参考https://zhuanlan.zhihu.com/p/26871672
- 首先确认windows下cuda8.0及cudnn5.1安装成功
- 确认anaconda4.4安装成功,python版本3.6.1
- 下载 pytorch-0.1.12-py36_0.1.12cu80.tar.bz2
进入安装包目录,shift + 右键,在当前目录命令行输入
conda install numpy mkl cffi
conda install –offline pytorch-0.1.12-py36_0.1.12cu80.tar.bz2测试python
python
import torch
import torch
x = torch.Tensor([1.0])
xx = x.cuda()
print(xx)from torch.backends import cudnn
print(cudnn.is_acceptable(xx))
成功