anaconda官网下载安装
2. 创建TensorFlow环境打开cmd,首先创建tensorflow 需要的环境
conda create -n tensorflow pip python=3.8
激活TensorFlow环境
activate tensorflow3. 安装TensorFlow(国内源,速度飞快)
安装CPU版本输入
pipinstall --index-url https://pypi.douban.com/simple --ignore-installed --upgrade tensorflow
安装GPU版本输入
pipinstall --index-url https://pypi.douban.com/simple --ignore-installed --upgrade tensorflow-gpu3. 测试
import tensorflow as tf a=tf.ones(5) print(a)



