问题
if I load a model which was saved to a tf saved model file I get the following issue. (keras 2.0)
SystemError: unknown opcode
As I can find this has to do with a lambda layer in my model.
https://github.com/keras-team/keras/issues/9595
There was stated the solution to save the architecure and weights.
Keep the code around and just save the weights. As you said:
save the architecture as code, and the weights in an h5. This will be compatible across versions
But how do I do that?
How do I save the model with a lambda layer savely now?
Thanks!
来源:https://stackoverflow.com/questions/63937724/keras-load-saved-model-systemerror-unknown-opcode