python - 安装并运行 tensorflow

标签 python tensorflow

我从未使用过tensorflow(或python)。我从https://www.python.org/downloads/安装了Python 3.5.2 。然后我按照此页面的说明安装 Tensorflow,适用于 Windows 64 位安装:

https://www.tensorflow.org/versions/r0.12/get_started/os_setup.html#download-and-setup

我按照 Windows 上的 Pip 安装步骤进行了仅 CPU 的安装。然后我按照测试 TensorFlow 安装/从命令行运行 TensorFlow 进行操作,看起来也基本没问题。

但是当我尝试运行 TensorFlow 演示模型部分时,我遇到了困难。具体来说,命令python -m tensorflow.models.image.mnist.convolutional在查找“tensorflow.models.image.mnist.volval”的规范时返回一个错误(ImportError:没有名为的模块) 'tensorflow.models')

我不太明白安装过程,也不明白我缺少什么。你能告诉我我搞砸了什么吗?

最佳答案

Tensorflow 模型已移至不同的 github 存储库。 因此,安装 TF 后,它们将不再可用。 您可以在这里找到该文件: https://github.com/tensorflow/models/blob/master/tutorials/image/mnist/convolutional.py

您可以下载此文件并手动执行。 抱歉,文档已过时。

关于python - 安装并运行 tensorflow ,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/41047158/

相关文章:

python - tensorflow word2vec 基本输入输出占位符

python - 使用 tensorflow 时 GPU 同步失败

python-3.x - 索引错误: index 69791 is out of bounds for axis 0 with size 56044

python - 如何通过重复索引拆分数据帧并进行枚举?

python - wxpython textctrl 打印到特定行

python - 如何找到 pandas 时间序列的最后一个局部最大值?

python - tf.gfile.GFile().read() 和 cv2.imread() 在读取图像时有什么区别

python - 如何在 Canvas Python Tkinter 中居中图像

python - 正则表达式仅提取单词

python - 使用 DNN 进行多标签预测