You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@xing-w,
I request you to take a look at this issue where a similar feature has been proposed and it is still open.Also I request to follow the similar issue which has been raised to have the updates on the similar issue. Thank you!
I think I am facing the same issue with load_model(). Right now, I'm using save_weight() and load_weight() to go around this problem. Hope it would be fixed soon.
@xing-w,
I tried to execute the mentioned code on tf-nightly and keras 3.0 version and it was executed without any issue/error. Kindly find the gist of it here. Thank you!
Issue type
Bug
Have you reproduced the bug with TensorFlow Nightly?
Yes
Source
source
TensorFlow version
2.13.0
Custom code
Yes
OS platform and distribution
No response
Mobile device
No response
Python version
No response
Bazel version
No response
GCC/compiler version
No response
CUDA/cuDNN version
No response
GPU model and memory
No response
Current behavior?
A simple RNN with LSTMcell model.
I want to initialize the states with
initial_state_h
andinitial_state_c
.After compile and train, the model is saved with
model.save('my_model_test.keras')
.But when I try to load it with
load_model = tf.keras.models.load_model('my_model_test.keras')
, it gives error:I tried to save in other format,
.h5
,.json
, etc. All give the same error.But, if I don't use
initial_state
inoutputs,states_h_fw, states_c_fw= lstm_layer_fw(inputs)
, everything goes well. No problem withload_model
.Standalone code to reproduce the issue
Relevant log output
The text was updated successfully, but these errors were encountered: