def _get_layer_from_layermap(layermap, layerid):
    """
    Get corresponding layer name and purpose from layermap
    Parameters
    ----------
    layermap : dict()
        layermap dictionary
    layerid : [int, int]
        layermap id
    Returns
    -------
    [str, str]
        layer name and purpose
    """
    for layer_name, layer in layermap.items():
        for layer_purpose, layer in layer.items():
            if layerid == layer:
                return [layer_name, layer_purpose]
    return None