2017-07-17 96 views
1

我试图在我的MacBook(OSX 10.12.5)上安装Tensorflow(r1.2)。 安装工程,但我收到错误,当我尝试在Python中导入TF。OSX上的Tensorflow:无法加载本地TensorFlow运行时(无模块名为pywrap_tensorflow_internal)

Python 2.7.10 (default, Feb 7 2017, 00:08:15) 
[GCC 4.2.1 Compatible Apple LLVM 8.0.0 (clang-800.0.34)] on darwin 
Type "help", "copyright", "credits" or "license" for more information. 

>>> import tensorflow as tf 
    Traceback (most recent call last): 
    File "<stdin>", line 1, in <module> 
    File "tensorflow/__init__.py", line 24, in <module> 
    from tensorflow.python import * 
    File "tensorflow/python/__init__.py", line 49, in <module> 
    from tensorflow.python import pywrap_tensorflow 
    File "tensorflow/python/pywrap_tensorflow.py", line 52, in <module> 
    raise ImportError(msg) 
    ImportError: Traceback (most recent call last): 
    File "tensorflow/python/pywrap_tensorflow.py", line 41, in <module> 
    from tensorflow.python.pywrap_tensorflow_internal import * 
    ImportError: No module named pywrap_tensorflow_internal 


Failed to load the native TensorFlow runtime. 

我在一家virtualenv(使用virtualenvwrapper)最多-TP最新封装

  • 蟒蛇2.7.10
  • PIP 9.0.1
  • numpy的1.13.1
  • 工作
  • 轮0.29.0
  • 六个1.10.0

我试着先用pip install tensorflow安装默认的pip软件包(不支持GPU)。 然后,我也尝试安装来自源代码之后的tensorflow,并且没有CUDA支持(配置脚本为No CUDA support will be enabled for TensorFlow)。建立和安装报告没有错误,但当我试图导入张量流时,我得到了同样的错误。

相关的问题/答案指出了CUDA的问题或缺少Windows DLL文件,这似乎不符合我的问题。

任何帮助,欢迎。提前致谢。

回答