I trained the model on my custom dataset, and now when I am trying to import the .h5 file, it is throwing me this error
model = load_model('model/model_weights_efficient.h5')
Traceback (most recent call last):
File "", line 1, in
File "/home/eleven/ccd/tf12/lib/python3.6/site-packages/tensorflow/python/keras/saving/save.py", line 146, in load_model
return hdf5_format.load_model_from_hdf5(filepath, custom_objects, compile)
File "/home/eleven/ccd/tf12/lib/python3.6/site-packages/tensorflow/python/keras/saving/hdf5_format.py", line 212, in load_model_from_hdf5
custom_objects=custom_objects)
File "/home/eleven/ccd/tf12/lib/python3.6/site-packages/tensorflow/python/keras/saving/model_config.py", line 55, in model_from_config
return deserialize(config, custom_objects=custom_objects)
File "/home/eleven/ccd/tf12/lib/python3.6/site-packages/tensorflow/python/keras/layers/serialization.py", line 89, in deserialize
printable_module_name='layer')
File "/home/eleven/ccd/tf12/lib/python3.6/site-packages/tensorflow/python/keras/utils/generic_utils.py", line 192, in deserialize_keras_object
list(custom_objects.items())))
File "/home/eleven/ccd/tf12/lib/python3.6/site-packages/tensorflow/python/keras/engine/network.py", line 1121, in from_config
process_layer(layer_data)
File "/home/eleven/ccd/tf12/lib/python3.6/site-packages/tensorflow/python/keras/engine/network.py", line 1105, in process_layer
layer = deserialize_layer(layer_data, custom_objects=custom_objects)
File "/home/eleven/ccd/tf12/lib/python3.6/site-packages/tensorflow/python/keras/layers/serialization.py", line 89, in deserialize
printable_module_name='layer')
File "/home/eleven/ccd/tf12/lib/python3.6/site-packages/tensorflow/python/keras/utils/generic_utils.py", line 194, in deserialize_keras_object
return cls.from_config(cls_config)
File "/home/eleven/ccd/tf12/lib/python3.6/site-packages/tensorflow/python/keras/engine/base_layer.py", line 446, in from_config
return cls(**config)
File "/home/eleven/ccd/tf12/lib/python3.6/site-packages/tensorflow/python/keras/layers/convolutional.py", line 477, in init
kernel_initializer=initializers.get(kernel_initializer),
File "/home/eleven/ccd/tf12/lib/python3.6/site-packages/tensorflow/python/keras/initializers.py", line 194, in get
return deserialize(identifier)
File "/home/eleven/ccd/tf12/lib/python3.6/site-packages/tensorflow/python/keras/initializers.py", line 186, in deserialize
printable_module_name='initializer')
File "/home/eleven/ccd/tf12/lib/python3.6/site-packages/tensorflow/python/keras/utils/generic_utils.py", line 181, in deserialize_keras_object
config, module_objects, custom_objects, printable_module_name)
File "/home/eleven/ccd/tf12/lib/python3.6/site-packages/tensorflow/python/keras/utils/generic_utils.py", line 166, in class_and_config_for_serialized_keras_object
raise ValueError('Unknown ' + printable_module_name + ': ' + class_name)
ValueError: Unknown initializer: EfficientConv2DKernelInitializer
I trained the model on my custom dataset, and now when I am trying to import the .h5 file, it is throwing me this error
Any way around?