When I run "torch.rand(10).to("cuda")", I face "error : Torch not compiled with CUDA enabled"
GPU : Nvidia RTX 3080 Ti
$nvidia-smi
+-----------------------------------------------------------------------------+
| NVIDIA-SMI 525.85.05 Driver Version: 525.85.05 CUDA Version: 12.0 |
|-------------------------------+----------------------+----------------------+
$nvcc -V
nvcc: NVIDIA (R) Cuda compiler driver
Copyright (c) 2005-2017 NVIDIA Corporation
Built on Fri_Nov__3_21:07:56_CDT_2017
Cuda compilation tools, release 9.1, V9.1.85
$conda list
cudatoolkit version : 11.0.221
$conda info
active environment : sw
active env location : /mnt/user2/.conda/envs/sw
shell level : 1
user config file : /mnt/user2/.condarc
populated config files :
conda version : 23.1.0
conda-build version : not installed
python version : 3.10.9.final.0
virtual packages : __archspec=1=x86_64
__glibc=2.27=0
__linux=5.4.0=0
__unix=0=0
base environment : /opt/conda (read only)
conda av data dir : /opt/conda/etc/conda
conda av metadata url : None
channel URLs : https://repo.anaconda.com/pkgs/main/linux-64
https://repo.anaconda.com/pkgs/main/noarch
https://repo.anaconda.com/pkgs/r/linux-64
https://repo.anaconda.com/pkgs/r/noarch
package cache : /opt/conda/pkgs
/mnt/user2/.conda/pkgs
envs directories : /mnt/user2/.conda/envs
/opt/conda/envs
platform : linux-64
user-agent : conda/23.1.0 requests/2.28.1 CPython/3.10.9 Linux/5.4.0-144-generic ubuntu/18.04.6 glibc/2.27
UID:GID : 1002:1001
netrc file : None
offline mode : False
torch ver : 2.0.0
I download pytorch
$ conda install pytorch torchvision torchaudio pytorch-cuda=11.8 -c pytorch -c nvidia
I'm confused to identify cuda version. nvidia-smi says cuda is 12.0 but the sheet from conda list says cuda is 11.0.221 but nvcc-V says cuda 9.1.
If you need more information, please comments.
Searching google to solve the problem but didn't work.