Error with run_windows.bat
RuntimeError: CUDA error: no kernel image is available for execution on the device
I have a Windows 10 machine with Nvidia GTX Titan card. Nvidia says it supports CUDA 3.5 which I think is the minimum required?
Also I read in the notes that it should fall to the CPU if the GPU isn't supported? How would I configure that if the card is the problem?
One possible solution is to downgrade Pytorch
conda activate avatarify
conda install pytorch==1.0.0 torchvision==0.2.1 cuda100 -c pytorch
This is a relative issue
I had to downgrade Python to 3.7 at the same time... but now I'm seeing this error
(avatarify) c:\GIT_Repos\avatarify>run_windows.bat
(avatarify) c:\GIT_Repos\avatarify>REM Web-camera device id
(avatarify) c:\GIT_Repos\avatarify>set CAMID=0
(avatarify) c:\GIT_Repos\avatarify>REM ################################################
(avatarify) c:\GIT_Repos\avatarify>REM Normally you don't want to change settings below
(avatarify) c:\GIT_Repos\avatarify>REM Conda environment name
(avatarify) c:\GIT_Repos\avatarify>set CONDA_ENV_NAME=avatarify
(avatarify) c:\GIT_Repos\avatarify>REM @set /P CAMID="Pick the webcam id you want to use (typically "0"): "
Traceback (most recent call last):
File "cam_fomm.py", line 11, in
reinstalled a different version of python but I'm still ending up with CUDA error: no kernel image is available for execution on the device
Is there a way to force it not to use the GPU as you suggest in the readme?
Before run, call
set CUDA_VISIBLE_DEVICES=''
I'm afraid you will be disappointed with the performance.
yeah I get a similar issue like this:

PATH:
C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.2\bin;
C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.2\libnvvp;
or do I need to also set the CUDA path variables to:
CUDA_PATH_V10_2=C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.2
CUDA_PATH=C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.2
??
Any idea how to work around this?
Something else is weird.
the conda (base) is python 3.7, while the conda (avatarify) is using py3.8. Is that correct?
Something else is weird. the
conda (base)is python 3.7, while theconda (avatarify)is using py3.8. Is that correct?
It is correct
Cuda installation is under question. Looks like Pytorch has Cuda runtime with itself. You can try removing Cuda from your computer, install the latest nVidia driver and re-install avatarify.
You can try removing Cuda from your computer, install the latest nVidia driver and re-install avatarify.
That's a no go because:
- I use CUDA successfully with other apps
- I already have the latest nVidia driver
- avatarify works, but apparently without CUDA because of the error above.
My question is if downgrading pytorch would solve it. I still need to try that.
What GPU you have?
Building Pytoch from source may be an option.
@alievk
What GPU you have?
An older one: GTX 850M
I also tried:
conda install pytorch==1.0.0 torchvision==0.2.1 cuda100 -c pytorch
Which gave the following errors:
(base) D:\avatarify\avatarify\avatars>conda activate avatarify
(avatarify) D:\avatarify\avatarify\avatars>conda install pytorch==1.0.0 torchvision==0.2.1 cuda100 -c pytorch
Collecting package metadata (current_repodata.json): done
Solving environment: failed with initial frozen solve. Retrying with flexible solve.
Solving environment: failed with repodata from current_repodata.json, will retry with next repodata source.
Collecting package metadata (repodata.json): done
Solving environment: failed with initial frozen solve. Retrying with flexible solve.
Solving environment: -
Found conflicts! Looking for incompatible packages.
This can take several minutes. Press CTRL-C to abort.
failed
# >>>>>>>>>>>>>>>>>>>>>> ERROR REPORT <<<<<<<<<<<<<<<<<<<<<<
Traceback (most recent call last):
...
raise UnsatisfiableError({})
conda.exceptions.UnsatisfiableError:
Did not find conflicting dependencies. If you would like to know which
packages conflict ensure that you have enabled unsatisfiable hints.
conda config --set unsatisfiable_hints True
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
...
TypeError: sequence item 0: expected str instance, Channel found
@alievk
What GPU you have?
An older one:
GTX 850M
Usually CUDA works well on GTX Gen 10 and upper (1060,1070,1080,2060,2070,2080). Others graphics always shows errors. I don't know why but I tried CUDA on GT950 and fails.
Before run, call
set CUDA_VISIBLE_DEVICES=''I'm afraid you will be disappointed with the performance.
You were right of course... but I was glad to see it working at all. If I get access to a better graphics card than my GXT Titan then I'll give it another go sometime... or if you ever figure out a way to make it work on my card I'll also be keen to try it
Thanks @alievk
set CUDA_VISIBLE_DEVICES=''
I tried that, and it totally killed my frame rate. But this is a good sign for me, because it proved that CUDA was actually working for me on my very old shitty graphics card or ??
Are there any better ways to check if CUDA is running?
Are there any better ways to check if CUDA is running?
You can use nvidia-smi tool https://forums.developer.nvidia.com/t/nvidia-smi/59840/5
c:
cd \Program Files\NVIDIA Corporation\NVSMI
nvidia-smi
+-----------------------------------------------------------------------------+
| NVIDIA-SMI 442.19 Driver Version: 442.19 CUDA Version: 10.2 |
|-------------------------------+----------------------+----------------------+
| GPU Name TCC/WDDM | Bus-Id Disp.A | Volatile Uncorr. ECC |
| Fan Temp Perf Pwr:Usage/Cap| Memory-Usage | GPU-Util Compute M. |
|===============================+======================+======================|
| 0 GeForce GTX 850M WDDM | 00000000:01:00.0 Off | N/A |
| N/A 62C P8 N/A / N/A | 100MiB / 4096MiB | 0% Default |
+-------------------------------+----------------------+----------------------+
+-----------------------------------------------------------------------------+
| Processes: GPU Memory |
| GPU PID Type Process name Usage |
|=============================================================================|
| No running processes found |
+-----------------------------------------------------------------------------+
PS. I fixed this by fixing the cuda100 to cuda102 in the install script and making sure the windows system paths pointes to the right cuda locations. I think it was also fixable by copying the cudaart64_102.dll into the windows installed path of the "blahblah Program Files ../CUDA/balabla" directory.
INVIDIA RTX 4070 , WINDOWS 11 , DRIVER TYPE DCH have already install drivers update and have also installed cuda
Traceback (most recent call last):
File "afy/cam_fomm.py", line 316, in cusparseCreate(handle)
any help to fix RuntimeError: CUDA error: operation not supported when calling