Open yy198698 opened 5 years ago
import torch
a = torch.tensor(1.)
a.cuda()
from torch.backends import cudnn
cudnn.is_available()
cudnn.is_acceptable(a.cuda())
https://blog.csdn.net/bat67/article/details/84065261
pytorch验证cuda版本 torch.version.cuda
import torch
若正常则静默
a = torch.tensor(1.)
若正常则静默
a.cuda()
若正常则返回 tensor(1., device='cuda:0')
from torch.backends import cudnn
若正常则静默
cudnn.is_available()
若正常则返回 True
cudnn.is_acceptable(a.cuda())
https://blog.csdn.net/bat67/article/details/84065261