Loading

detectron2 The detected CUDA version mismatches 错误

我的报错信息

The detected CUDA version (9.1) mismatches the version that was used to compile PyTorch (11.3). Please make sure to use the same CUDA versions.

https://github.com/facebookresearch/detectron2/issues/4343#issuecomment-1229448546

根据这个问题

我查看了 nvcc --version 显示是9.1

解决方法

https://huaweicloud.csdn.net/638071e7dacf622b8df884df.html

~/.bashrc当中添加

export PATH=/usr/local/cuda-10.2/bin:$PATH
export LD_LIBRARY_PATH=/usr/local/cuda-10.2/lib64:$LD_LIBRARY_PATH

10.2注意和所需的nvidia-smi版本对应

重新编译即可

posted @ 2023-02-01 17:22  ZXYFrank  阅读(4918)  评论(0编辑  收藏  举报