Closed gokceneraslan closed 6 years ago
custom_objects
to
Maybe useful for you as well: I typically load all my own custom_objects to 'global custom objects' for convenience (you don't need to specify custom_objects in load_model then): https://github.com/gagneurlab/concise/blob/master/concise/__init__.py#L22-L27
I'm thinking whether it's maybe better for the user to just specify custom_objects to the global environment
from keras.utils.generic_utils import get_custom_objects
get_custom_objects()["myobject"] = myobject
I'll anyway add custom_objects to CompileFN
, test_fn
,
Maybe useful for you as well: I typically load all my own custom_objects to 'global custom objects' for convenience (you don't need to specify custom_objects in load_model then): https://github.com/gagneurlab/concise/blob/master/concise/__init__.py#L22-L27
I didn't know about that, very cool!
I'll anyway add custom_objects to CompileFN, test_fn,
That's also convenient, I think. Thanks!
As described here,
custom_objects
argument ofkeras.models.load_model
must be used for loading models with custom loss/layer/activation function. Adding here as a TODO item.