Comfy-Org / Comfy-Org/ComfyUI

Framework Desktop AMD 395+ (rdna 3.5) cannot run confyui error msg says no cuda cores available

Open
#14,326 6 comments 0 reactions 0 assignees View on GitHub
Potential Bug
Dominant language
Python
Stars
133k
Forks
15.7k
Avg merge
1d 7h
Merged PRs (30d)
158

Description

### Custom Node Testing

- [x] I have tried disabling custom nodes and the issue persists (see [how to disable custom nodes](https://docs.comfy.org/troubleshooting/custom-node-issues#step-1%3A-test-with-all-custom-nodes-disabled) if you need help)

### Expected Behavior

Run the command to launch comfy ui and it would load up...

### Actual Behavior

Ubuntu Terminal gives error about cuda cores not being present despite not using //ANY// of the nvidia instruction and using both the rocm7.2 stable and the experimental rdna 3.5 rocm torch related instructions.

Image

### Steps to Reproduce

As it is my intent to get this running inside a KASM Docker (with /dev/dri/card1 & /dev/dri/renderD128 passed through) and thus I need to make a Dockerfile I actually have this down to a single if long command.

My testing has been me putting the commands into the terminal seeing and fixing errors and then copying what works to my dockerfile-inprogress.

The command I have is thus:
`sudo apt-get update \
&& sudo apt-get upgrade -y \
&& sudo apt-get install -y sudo git bash python3 python3-venv python3-dev build-essential libgl1 ssh systemd-timesyncd pip \
&& sudo mkdir /opt/comfyui \
&& sudo chmod 777 /opt/comfyui \
&& git clone https://github.com/Comfy-Org/ComfyUI.git /opt/comfyui \
&& cd /opt/comfyui \
&& python3 -m venv .venv \
&& source .venv/bin/activate \
&& pip install --upgrade pip wheel \
&& pip install --pre torch torchvision torchaudio --index-url https://rocm.nightlies.amd.com/v2/gfx1151/ \
&& pip install -r requirements.txt`

Prior to the above: In my troubleshooting and when I was freehanding it more then a guide I found I had a slightly different version of ubuntu (noble vs jammy) which complained about my trying to use pip directly (the way the github instructions says to, the guide I found showed me how to do it with venv's I had come up with the following which also does not work:

`sudo apt-get update \
&& sudo apt-get upgrade - y \
&& sudo apt-get install -y sudo git bash python3 pip \
&& sudo pip install --upgrade pip wheel
&& sudo pip install --pre torch torchvision torchaudio --index-url https://rocm.nightlies.amd.com/v2/gfx1151/ --break-system-packages \
&& sudo mkdir /opt/comfyui \
&& sudo chmod 777 /opt/comfyui \
&& git clone https://github.com/Comfy-Org/ComfyUI.git /opt/comfyui \
&& cd /opt/comfyui \
&& sudo pip install --upgrade pip wheel --break-system-packages\
&& sudo pip install -r requirements.txt --break-system-packages`

The --break-system-packages flag was required to make pip work at all on that build of ubuntu without a venv.

I also Tried a entirely different linux distro (same hardware)with fedora hoping for different results and the error was slightly different and the lines of code referenced were like 2~3 lines different then the ubuntu version but otherwise the same. Also these linux environments are clean with nothing else installed yet.

Fedora error attached here

Image

I also tried with the disable all custom nodes, and with the directml flags but so far, google, reddit, and the install page and the one liner troubleshooting tip about uninstalling torch have not yielded any fruit

### Debug Logs

```powershell
(.venv) default:/opt/comfyui$ python3 main.py
[INFO] setup plugin alembic.autogenerate.schemas
[INFO] setup plugin alembic.autogenerate.tables
[INFO] setup plugin alembic.autogenerate.types
[INFO] setup plugin alembic.autogenerate.constraints
[INFO] setup plugin alembic.autogenerate.defaults
[INFO] setup plugin alembic.autogenerate.comments
[INFO] Successfully registered DSL: cutedsl
[INFO] Successfully registered DSL: triton
[INFO] Found comfy_kitchen backend triton: {'available': False, 'disabled': True, 'unavailable_reason': 'Neither CUDA nor XPU available on this system', 'capabilities': []}
[INFO] Found comfy_kitchen backend eager: {'available': True, 'disabled': False, 'unavailable_reason': None, 'capabilities': ['apply_rope', 'apply_rope1', 'apply_rope_split_half', 'apply_rope_split_half1', 'dequantize_mxfp8', 'dequantize_nvfp4', 'dequantize_per_tensor_fp8', 'gemv_awq_w4a16', 'quantize_mxfp8', 'quantize_nvfp4', 'quantize_per_tensor_fp8', 'quantize_svdquant_w4a4', 'scaled_mm_mxfp8', 'scaled_mm_nvfp4', 'scaled_mm_svdquant_w4a4', 'stochastic_rounding_fp8']}
[INFO] Found comfy_kitchen backend cuda: {'available': False, 'disabled': True, 'unavailable_reason': 'CUDA not available on this system', 'capabilities': []}
[INFO] Checkpoint files will always be loaded safely.
Traceback (most recent call last):
File "/opt/comfyui/main.py", line 206, in
import execution
File "/opt/comfyui/execution.py", line 18, in
import comfy.model_management
File "/opt/comfyui/comfy/model_management.py", line 362, in
total_vram = get_total_memory(get_torch_device()) / (1024 * 1024)
File "/opt/comfyui/comfy/model_management.py", line 211, in get_torch_device
return torch.device(torch.cuda.current_device())
File "/opt/comfyui/.venv/lib/python3.10/site-packages/torch/cuda/__init__.py", line 1165, in current_device
_lazy_init()
File "/opt/comfyui/.venv/lib/python3.10/site-packages/torch/cuda/__init__.py", line 489, in _lazy_init
torch._C._cuda_init()
RuntimeError: No CUDA GPUs are available
```

### Other

_No response_

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.