def get_length_breakdown(model, property_ids=None, stop_if_no_length=True):
    """
    Gets a breakdown of the length by property region.

    Returns
    -------
    pids_to_length : Dict[int pid] : float length
        the pid to length dictionary

    TODO: What about CONRODs?

    """
    skip_props = {'PSOLID', 'PLPLANE', 'PPLANE', 'PELAS', 'PDAMP', 'PBUSH',
        'PBUSH1D', 'PBUSH2D', 'PELAST', 'PDAMPT', 'PBUSHT', 'PDAMP5',
        'PFAST', 'PGAP', 'PRAC2D', 'PRAC3D', 'PCONEAX', 'PLSOLID', 'PCOMPS',
        'PVISC', 'PSHELL', 'PCOMP', 'PCOMPG', 'PSHEAR', 'PIHEX', 'PBEND',
        'PACABS', 'PAABSF', 'PACBAR'}
    bar_properties = {'PBAR', 'PBARL', 'PBEAM', 'PBEAML', 'PROD', 'PTUBE',
        'PBRSECT', 'PBMSECT', 'PBCOMP', 'PBEAM3'}
    pid_eids = model.get_element_ids_dict_with_pids(property_ids,
        stop_if_no_eids=stop_if_no_length, msg=
        ' which is required by get_length_breakdown')
    pids_to_length = {}
    for pid, eids in pid_eids.items():
        prop = model.properties[pid]
        lengths = []
        if prop.type in skip_props:
            continue
        elif prop.type in bar_properties:
            for eid in eids:
                elem = model.elements[eid]
                try:
                    lengths.append(elem.Length())
                except AttributeError:
                    print(prop)
                    print(elem)
                    raise
        else:
            print('prop\n%s' % prop)
            eid0 = eids[0]
            elem = model.elements[eid0]
            msg = str(prop) + str(elem)
            raise NotImplementedError(msg)
        if lengths:
            pids_to_length[pid] = sum(lengths)
    has_length = len(pids_to_length)
    if not has_length:
        msg = 'No elements with length were found'
        model.log.warning(msg)
        if stop_if_no_length:
            raise RuntimeError(msg)
    return pids_to_length
