def create_mapping(label_mapping_p):
    """Creates a Python dictionary mapping an index to a label.

    label_mapping[idx] = label

    args:
      - label_mapping_p: pathlib.Path

    returns:
      - label_mapping: dict
    """
    idx = 0
    label_mapping = {}
    with open(label_mapping_p) as label_mapping_raw:
        for line in label_mapping_raw:
            label_mapping[idx] = line
            idx += 1

    return label_mapping