【发布时间】:2018-07-23 00:35:02
【问题描述】:
我刚刚安装了 tesorflow cpu,这是我的代码
import tensorflow as tf
node1 = tf.constant(3.0)
node2 = tf.constant(4.0)
print(node1)
这没有运行,并出现以下错误:
Traceback (most recent call last):
File "c:\Python\Python36\cssi\final_project.py", line 1, in <module>
import tensorflow as tf
File "c:\Python\Python36\cssi\tensorflow.py", line 2, in <module>
node1 = tf.constant(3.0)
AttributeError: module 'tensorflow' has no attribute 'constant'
请帮忙
【问题讨论】:
-
你是如何安装 tensorflow 的?
-
我跟着他们网站上的教程
标签: python tensorflow python-3.6