def instance_id(self):
        """The label's instance ID, or None if it does not have one."""
        try:
            return self.instance.id
        except AttributeError:
            return None
The label's instance ID, or None if it does not have one.
fiftyone/core/labels.py