环境 :python3.6
激活环境:
conda activate tf15
conda install cudatoolkit=10.0
查找cudnn对应版本:
conda search cudnn -c https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main/win-64/
conda install cudnn=7.6.4 -c https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main/win-64/
安装tensorflow
pip install tensorflow-gpu==1.15
进入编译环境测试GPU是否可用:
import tensorflow as tf
print(tf.test.is_gpu_available())