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

AttributeError: module 'tensorflow_core.contrib' has no attribute 'lite' #5

Open
japita-se opened this issue Oct 24, 2019 · 1 comment

Comments

@japita-se
Copy link

On a fresh install:

python3 demo.py
Using TensorFlow backend.
WARNING:tensorflow:
The TensorFlow contrib module will not be included in TensorFlow 2.0.
For more information, please see:

Traceback (most recent call last):
File "demo.py", line 124, in
mC = motionClassifier()

File "demo.py", line 19, in init
self.interpreter = tf.contrib.lite.Interpreter(model_path=self.model_path)
File "/usr/local/lib/python3.7/dist-packages/tensorflow_core/python/util/lazy_loader.py", line 63, in getattr
return getattr(module, item)
File "/usr/local/lib/python3.7/dist-packages/tensorflow/init.py", line 51, in getattr
return getattr(module, item)
AttributeError: module 'tensorflow_core.contrib' has no attribute 'lite'

@gohjiayi
Copy link

I encountered this as well and was able to run it by removing contrib. Instead of self.interpreter = tf.contrib.lite.Interpreter(model_path=self.model_path) I have self.interpreter = tf.lite.Interpreter(model_path=self.model_path).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants