def get_spectral_characteristics_for_lid(local_identifier, label):
    """ Search a PDS4 label for Spectral_Characteristics of a data structure with local_identifier.

    Parameters
    ----------
    local_identifier : str or unicode
        The local identifier of the data structure to which the spectral characteristics belong.
    label : Label or ElementTree Element
        Label for a PDS4 product with-in which to look for the spectral characteristics.

    Returns
    -------
    Label,  ElementTree Element or None
        Found Spectral_Characteristics section with same return type as *label*, or None if not found.
    """

    matching_spectral = None

    # Find all the Spectral Characteristics classes in the label
    spectra = label.findall('.//sp:Spectral_Characteristics')
    if not spectra:
        return None

    # Find the particular Spectral Characteristics for this LID
    for spectral in spectra:

        # There may be multiple local internal references for each spectral data object sharing these
        # characteristics. Also look in both PDS and SP namespace due to standards changes in the spectral
        # dictionary
        references = spectral.findall('sp:Local_Internal_Reference') + \
                     spectral.findall('Local_Internal_Reference')

        for reference in references:

            # Look in both PDS and DISP namespace due to standards changes in the display dictionary
            lid_sp = reference.findtext('sp:local_identifier_reference')
            lid_pds = reference.findtext('local_identifier_reference')

            if local_identifier in (lid_sp, lid_pds):
                matching_spectral = spectral
                break

    return matching_spectral