1问题:
从网上下载了一个源码:Tensorflow卷积神经网络(CNN)手写数字识别,准备跑来看看效果,谁知道卡在导入数据,报错:
from tensorflow.examples.tutorials.mnist import input_data(这一行有错,找不到tutorials)
2环境:
python 3.7
tensorflow2.0
3解决办法:
tensorflow 改为低版本,比如改为1.14.0
4解决步骤:
cmd命令下:
pip uninstall tensorflow
pip install tensorflow==1.14.0
发现下载速度太慢后,换到清华大学镜像上
pip pip install tensorflow==1.14.0 -i https://pypi.tuna.tsinghua.edu.cn/simple/
(
阿里云 http://mirrors.aliyun.com/pypi/simple/
中国科技大学 https://pypi.mirrors.ustc.edu.cn/simple/
豆瓣(douban) http://pypi.douban.com/simple/
清华大学 https://pypi.tuna.tsinghua.edu.cn/simple/
中国科学技术大学 http://pypi.mirrors.ustc.edu.cn/simple/
)