Torch not compiled with CUDA enabled: verify the build and the intended backend
This error can mean a CPU-only Torch build was installed, but it can also come from a node calling CUDA where the selected build or backend cannot provide it.
Symptoms and scope
This error can mean a CPU-only Torch build was installed, but it can also come from a node calling CUDA where the selected build or backend cannot provide it.
Error fragments for search; IDs, values and filenames may vary:
Torch not compiled with CUDA enabled
Source-supported context
PyTorch publishes platform-specific installation choices. A Portable user reported this error after a dependency update, but the report does not establish which package changed. A separate Mac report traces a CUDA call through a custom-node workflow; those are different scenarios. Source 1 Source 2 Source 3 Source 4
Cases to distinguish
1. CPU-only Torch or a different interpreter is being used for a NVIDIA workflow.
2. A dependency update may have changed the Torch build; compare versions before assigning a cause.
3. A node expects CUDA although the selected machine uses a different backend.
Diagnostic sequence
The sequence below is an editorial procedure based on the cited context, not a diagnosis already confirmed for your environment.
Step 1. Print the executable, Torch version, torch.version.cuda and availability result from the runtime that launches ComfyUI.
Step 2. For NVIDIA, check the official installation choice and the node's requirements together. Recover a coherent torch/torchvision/torchaudio set in a reversible environment.
Step 3. For other hardware, use a supported backend and compatible nodes rather than installing an NVIDIA-only wheel by habit.
Step 4. Establish a native baseline before reintroducing the node that caused the problem.
Commands and request examples
Use the environment and shell identified above. Paths and variables are examples to adapt; these commands/snippets were not executed for your machine. Portable examples run from the package root. A virtual environment or managed launcher can use a different executable layout.
python -c "import sys,torch; print(sys.executable); print(torch.__version__); print(torch.version.cuda); print(torch.cuda.is_available())"
For Windows Portable, run the same read-only check from the extracted package root with its embedded interpreter instead of a system Python:
.\python_embeded\python.exe -c "import sys,torch; print(sys.executable); print(torch.__version__); print(torch.version.cuda); print(torch.cuda.is_available())"
Completion check
The core workflow executes on the intended backend and the node's assumptions match it.
Limitations and cautions
The CUDA version displayed by a driver tool is not the same as Torch's bundled build. PyTorch's ROCm build also uses the torch.cuda API, so the API name or a None value from torch.version.cuda alone does not prove that an NVIDIA wheel is needed. Read those values with the selected build and hardware. PyTorch HIP semantics This message alone does not prove that the driver is defective.
Original sources
- PyTorch local installation — original record checked 2026-09-21.
- ComfyUI Portable Windows — original record checked 2026-09-21.
- Torch not compiled with CUDA after dependency update — original record checked 2026-09-21.
- Mac custom node requests CUDA — original record checked 2026-09-21.
- PyTorch HIP (ROCm) semantics — checked 2026-09-25.
Localization prepared: 2026-09-22. The source-check dates above were inherited from the existing article; this translation does not claim they were all rechecked today. No GPU run, minimum-memory measurement or runtime guarantee is supplied.
Related troubleshooting and guides
Was this page helpful?
Anonymous. Only a yes/no counter is stored; no account, IP address or device details.
Sources & references
Localized from the existing Chinese research draft. Original source-check dates are retained; this translation is not new technical verification or a runtime test.
01PyTorch local installationSource checked: 2026-09-2102ComfyUI Portable WindowsSource checked: 2026-09-2103Torch not compiled with CUDA after dependency updateSource checked: 2026-09-2104Mac custom node requests CUDASource checked: 2026-09-2105PyTorch HIP (ROCm) semanticsSource checked: 2026-09-25