创建环境
conda create -n tensorflow python=3.6
切换环境
conda activate tensorflow
安装gpu版本的tensorflow,用conda安装会把cuda/cudnn都安装
conda install tensorflow-gpu==1.14
若不成功,重试几次或十来次或会成功
验证
(tensorflow) C:\Users\Administrator>python
Python 3.6.9 |Anaconda, Inc.| (default, Jul 30 2019, 14:00:49) [MSC v.1915 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import tensorflow as tf
...#此省略一大堆warning信息
>>>print(tf.__version__)
1.14.0