Keras-retinanet: No training configuration found

Created on 29 Dec 2017  路  6Comments  路  Source: fizyr/keras-retinanet

First of all, I'd like to thank several staff for your efforts to complete such a wonderful project.
Then I'm sorry for the bother caused by my question.

The problem is as follows.
I tried to train a model with VOC by using train.py and 50 epochs, and then I got the final model 'resnet50_pascal_50.h5'.
Next, I loaded the 'resnet50_pascal_50.h5' by the code
' model = keras.models.load_model('snapshots/resnet50_pascal_50.h5', custom_objects=custom_objects) '

But I got a message

/usr/local/lib/python2.7/dist-packages/keras/models.py:252: UserWarning: No training configuration found in save file: the model was not compiled. Compile it manually.
warnings.warn('No training configuration found in save file: '

Was there something I did in wrong way?
Thank you for your reply.

Most helpful comment

Seems you saved it before running compile on your model. What the warning means is that no training state is found in the saved model, meaning if you wanted to, you can't resume training. Based on the error I would guess it should still run the detections on your model.

Does this resolve your issue?

All 6 comments

I think it doesn't matter.Just ignore it. You can still use this model to test and so on.

Seems you saved it before running compile on your model. What the warning means is that no training state is found in the saved model, meaning if you wanted to, you can't resume training. Based on the error I would guess it should still run the detections on your model.

Does this resolve your issue?

Thank you very much for the reply.
As huangcong77 said, ignoring this issue seems to have no effect.
At that time, I was a little over-worried about where I did something wrong.
But nothing happened, everything looked very successful.
You guys are very enthusiastic, thanks again.

Good to hear :)

I seem to find this warning too when I use a saved model to predict. During training I do this in order
create model -> compile model -> data flow from dir -> fit generator -> save model. Then I use the model in another script as load model -> predict.
Is it okay to ignore this , or is it required to compile the model again? I am using Keras 2.2

It's okay to ignore.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

remcova picture remcova  路  4Comments

aaronBioBot picture aaronBioBot  路  5Comments

xyiaaoo picture xyiaaoo  路  5Comments

wassname picture wassname  路  6Comments

mayur-who picture mayur-who  路  5Comments