【Bug解决】GeForce RTX 3070 with CUDA capability sm_86 is not compatible with the current PyTorch.

问题分析

F:\软件打包\Dislden_yolo_210510\torch\cuda\__init__.py:104: UserWarning:
GeForce RTX 3070 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 GeForce RTX 3070 GPU with PyTorch, please check the instructions at https://pytorch.org/get-started/locally/

  warnings.warn(incompatible_device_warn.format(device_name, capability, " ".join(arch_list), device_name))
Using CUDA device0 _CudaDeviceProperties(name='GeForce RTX 3070', total_memory=8192MB)

笔者的硬件环境如下:
显卡驱动:CUDA device0 _CudaDeviceProperties(name=‘GeForce RTX 3070’, total_memory=8192MB)
CUDA:11.1
运行pytorch框架的代码时出现的如上问题:现有的pytorch版本与驱动和cuda版本不匹配

解决问题

根据Bug提示打开网址:https://pytorch.org/get-started/locally/
在这里插入图片描述
输入图示的指令:

pip3 install torch==1.8.1+cu111 torchvision==0.9.1+cu111 torchaudio===0.8.1 -f https://download.pytorch.org/whl/torch_stable.html

再次运行报错前的指令

评论 6
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值