NVIDIA/apex报错解决过程

本文详细记录了解决在安装NVIDIA Apex时遇到的CUDA版本不匹配问题,包括检查和设置正确的CUDA_HOME环境变量,确保与Pytorch二进制文件的CUDA版本一致,以及处理Microsoft Visual Studio版本不支持的问题。

https://github.com/NVIDIA/apex

python setup.py install --cuda_ext --cpp_ext

马上报错

File "setup.py", line 106, in <module>
    check_cuda_torch_binary_vs_bare_metal(torch.utils.cpp_extension.CUDA_HOME)
  File "setup.py", line 80, in check_cuda_torch_binary_vs_bare_metal
    "https://github.com/NVIDIA/apex/pull/323#discussion_r287021798.  "

RuntimeError: Cuda extensions are being compiled with a version of Cuda that does not match the version used to compile Pytorch binaries.  Pytorch binaries were compiled with Cuda 10.0.
In some cases, a minor-version mismatch will not cause later errors:  https://github.com/NVIDIA/apex/pull/323#discussion_r287021798.  You can try commenting out this check (at your own risk).

Cuda扩展的编译版本与用于编译Pytorch二进制文件的版本不匹配。Pytorch二进制文件是用Cuda 10.0编译的。

查询一下CUDA版本

C:\Users\Clem
评论 5
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值