def to_json(self):
        """Converts the object definition to JSON.

        Returns:
            a JSON dict
        """
        properties = {}
        for name, prop in self.properties.items():
            properties[name] = prop.to_json()

        return {"name": self.__class__.__name__, "properties": properties}
Converts the object definition to JSON.

        Returns:
            a JSON dict
        
fiftyone/operators/types.py