Sunday, September 18, 2016

ImportError: cannot import name pywrap_tensorflow

When you import `tensorflow`, you might encounter the following error:

>>> import tensorflow
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "tensorflow/__init__.py", line 23, in <module>
    from tensorflow.python import *
  File "tensorflow/python/__init__.py", line 49, in <module>
    from tensorflow.python import pywrap_tensorflow
ImportError: cannot import name pywrap_tensorflow
>>>

If you're in the source directory of TensorFlow, moving out from it will solve the issue.

Reference:
https://github.com/tensorflow/tensorflow/issues/3217

No comments:

Post a Comment