def set(self, object_id, obj):
        """Stores an instantiated object for future lookup and sharing."""
        if object_id is None:
            return
        self._obj_ids_to_obj[object_id] = obj
Stores an instantiated object for future lookup and sharing.
keras/src/legacy/saving/serialization.py