We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d2db251 commit 3bf1b5fCopy full SHA for 3bf1b5f
tensorflow_addons/utils/keras_utils.py
@@ -19,9 +19,9 @@
19
20
# TODO: find public API alternative to these
21
from tensorflow.python.keras.losses import LossFunctionWrapper # pylint: disable=unused-import
22
-from tensorflow.python.keras.utils import generic_utils
+from tensorflow.keras.utils import get_custom_objects
23
24
25
def register_keras_custom_object(cls):
26
- generic_utils._GLOBAL_CUSTOM_OBJECTS[cls.__name__] = cls
+ get_custom_objects()[cls.__name__] = cls
27
return cls
0 commit comments