AssertionError: CUDA unavailable, invalid device 0 requested

1.6.0版本的torch不支持低版本的cuda 10.1 所以检测不到gpu,安装兼容10.1低版本cuda的对应torch版本1.6.0+cu101

 

pip install torch==1.6.0+cu101 torchvision==0.7.0+cu101 -f https://download.pytorch.org/whl/torch_stable.html

文章来自:https://www.cnblogs.com/owlowl/p/13673415.html
© 2021 jiaocheng.bubufx.com  联系我们
ICP备案:鲁ICP备09046678号-3