class_docstr: Helper class providing useful methods for working with ``SampleCollection`` datasets from FiftyOne.
  
  Args:
      label_field: The field in the ``SampleCollection`` containing the ground truth labels.
      label_cls: The ``FiftyOne.Label`` subclass to expect ground truth labels to be instances of. If ``None``,
          defaults to ``FiftyOne.Label``.
code: def get_classes(self, sample_collection: SampleCollection):
      classes = sample_collection.classes.get(self.label_field, None)
  
      if not classes:
          classes = sample_collection.default_classes
  
      if not classes:
          label_path = sample_collection._get_label_field_path(
              self.label_field, "label"
          )[1]
          classes = sample_collection.distinct(label_path)
  
      return classes
  
file_path: lightning-flash/src/flash/core/integrations/fiftyone/utils.py
imports: from itertools import chain
  from typing import Dict, List, Optional, Type, Union
  import flash
  from flash.core.utilities.imports import _FIFTYONE_AVAILABLE, lazy_import, requires
label_desc: Use image node_id 3 for calling the FiftyOneLabelUtilities obj's underlying member method code with example usage: obj.get_classes(sample_collection) and returns: classes