2017-03-16 41 views
0

我正在關注的turtorial https://www.tensorflow.org/install/install_windows,但是當我嘗試導入tensorflow,它帶有一個錯誤:NameError:名字「核心」沒有定義

Traceback (most recent call last):
File "", line 1, in import tensorflow as tf
File "D:\Python 3.5.3\lib\site-packages\tensorflow__init__.py", line 51, in
del core
NameError: name 'core' is not defined

的tensorflow安裝命令是

pip3 install --upgrade tensorflow

完整的代碼是在這裏 >

import tensorflow as tf 
hello = tf.constant('Hello, TensorFlow!')  
sess = tf.Session()     
print(sess.run(hello)) 

Python的版本我s 3.5.3順便說一下

有什麼辦法可以解決這個問題嗎?提前致謝。

+0

你可以粘貼你的命令來安裝TensorFlow嗎? – vanloc

+0

我正在關注Tensorflow官方網站發佈的教程,鏈接在這裏https://www.tensorflow.org/install/install_windows。我用的命令是:pip3 install --upgrade tensorflow –

+0

你能發佈完整的代碼嗎? – vanloc

回答

1

我已經通過解決了這個問題安裝Python時選項'預編譯標準庫'。

相關問題