[TensorFlow] Win10 下GPU版安装
2019-03-15 本文已影响0人
AustinPup
本机环境
. Win10
. NVIDIA TITAN XP
. TensorFlow 1.12.0
. Python 3.6.8
. Anaconda
. CUDA Toolkit 9.0
. CuDnn 7.5
安装过程
基本参照引文去做,但不能安装TensorFlow 的1.13 及以上版本,出现DLL找不到的问题
一些命令
//Anaconda 新建Python环境
conda create -n tensorflow pip python=3.6
//删除Python环境
conda remove -n tensorflow --all
//进入环境
conda activate tensorflow
//退出环境
conda deactivate
//删除某个包
conda remove -n tensorflow numpy
//安装GPU版的TensorFlow
pip install --ignore-installed --upgrade tensorflow-gpu==1.12.0 -i https://mirrors.aliyun.com/pypi/simple
//安装某个包
pip install pillow -i https://mirrors.aliyun.com/pypi/simple
//conda基础包安装
conda install anaconda
//conda包列表查看
conda list
校验
1.查看是否使用GPU
import tensorflow as tf
tf.test.gpu_device_name()

- 查看在使用哪个GPU
from tensorflow.python.client import device_lib
device_lib.list_local_devices()
