Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failing to infere input type for RNN layer when loading Keras model #6995

kolarto opened this issue Jan 14, 2019 · 2 comments


Copy link

commented Jan 14, 2019

Issue Description

Hi, I am are trying to load model with weights from keras.
When I try to load the model config using the function KerasModelImport.importKerasModelConfiguration(jsonFilePath) and than weights separately, there is an exception "Invalid input for RNN layer (layer name = "value_encoder"): input type is null". (first included json file)
The same thing happens when exporting the model in HDF5 file with weights and model configuration together. Keras is able to load and infere this model without a problem both separate and as one HDF5 file.

I also tried to include all the shapes i was able to define in the configuration (second included json), as I thought the problem could be caused by inability of DL4j to infer the shapes, but the same error was still present.
I was not able to force include output shapes in Keras, but those should not be required.

Version Information

  • Deeplearning4j version - 1.0.0 beta3 with native backend
  • platform information - windows 10


This comment has been minimized.

Copy link

commented Apr 9, 2019

Fixed #7502


This comment has been minimized.

Copy link

commented May 9, 2019

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock bot locked and limited conversation to collaborators May 9, 2019

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
None yet
3 participants
You can’t perform that action at this time.