服务器上Cuda+Pytorch兼容性的那些问题

服务器上如何搭建匹配版本的cuda+pytorch:

1.查询nvidia中驱动版本与cuda最高兼容版本

命令行输入:nvidia-smi

2.选择对应的python

Driver Version与NVIDIA-SMI决定当前服务器上能兼容最高cuda和Pytorch版本

查询匹配方式:1.官网查询 2.问AI(可能存在不准确情况)

CUDA版本与显卡驱动版本对照表(更新至2022.10.26 - CUDA11.8)

3.cuda+torch离线包(网站附torchvision离线包):

http://download.pytorch.org/whl/torch_stable.html

4.torch与torchvision版本对应:

PyTorch中torch、torchvision、torchaudio、torchtext版本对应关系_torch2.0.1对应的torchvision-CSDN博客(经尝试可能存在一定问题)

其它方法:问AI对应

bash 复制代码
import torch # 如果pytorch安装成功即可导入  
print(torch.cuda.is_available()) # 查看CUDA是否可用  
print(torch.cuda.device_count()) # 查看可用的CUDA数量  
print(torch.version.cuda) # 查看CUDA的版本号

cuda+pytorch以及服务器驱动不匹配的那些问题:

1.RuntimeError: The NVIDIA driver on your system is too old.-CSDN博客

2.RuntimeError:No such operator torchvision::nms

3.UserWarning: NVIDIA GeForce RTX 3080 with CUDA capability sm_86 is not compatible with the current PyTorch installation.
The current PyTorch install supports CUDA capabilities sm_37 sm_50 sm_60 sm_61 sm_70 sm_75 compute_37.
If you want to use the NVIDIA GeForce RTX 3080 GPU with PyTorch, please check the instructions at https://pytorch.org/get-started/locally/

相关推荐
暴力求解1 小时前
Linux--进程(四) 进程优先级与进程切换
linux·运维·服务器
枕石 入梦1 小时前
华为云服务器本地部署大模型实战(Ollama + Tesla T4 踩坑记)
服务器·人工智能·大模型·华为云
Laughtin1 小时前
【Claude Code】如何删除git提交时的AI署名
运维·服务器
小叮当⇔2 小时前
计算机网络实验——华为eNSP模拟器常用命令总结
服务器·计算机网络·华为
开开心心就好2 小时前
实用PDF擦除隐藏信息工具,空白处理需留意
运维·服务器·windows·pdf·迭代器模式·桥接模式·1024程序员节
礼拜天没时间.2 小时前
Docker Registry私有仓库搭建与使用
java·运维·docker·云原生·容器·centos
落羽的落羽2 小时前
【Linux系统】磁盘ext文件系统与软硬链接
linux·运维·服务器·数据库·c++·人工智能·机器学习
码客研究员2 小时前
Kafka(05)搭建高可用Kafka集群:从三台服务器开始
服务器·kafka·linq
Codefengfeng2 小时前
Kali-linux中安装与使用Stegsolve
linux·运维·服务器