(self, split, superclass_id,
                                                  class_inds)
return rel_class_ids, class_ids
Gets the class ids of a number of classes of a given superclass.

    Args:
      split: A Split, the split for which to get classes.
      superclass_id: An int. The id of a superclass.
      class_inds: A list or sequence of ints. The indices into the classes of
        the superclass superclass_id that we wish to return class id's for.

    Returns:
      rel_class_ids: A list of ints of length equal to that of class_inds. The
        class id's relative to the split (between 0 and num classes in split).
      class_ids: A list of ints of length equal to that of class_inds. The class
        id's relative to the dataset (between 0 and the total num classes).
Gets the class ids of a number of classes of a given superclass.
Gets the class ids of a number of classes of a given superclass .
def get_class_ids_from_superclass_subclass_inds(self, split, superclass_id,
                                                  class_inds):
    """Gets the class ids of a number of classes of a given superclass.

    Args:
      split: A Split, the split for which to get classes.
      superclass_id: An int. The id of a superclass.
      class_inds: A list or sequence of ints. The indices into the classes of
        the superclass superclass_id that we wish to return class id's for.

    Returns:
      rel_class_ids: A list of ints of length equal to that of class_inds. The
        class id's relative to the split (between 0 and num classes in split).
      class_ids: A list of ints of length equal to that of class_inds. The class
        id's relative to the dataset (between 0 and the total num classes).
    """
    # The number of classes before the start of superclass_id, i.e. the class id
    # of the first (sub-)class of the given superclass.
    superclass_offset = self._count_classes_in_superclasses(
        range(superclass_id))

    # Absolute class ids (between 0 and the total number of dataset classes).
    class_ids = [superclass_offset + class_ind for class_ind in class_inds]

    # Relative (between 0 and the total number of classes in the split).
    # This makes the assumption that the class id's are in a contiguous range.
    rel_class_ids = [
        class_id - self._get_split_offset(split) for class_id in class_ids
    ]

    return rel_class_ids, class_ids
def get_class_ids_from_superclass_subclass_inds ( self , split , superclass_id , class_inds ) : # The number of classes before the start of superclass_id, i.e. the class id # of the first (sub-)class of the given superclass. superclass_offset = self . _count_classes_in_superclasses ( range ( superclass_id ) ) # Absolute class ids (between 0 and the total number of dataset classes). class_ids = [ superclass_offset + class_ind for class_ind in class_inds ] # Relative (between 0 and the total number of classes in the split). # This makes the assumption that the class id's are in a contiguous range. rel_class_ids = [ class_id - self . _get_split_offset ( split ) for class_id in class_ids ] return rel_class_ids , class_ids