def num_classes(self):
        """The number of classes for the model, if known."""
        if self._classes is not None:
            return len(self._classes)

        return None
The number of classes for the model, if known.
fiftyone/utils/torch.py