-
Notifications
You must be signed in to change notification settings - Fork 74k
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
'Sequential' object has no attribute '_get_save_spec' #39001
Labels
stat:awaiting response
Status - Awaiting response from author
TFLiteConverter
For issues related to TFLite converter
type:bug
Bug
Comments
@davidbayon |
Saduf2019
added
the
stat:awaiting response
Status - Awaiting response from author
label
Apr 29, 2020
tf.keras not same keras |
Thanks a lot, that worked!
…On Fri, May 1, 2020 at 12:28 PM LunaMK ***@***.***> wrote:
tf.keras not same keras
model=tf.keras.models.load_model('model.h5', compile=False)
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#39001 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AJHKOX63TGFABXAOFMCRMNDRPIXTPANCNFSM4MTHIEXA>
.
--
David Bayon
|
Issue was : |
Please what is the solution code to that error |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
stat:awaiting response
Status - Awaiting response from author
TFLiteConverter
For issues related to TFLite converter
type:bug
Bug
System information
Command used to run the converter or code if you’re using the Python API
https://colab.research.google.com/drive/1IJWCGMZ9Wrf8C89oLJ_AWnGPH1ea4dma
converter = tf.lite.TFLiteConverter.from_keras_model(model)
The output from the converter invocation
AttributeError Traceback (most recent call last)
in ()
----> 1 converter = tf.lite.TFLiteConverter.from_keras_model(model)
1 frames
/usr/local/lib/python3.6/dist-packages/tensorflow/python/keras/saving/saving_utils.py in model_input_signature(model, keep_original_batch_size)
75 TensorSpecs. This list does not contain the
training
argument.76 """
---> 77 input_specs = model._get_save_spec(dynamic_batch=not keep_original_batch_size) # pylint: disable=protected-access
78 if input_specs is None:
79 return None
AttributeError: 'Sequential' object has no attribute '_get_save_spec'
Failure details
Fails to convert
Any other info / logs
When running the exact same code on a Windows 10 machine with TF2.1, the error is different :
D:\dev\Anaconda3\lib\site-packages\keras\engine\base_layer.py in call(self, inputs, **kwargs)
487 # Actually call the layer,
488 # collecting output(s), mask(s), and shape(s).
--> 489 output = self.call(inputs, **kwargs)
490 output_mask = self.compute_mask(inputs, previous_mask)
491
TypeError: call() got an unexpected keyword argument 'training'
The text was updated successfully, but these errors were encountered: