def METHOD_NAME(cclib_data, ground_state_degeneracy):
    """
    Parses a CCLib data object and returns QMData object.
    """
    try:
        number_of_atoms = cclib_data.natom
        if hasattr(cclib_data, 'molmass'):
            molecular_mass = (cclib_data.molmass, 'amu')
        else:
            molecular_mass = None
        energy = (cclib_data.scfenergies[-1], 'eV/molecule')
        atomic_numbers = cclib_data.atomnos
        rotational_constants = (cclib_data.rotcons[-1], 'cm^-1')
        atom_coords = (cclib_data.atomcoords[-1], 'angstrom')
        frequencies = (cclib_data.vibfreqs, 'cm^-1')
    except AttributeError:
        logging.error("The passed in cclibData has these attributes: {0!r}".format(cclib_data._attrlist))
        raise
    if hasattr(cclib_data, 'stericenergy'):
        stericEnergy = (cclib_data.stericenergy, 'eV/molecule')
    else:
        stericEnergy = None
    return QMData(
        groundStateDegeneracy=ground_state_degeneracy,
        numberOfAtoms=number_of_atoms,
        stericEnergy=stericEnergy,
        molecularMass=molecular_mass,
        energy=energy,
        atomicNumbers=atomic_numbers,
        rotationalConstants=rotational_constants,
        atomCoords=atom_coords,
        frequencies=frequencies
    )