Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

tensorflow lite conversion failed. "undefined symbol : _ZTIN10tensorflow6DeviceE" occured

Tags:

tflite_model = converter.convert()
tflite_model_file = 'converted_model.tflite'

with open(tflite_model_file, "wb") as f:
  f.write(tflite_model)

When I finally converted model within dot convert method, I got some error.

Error Message:

ValueError: Failed to parse the model: /tensorflow-2.1.0/python3.6/tensorflow_core/lite/python/optimize/_tensorflow_lite_wrap_calibration_wrapper.so: undefined symbol: _ZTIN10tensorflow6DeviceE.

Source Code:

https://colab.research.google.com/github/tensorflow/examples/blob/master/courses/udacity_intro_to_tensorflow_lite/tflite_c02_transfer_learning.ipynb#scrollTo=BbTF6nd1KG2o

even through I didn't find what is

_ZTIN10tensorflow6DeviceE

How could I convert transfer learning model?

like image 609
soredive Avatar asked Dec 26 '19 15:12

soredive


1 Answers

I had the same issue - installing nightly build (currently '2.1.0-dev20200104') solved it.

!pip3 uninstall tensorflow
!pip3 install tf-nightly
like image 79
gog Avatar answered Oct 20 '22 06:10

gog