Unable to load model from .h5 file
See original GitHub issue# Unable to load model
Using TensorFlow backend.
Traceback (most recent call last):
File "ocv.py", line 7, in <module>
model = load_model('bottleneck_fc_model.h5')
File "/usr/local/lib/python2.7/dist-packages/keras/models.py", line 230, in load_model
raise ValueError('No model found in config file.')
ValueError: No model found in config file.
I did not find a clear answer in other issues.
Issue Analytics
- State:
- Created 6 years ago
- Comments:15 (1 by maintainers)
Top Results From Across the Web
I can't load my trained h5 model with load.models(), how do I ...
Yes, there is a conflict between tf.keras and keras packages, you trained the model using tf.keras but then you are loading it with...
Read more >Problems loading h5 model - TensorFlow Forum
This failed: model_config = f.attrs.get('model_config') (returned None). So inspect that f.attrs and try to figure out what's wrong, maybe you ...
Read more >Unable to load a .h5 keras model
but when I'm trying to load the model using the following command: saved_model = keras.models.load_model('mymodel.h5').
Read more >fail to load h5 model - Google Groups
Hello everyone ! I have the error : " Traceback (most recent call last): File "/home/reveries/programmes/Valery_Malecot_opencv4/ ...
Read more >How to Save and Load Your Keras Deep Learning Model
It is important to compile the loaded model before it is used. ... I have created the keras model file (.h5) unfortunately it...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Did you saved with model.save or model.save_weights? Also, try to provide a working example so that we can see if it’s a bug.
I am using a pre-trained model such as Alexnet, In this case also, ending up with the same error.
I was downloaded the alexnet_weights from here–>https://github.com/heuritech/convnets-keras then I tried like this
from keras.models import load_model base_model=load_model(‘alexnet_weights.h5’)
I ended up with
ValueError: No model found in config file.
please help me to get rid out of it.