AssertionError: Duplicate registrations for type 'experimentalOptimizer' when converting ssd model to tflite format

Hi Everyone,
I was trying to convert my trained ssd model to tflite format. But I always face to this below error.

Here is my code:


import tensorflow as tf

converter = tf.lite.TFLiteConverter.from_saved_model("/TensorFlow/workspace/traning_demo/exported-models/my_model/saved_model/") tflite_model = converter.convert()

with open(‘tflite_test2.tflite’, ‘wb’) as f: f.write(tflite_model)


Does anyone have solution for this problem? Thank you very much

Best regards

The same after updating the python to v3.10 and tensorflow&keras to v2.8

Can you pip list your Tensorflow and Keras installed packages?

Thank you all very much for your reply. But I solved this problem.

Could you explain how did you solve the problem

1 Like