Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[WSL-2] lava-dl installation: BUILD FAILED - RuntimeError: CUDA error: no kernel image is available for execution on the device #20

Open
GoHeFa opened this issue Dec 1, 2021 · 11 comments
Assignees
Labels
0-wontfix This will not be worked on 1-bug Something isn't working community Project that could be developed by the neuromorphic community

Comments

@GoHeFa
Copy link

GoHeFa commented Dec 1, 2021

I tried to build lava-dl on my local WSL2 (with Ubuntu 20.04) machine with an RTX 3090 (after successfully installing lava and lava-optimization) and followed therefor the given installation instructions. (I already had a working CUDA 11.5 installation on this machine.)
Unfortunately I received this error:

BUILD FAILED - RuntimeError: CUDA error: no kernel image is available for execution on the device (tests/lava/lib/dl/slayer/neuron/test_adrf_iz.py:45)

Is the RTX 3090 currently not supported? How to resolve this issue? Are there otherwise any workarounds?
Here is the full output:

(base) user@machine:~/miniconda3/lava-dl$ pip install -r build-requirements.txt
Requirement already satisfied: pybuilder in /home/user/miniconda3/lib/python3.8/site-packages (from -r build-requirements.txt (line 1)) (0.13.3)
Requirement already satisfied: flake8 in /home/user/miniconda3/lib/python3.8/site-packages (from -r build-requirements.txt (line 2)) (4.0.1)
Requirement already satisfied: pytest in /home/user/miniconda3/lib/python3.8/site-packages (from -r build-requirements.txt (line 3)) (6.2.5)
Requirement already satisfied: unittest2 in /home/user/miniconda3/lib/python3.8/site-packages (from -r build-requirements.txt (line 4)) (1.1.0)
Requirement already satisfied: bandit in /home/user/miniconda3/lib/python3.8/site-packages (from -r build-requirements.txt (line 5)) (1.7.1)
Requirement already satisfied: coverage in /home/user/miniconda3/lib/python3.8/site-packages (from -r build-requirements.txt (line 6)) (6.2)
Requirement already satisfied: mccabe<0.7.0,>=0.6.0 in /home/user/miniconda3/lib/python3.8/site-packages (from flake8->-r build-requirements.txt (line 2)) (0.6.1)
Requirement already satisfied: pycodestyle<2.9.0,>=2.8.0 in /home/user/miniconda3/lib/python3.8/site-packages (from flake8->-r build-requirements.txt (line 2)) (2.8.0)
Requirement already satisfied: pyflakes<2.5.0,>=2.4.0 in /home/user/miniconda3/lib/python3.8/site-packages (from flake8->-r build-requirements.txt (line 2)) (2.4.0)
Requirement already satisfied: attrs>=19.2.0 in /home/user/miniconda3/lib/python3.8/site-packages (from pytest->-r build-requirements.txt (line 3)) (21.2.0)
Requirement already satisfied: toml in /home/user/miniconda3/lib/python3.8/site-packages (from pytest->-r build-requirements.txt (line 3)) (0.10.2)
Requirement already satisfied: iniconfig in /home/user/miniconda3/lib/python3.8/site-packages (from pytest->-r build-requirements.txt (line 3)) (1.1.1)
Requirement already satisfied: pluggy<2.0,>=0.12 in /home/user/miniconda3/lib/python3.8/site-packages (from pytest->-r build-requirements.txt (line 3)) (1.0.0)
Requirement already satisfied: packaging in /home/user/miniconda3/lib/python3.8/site-packages (from pytest->-r build-requirements.txt (line 3)) (21.3)
Requirement already satisfied: py>=1.8.2 in /home/user/miniconda3/lib/python3.8/site-packages (from pytest->-r build-requirements.txt (line 3)) (1.11.0)
Requirement already satisfied: six>=1.4 in /home/user/miniconda3/lib/python3.8/site-packages (from unittest2->-r build-requirements.txt (line 4)) (1.16.0)
Requirement already satisfied: traceback2 in /home/user/miniconda3/lib/python3.8/site-packages (from unittest2->-r build-requirements.txt (line 4)) (1.4.0)
Collecting argparse
  Using cached argparse-1.4.0-py2.py3-none-any.whl (23 kB)
Requirement already satisfied: stevedore>=1.20.0 in /home/user/miniconda3/lib/python3.8/site-packages (from bandit->-r build-requirements.txt (line 5)) (3.5.0)
Requirement already satisfied: GitPython>=1.0.1 in /home/user/miniconda3/lib/python3.8/site-packages (from bandit->-r build-requirements.txt (line 5)) (3.1.24)
Requirement already satisfied: PyYAML>=5.3.1 in /home/user/miniconda3/lib/python3.8/site-packages (from bandit->-r build-requirements.txt (line 5)) (6.0)
Requirement already satisfied: typing-extensions>=3.7.4.3 in /home/user/miniconda3/lib/python3.8/site-packages (from GitPython>=1.0.1->bandit->-r build-requirements.txt (line 5)) (4.0.0)
Requirement already satisfied: gitdb<5,>=4.0.1 in /home/user/miniconda3/lib/python3.8/site-packages (from GitPython>=1.0.1->bandit->-r build-requirements.txt (line 5)) (4.0.9)
Requirement already satisfied: pbr!=2.1.0,>=2.0.0 in /home/user/miniconda3/lib/python3.8/site-packages (from stevedore>=1.20.0->bandit->-r build-requirements.txt (line 5)) (5.8.0)
Requirement already satisfied: pyparsing!=3.0.5,>=2.0.2 in /home/user/miniconda3/lib/python3.8/site-packages (from packaging->pytest->-r build-requirements.txt (line 3)) (3.0.6)
Requirement already satisfied: linecache2 in /home/user/miniconda3/lib/python3.8/site-packages (from traceback2->unittest2->-r build-requirements.txt (line 4)) (1.0.0)
Requirement already satisfied: smmap<6,>=3.0.1 in /home/user/miniconda3/lib/python3.8/site-packages (from gitdb<5,>=4.0.1->GitPython>=1.0.1->bandit->-r build-requirements.txt (line 5)) (5.0.0)
Installing collected packages: argparse
Successfully installed argparse-1.4.0
(base) user@machine:~/miniconda3/lava-dl$ pip install -r requirements.txt
Requirement already satisfied: torch==1.8.1 in /home/user/miniconda3/lib/python3.8/site-packages (from -r requirements.txt (line 1)) (1.8.1)
Requirement already satisfied: torchvision==0.9.1 in /home/user/miniconda3/lib/python3.8/site-packages (from -r requirements.txt (line 2)) (0.9.1)
Requirement already satisfied: numpy in /home/user/miniconda3/lib/python3.8/site-packages (from -r requirements.txt (line 3)) (1.21.2)
Requirement already satisfied: scipy in /home/user/miniconda3/lib/python3.8/site-packages (from -r requirements.txt (line 4)) (1.7.2)
Requirement already satisfied: matplotlib in /home/user/miniconda3/lib/python3.8/site-packages (from -r requirements.txt (line 5)) (3.5.0)
Requirement already satisfied: ninja in /home/user/miniconda3/lib/python3.8/site-packages (from -r requirements.txt (line 6)) (1.10.2.3)
Requirement already satisfied: h5py>=3.1.0 in /home/user/miniconda3/lib/python3.8/site-packages (from -r requirements.txt (line 7)) (3.6.0)
Requirement already satisfied: typing-extensions in /home/user/miniconda3/lib/python3.8/site-packages (from torch==1.8.1->-r requirements.txt (line 1)) (4.0.0)
Requirement already satisfied: pillow>=4.1.1 in /home/user/miniconda3/lib/python3.8/site-packages (from torchvision==0.9.1->-r requirements.txt (line 2)) (8.4.0)
Requirement already satisfied: fonttools>=4.22.0 in /home/user/miniconda3/lib/python3.8/site-packages (from matplotlib->-r requirements.txt (line 5)) (4.28.1)
Requirement already satisfied: cycler>=0.10 in /home/user/miniconda3/lib/python3.8/site-packages (from matplotlib->-r requirements.txt (line 5)) (0.11.0)
Requirement already satisfied: python-dateutil>=2.7 in /home/user/miniconda3/lib/python3.8/site-packages (from matplotlib->-r requirements.txt (line 5)) (2.8.2)
Requirement already satisfied: kiwisolver>=1.0.1 in /home/user/miniconda3/lib/python3.8/site-packages (from matplotlib->-r requirements.txt (line 5)) (1.3.2)
Requirement already satisfied: setuptools-scm>=4 in /home/user/miniconda3/lib/python3.8/site-packages (from matplotlib->-r requirements.txt (line 5)) (6.3.2)
Requirement already satisfied: pyparsing>=2.2.1 in /home/user/miniconda3/lib/python3.8/site-packages (from matplotlib->-r requirements.txt (line 5)) (3.0.6)
Requirement already satisfied: packaging>=20.0 in /home/user/miniconda3/lib/python3.8/site-packages (from matplotlib->-r requirements.txt (line 5)) (21.3)
Requirement already satisfied: six>=1.5 in /home/user/miniconda3/lib/python3.8/site-packages (from python-dateutil>=2.7->matplotlib->-r requirements.txt (line 5)) (1.16.0)
Requirement already satisfied: setuptools in /home/user/miniconda3/lib/python3.8/site-packages (from setuptools-scm>=4->matplotlib->-r requirements.txt (line 5)) (52.0.0.post20210125)
Requirement already satisfied: tomli>=1.0.0 in /home/user/miniconda3/lib/python3.8/site-packages (from setuptools-scm>=4->matplotlib->-r requirements.txt (line 5)) (1.2.2)
(base) user@machine:~/miniconda3/lava-dl$ pyb -E unit
PyBuilder version 0.13.3
Build started at 2021-12-01 16:10:58
------------------------------------------------------------
[INFO]  Installing or updating plugin "pypi:pybuilder_bandit, module name 'pybuilder_bandit'"
[INFO]  Processing plugin packages 'pybuilder_bandit' to be installed with {}
[INFO]  Activated environments: unit
[INFO]  Building lava-dl version 0.1.1
[INFO]  Executing build in /home/user/miniconda3/lava-dl
[INFO]  Going to execute tasks: analyze, publish
[INFO]  Processing plugin packages 'flake8~=3.7' to be installed with {'upgrade': True}
[INFO]  Processing plugin packages 'pypandoc~=1.4' to be installed with {'upgrade': True}
[INFO]  Processing plugin packages 'setuptools>=38.6.0' to be installed with {'upgrade': True}
[INFO]  Processing plugin packages 'sphinx_rtd_theme' to be installed with {}
[INFO]  Processing plugin packages 'sphinx_tabs' to be installed with {}
[INFO]  Processing plugin packages 'twine>=1.15.0' to be installed with {'upgrade': True}
[INFO]  Processing plugin packages 'unittest-xml-reporting~=3.0.4' to be installed with {'upgrade': True}
[INFO]  Processing plugin packages 'wheel>=0.34.0' to be installed with {'upgrade': True}
[INFO]  Creating target 'build' VEnv in '/home/user/miniconda3/lava-dl/target/venv/build/cpython-3.8.12.final.0'
[INFO]  Processing dependency packages 'requirements.txt' to be installed with {}
[INFO]  Creating target 'test' VEnv in '/home/user/miniconda3/lava-dl/target/venv/test/cpython-3.8.12.final.0'
[INFO]  Processing dependency packages 'requirements.txt' to be installed with {}
[INFO]  Executing flake8 on project sources.
[INFO]  Running unit tests
[INFO]  Executing unit tests from Python modules in /home/user/miniconda3/lava-dl/tests/lava
/home/user/miniconda3/lava-dl/target/venv/build/cpython-3.8.12.final.0/lib/python3.8/site-packages/torch/cuda/__init__.py:104: UserWarning:
NVIDIA GeForce RTX 3090 with CUDA capability sm_86 is not compatible with the current PyTorch installation.
The current PyTorch install supports CUDA capabilities sm_37 sm_50 sm_60 sm_70.
If you want to use the NVIDIA GeForce RTX 3090 GPU with PyTorch, please check the instructions at https://pytorch.org/get-started/locally/

  warnings.warn(incompatible_device_warn.format(device_name, capability, " ".join(arch_list), device_name))
------------------------------------------------------------
BUILD FAILED - RuntimeError: CUDA error: no kernel image is available for execution on the device (tests/lava/lib/dl/slayer/neuron/test_adrf_iz.py:45)
------------------------------------------------------------
Build finished at 2021-12-01 16:11:06
Build took 8 seconds (8015 ms)

I afterwards installed the latest PyTorch version directly from the PyTorch page and re-ran the building process but ran into a similar issue:

(base) user@machine:~/miniconda3/lava-dl$ pip3 install torch==1.10.0+cu113 torchvision==0.11.1+cu113 torchaudio==0.10.0+cu113 -f https://download.pytorch.org/whl/cu113/torch_stable.html
Looking in links: https://download.pytorch.org/whl/cu113/torch_stable.html
Collecting torch==1.10.0+cu113
  Using cached https://download.pytorch.org/whl/cu113/torch-1.10.0%2Bcu113-cp38-cp38-linux_x86_64.whl (1821.4 MB)
Collecting torchvision==0.11.1+cu113
  Using cached https://download.pytorch.org/whl/cu113/torchvision-0.11.1%2Bcu113-cp38-cp38-linux_x86_64.whl (24.6 MB)
Collecting torchaudio==0.10.0+cu113
  Using cached https://download.pytorch.org/whl/cu113/torchaudio-0.10.0%2Bcu113-cp38-cp38-linux_x86_64.whl (2.9 MB)
Requirement already satisfied: typing-extensions in /home/user/miniconda3/lib/python3.8/site-packages (from torch==1.10.0+cu113) (4.0.0)
Requirement already satisfied: numpy in /home/user/miniconda3/lib/python3.8/site-packages (from torchvision==0.11.1+cu113) (1.21.2)
Requirement already satisfied: pillow!=8.3.0,>=5.3.0 in /home/user/miniconda3/lib/python3.8/site-packages (from torchvision==0.11.1+cu113) (8.4.0)
Installing collected packages: torch, torchvision, torchaudio
  Attempting uninstall: torch
    Found existing installation: torch 1.8.1
    Uninstalling torch-1.8.1:
      Successfully uninstalled torch-1.8.1
  Attempting uninstall: torchvision
    Found existing installation: torchvision 0.9.1
    Uninstalling torchvision-0.9.1:
      Successfully uninstalled torchvision-0.9.1
  Attempting uninstall: torchaudio
    Found existing installation: torchaudio 0.8.1
    Uninstalling torchaudio-0.8.1:
      Successfully uninstalled torchaudio-0.8.1
Successfully installed torch-1.10.0+cu113 torchaudio-0.10.0+cu113 torchvision-0.11.1+cu113
(base) user@machine:~/miniconda3/lava-dl$ pyb -E unit
PyBuilder version 0.13.3
Build started at 2021-12-01 16:22:04
------------------------------------------------------------
[INFO]  Installing or updating plugin "pypi:pybuilder_bandit, module name 'pybuilder_bandit'"
[INFO]  Processing plugin packages 'pybuilder_bandit' to be installed with {}
[INFO]  Activated environments: unit
[INFO]  Building lava-dl version 0.1.1
[INFO]  Executing build in /home/user/miniconda3/lava-dl
[INFO]  Going to execute tasks: analyze, publish
[INFO]  Processing plugin packages 'flake8~=3.7' to be installed with {'upgrade': True}
[INFO]  Processing plugin packages 'pypandoc~=1.4' to be installed with {'upgrade': True}
[INFO]  Processing plugin packages 'setuptools>=38.6.0' to be installed with {'upgrade': True}
[INFO]  Processing plugin packages 'sphinx_rtd_theme' to be installed with {}
[INFO]  Processing plugin packages 'sphinx_tabs' to be installed with {}
[INFO]  Processing plugin packages 'twine>=1.15.0' to be installed with {'upgrade': True}
[INFO]  Processing plugin packages 'unittest-xml-reporting~=3.0.4' to be installed with {'upgrade': True}
[INFO]  Processing plugin packages 'wheel>=0.34.0' to be installed with {'upgrade': True}
[INFO]  Creating target 'build' VEnv in '/home/user/miniconda3/lava-dl/target/venv/build/cpython-3.8.12.final.0'
[INFO]  Processing dependency packages 'requirements.txt' to be installed with {}
[INFO]  Creating target 'test' VEnv in '/home/user/miniconda3/lava-dl/target/venv/test/cpython-3.8.12.final.0'
[INFO]  Processing dependency packages 'requirements.txt' to be installed with {}
[INFO]  Executing flake8 on project sources.
[INFO]  Running unit tests
[INFO]  Executing unit tests from Python modules in /home/user/miniconda3/lava-dl/tests/lava
/home/user/miniconda3/lava-dl/target/venv/build/cpython-3.8.12.final.0/lib/python3.8/site-packages/torch/cuda/__init__.py:104: UserWarning:
NVIDIA GeForce RTX 3090 with CUDA capability sm_86 is not compatible with the current PyTorch installation.
The current PyTorch install supports CUDA capabilities sm_37 sm_50 sm_60 sm_70.
If you want to use the NVIDIA GeForce RTX 3090 GPU with PyTorch, please check the instructions at https://pytorch.org/get-started/locally/

  warnings.warn(incompatible_device_warn.format(device_name, capability, " ".join(arch_list), device_name))
------------------------------------------------------------
BUILD FAILED - RuntimeError: CUDA error: no kernel image is available for execution on the device (tests/lava/lib/dl/slayer/neuron/test_adrf_iz.py:45)
------------------------------------------------------------
Build finished at 2021-12-01 16:22:10
Build took 5 seconds (5793 ms)
@bamsumit
Copy link
Contributor

bamsumit commented Dec 7, 2021

Hi @GoHeFa, it looks like your PyTorch installation does not support RTX3090 (cuda compute capability 8.6, i.e. sm 86). This is from your error message

NVIDIA GeForce RTX 3090 with CUDA capability sm_86 is not compatible with the current PyTorch installation.
The current PyTorch install supports CUDA capabilities sm_37 sm_50 sm_60 sm_70.
If you want to use the NVIDIA GeForce RTX 3090 GPU with PyTorch, please check the instructions at https://pytorch.org/get-started/locally/

I am assuming you installed the latest PyTorch version. The solution is to build your PyTorch locally.

Before you do that, let's confirm the following things

  • Are you able to use GPU with your torch?
import torch
x = torch.rand(100)
x = x.to(torch.device('cuda')
  • What are the output of following commands?
python -c "import torch; print(torch.__version__)"
nvidia-smi | grep CUDA
nvcc --version | grep release
gcc --version
  • I assume you are using insider build of windows to access GPU from WSL2. How did you verify that cuda is working?

@GoHeFa
Copy link
Author

GoHeFa commented Dec 8, 2021

@bamsumit First of all, thanks for your response.
I rechecked the torch version compatibility with another project (pure python/PyTorch with GPU usage) I am working on.
With torch == 1.8.1 and torchvision == 0.9.1 successfully installed (with pip3), during runtime I get the error:

NVIDIA GeForce RTX 3090 with CUDA capability sm_86 is not compatible with the current PyTorch installation.
The current PyTorch install supports CUDA capabilities sm_37 sm_50 sm_60 sm_70.
If you want to use the NVIDIA GeForce RTX 3090 GPU with PyTorch, please check the instructions at https://pytorch.org/get-started/locally/

After successfully installing the latest PyTorch version via: pip3 install torch==1.10.0+cu113 torchvision==0.11.1+cu113 torchaudio==0.10.0+cu113 -f https://download.pytorch.org/whl/cu113/torch_stable.html I can successfully run my code without any errors or warnings.

Now to your tests:

  • Are you able to use GPU with your torch?
import torch
x = torch.rand(100)
x = x.to(torch.device('cuda'))

Works fine without any errors with the latest PyTorch version installed (with the pip3 command depicted above). While with torch == 1.8.1 and torchvision == 0.9.1 I receive the error described above.

  • What are the output of following commands?
    (Output received with the latest PyTorch version installed.)
(base) user@machine:~/miniconda3/lava-dl$ python -c "import torch; print(torch.__version__)"
1.10.0+cu113
(base) user@machine:~/miniconda3/lava-dl$ nvidia-smi | grep CUDA
| NVIDIA-SMI 510.00       Driver Version: 510.06       CUDA Version: 11.6     |
(base) user@machine:~/miniconda3/lava-dl$ nvcc --version | grep release
Cuda compilation tools, release 11.5, V11.5.119
(base) user@machine:~/miniconda3/lava-dl$ gcc --version
gcc (Ubuntu 9.3.0-17ubuntu1~20.04) 9.3.0
Copyright (C) 2019 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  • I assume you are using insider build of windows to access GPU from WSL2. How did you verify that cuda is working?
    I am not using the insider built of Windows. My current Microsoft Windows 10 version is Microsoft Windows [Version 10.0.19044.1387].
    Furthermore, entering wsl -l -v into a PowerShell gives me:
  NAME            STATE           VERSION
* Ubuntu-20.04    Running         2

To verify that my CUDA installation is working I only did: (Honestly, hence describing it as "working" is not appropriate.)

nvidia-smi | grep CUDA
nvcc --version | grep release

Also, entering nvidia-smi in my Power Shell or in a WSL shell yields the expected output.

@bamsumit
Copy link
Contributor

bamsumit commented Dec 8, 2021

So are you able to run lava-dl with torch 1.10.0+cu113 or not?

@bamsumit bamsumit self-assigned this Dec 8, 2021
@GoHeFa
Copy link
Author

GoHeFa commented Dec 8, 2021

Unfortunately I am noch able to build lava-dl with torch 1.10.0+cu113 (while normal PyTorch GPU execution works fine).

(base) user@machine:~/miniconda3/lava-dl$ pip3 install torch==1.10.0+cu113 torchvision==0.11.1+cu113 torchaudio==0.10.0+cu113 -f https://download.pytorch.org/whl/cu113/torch_stable.html
Looking in links: https://download.pytorch.org/whl/cu113/torch_stable.html
Requirement already satisfied: torch==1.10.0+cu113 in /home/user/miniconda3/lib/python3.8/site-packages (1.10.0+cu113)
Requirement already satisfied: torchvision==0.11.1+cu113 in /home/user/miniconda3/lib/python3.8/site-packages (0.11.1+cu113)
Requirement already satisfied: torchaudio==0.10.0+cu113 in /home/user/miniconda3/lib/python3.8/site-packages (0.10.0+cu113)
Requirement already satisfied: typing-extensions in /home/user/miniconda3/lib/python3.8/site-packages (from torch==1.10.0+cu113) (4.0.0)
Requirement already satisfied: pillow!=8.3.0,>=5.3.0 in /home/user/miniconda3/lib/python3.8/site-packages (from torchvision==0.11.1+cu113) (8.4.0)
Requirement already satisfied: numpy in /home/user/miniconda3/lib/python3.8/site-packages (from torchvision==0.11.1+cu113) (1.21.2)
(base) user@machine:~/miniconda3/lava-dl$ pyb -E unit
PyBuilder version 0.13.3
Build started at 2021-12-08 18:13:13
------------------------------------------------------------
[INFO]  Installing or updating plugin "pypi:pybuilder_bandit, module name 'pybuilder_bandit'"
[INFO]  Processing plugin packages 'pybuilder_bandit' to be installed with {}
[INFO]  Activated environments: unit
[INFO]  Building lava-dl version 0.1.1
[INFO]  Executing build in /home/user/miniconda3/lava-dl
[INFO]  Going to execute tasks: analyze, publish
[INFO]  Processing plugin packages 'flake8~=3.7' to be installed with {'upgrade': True}
[INFO]  Processing plugin packages 'pypandoc~=1.4' to be installed with {'upgrade': True}
[INFO]  Processing plugin packages 'setuptools>=38.6.0' to be installed with {'upgrade': True}
[INFO]  Processing plugin packages 'sphinx_rtd_theme' to be installed with {}
[INFO]  Processing plugin packages 'sphinx_tabs' to be installed with {}
[INFO]  Processing plugin packages 'twine>=1.15.0' to be installed with {'upgrade': True}
[INFO]  Processing plugin packages 'unittest-xml-reporting~=3.0.4' to be installed with {'upgrade': True}
[INFO]  Processing plugin packages 'wheel>=0.34.0' to be installed with {'upgrade': True}
[INFO]  Creating target 'build' VEnv in '/home/user/miniconda3/lava-dl/target/venv/build/cpython-3.8.12.final.0'
[INFO]  Processing dependency packages 'requirements.txt' to be installed with {}
[INFO]  Creating target 'test' VEnv in '/home/user/miniconda3/lava-dl/target/venv/test/cpython-3.8.12.final.0'
[INFO]  Processing dependency packages 'requirements.txt' to be installed with {}
[INFO]  Executing flake8 on project sources.
[INFO]  Running unit tests
[INFO]  Executing unit tests from Python modules in /home/user/miniconda3/lava-dl/tests/lava
/home/user/miniconda3/lava-dl/target/venv/build/cpython-3.8.12.final.0/lib/python3.8/site-packages/torch/cuda/__init__.py:104: UserWarning:
NVIDIA GeForce RTX 3090 with CUDA capability sm_86 is not compatible with the current PyTorch installation.
The current PyTorch install supports CUDA capabilities sm_37 sm_50 sm_60 sm_70.
If you want to use the NVIDIA GeForce RTX 3090 GPU with PyTorch, please check the instructions at https://pytorch.org/get-started/locally/

  warnings.warn(incompatible_device_warn.format(device_name, capability, " ".join(arch_list), device_name))
------------------------------------------------------------
BUILD FAILED - RuntimeError: CUDA error: no kernel image is available for execution on the device (/home/user/miniconda3/lava-dl/tests/lava/lib/dl/slayer/neuron/test_adrf_iz.py:45)
------------------------------------------------------------
Build finished at 2021-12-08 18:13:19
Build took 6 seconds (6421 ms)

@bamsumit bamsumit added the 1-bug Something isn't working label Dec 8, 2021
@bamsumit
Copy link
Contributor

bamsumit commented Dec 8, 2021

I would try re-installing nvidia driver and nvcc compiler for cuda 11.3 and try again (currently you have them at 11.6 and 11.5). If that does not work, I am afraid you will have to build pytorch from source locally.

@bamsumit bamsumit changed the title lava-dl installation: BUILD FAILED - RuntimeError: CUDA error: no kernel image is available for execution on the device [WSL-2] lava-dl installation: BUILD FAILED - RuntimeError: CUDA error: no kernel image is available for execution on the device Dec 8, 2021
@mgkwill
Copy link
Contributor

mgkwill commented Feb 10, 2022

I would try re-installing nvidia driver and nvcc compiler for cuda 11.3 and try again (currently you have them at 11.6 and 11.5). If that does not work, I am afraid you will have to build pytorch from source locally.

Hi @GoHeFa did @bamsumit's suggestion fix the issue?

@GoHeFa
Copy link
Author

GoHeFa commented Feb 10, 2022

@mgkwill Unfortunately, it's currently not possible for me to test the suggestion, hence I can't tell you.

@VishalPathak-GTRI
Copy link

Has anyone else had this issue? I'm having the exact same problem at the moment, here are some of the requested outputs:

image
image

@bamsumit
Copy link
Contributor

bamsumit commented Mar 8, 2022

@VishalPathak-GTRI are you also running it in WSL-2?

First thing I would check is to check if you can compile and run cuda code using nvcc.

@uslumt
Copy link
Contributor

uslumt commented Jun 24, 2022

Hello everyone, I'm able to train pytorch model on gpu using cuda however with the same set up on LAVA blocks gives an error.
torch 1.10.1+cu111
torch-encoding 1.2.1
torchaudio 0.10.1+rocm4.1
torchsummary 1.5.1
torchvision 0.11.2+cu111

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

NVIDIA-SMI 495.29.05 Driver Version: 495.29.05 CUDA Version: 11.5

error :
nvcc fatal : Unsupported gpu architecture 'compute_80'
ninja: build stopped: subcommand failed.

@bamsumit
Copy link
Contributor

@uslumt , can you try updating your nvcc compiler to v 11.5?

@bamsumit bamsumit added 0-wontfix This will not be worked on community Project that could be developed by the neuromorphic community and removed 0-needs-review labels Jan 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
0-wontfix This will not be worked on 1-bug Something isn't working community Project that could be developed by the neuromorphic community
Projects
None yet
Development

No branches or pull requests

6 participants