📜  未设置 cuda_home 环境变量.请将其设置为您的 cuda 安装根目录. - Shell-Bash 代码示例

📅  最后修改于: 2022-03-11 14:50:14.152000             🧑  作者: Mango

代码示例1
Solution to above issue!

As cuda installed through anaconda is not the entire package. Please install cuda drivers manually from Nvidia Website[ https://developer.nvidia.com/cuda-downloads ]

After installation of drivers, pytorch would be able to access the cuda path. You can test the cuda path using below sample code. Problem resolved!!!

CHECK INSTALLATION:

import os
print(os.environ.get('CUDA_PATH'))
OUTPUT:

C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.1