python中安装tensorflow

  1. 下载Python3.7版本以下的且为64bit进行安装,注意勾选环境

  2. 升级pip

    python -m pip install --upgrade pip

  3. 安装tensorflow

    pip install tensorflow

如果处在墙内建议使用国内镜像

pip install -i https://pypi.tuna.tsinghua.edu.cn/simple tensorflow

出现如下情况,可更改protobuf版本解决:

pip uninstall protobuf
pip install protobuf==3.6.0

出现如下情况,可更改protobuf版本解决

猜你喜欢

转载自blog.csdn.net/obf13/article/details/85272881