ComfyUI icon indicating copy to clipboard operation
ComfyUI copied to clipboard

Error loading caffe2_nvrtc.dll or one of its dependencies.

Open tenrandomdigits opened this issue 2 years ago • 1 comments

I've just installed, and this is what I get every time I try to run ComfyUI on Windows:

$ python main.py Traceback (most recent call last): File "X:\SD\ComfyUI\main.py", line 66, in import comfy.utils File "X:\SD\ComfyUI\comfy\utils.py", line 1, in import torch File "C:\Users\tenra\AppData\Roaming\Python\Python310\site-packages\torch_init_.py", line 133, in raise err OSError: [WinError 126] The specified module could not be found. Error loading "C:\Users\tenra\AppData\Roaming\Python\Python310\site-packages\torch\lib\caffe2_nvrtc.dll" or one of its dependencies.

caffe2_nvrtc.dll does in fact exist in that directory!

I've tried to reinstall torch with pip and pip3. I've tried to add this directory to my PATH. Also tried the standalone package.

My Automatic1111 installation works fine, and the ComfyUI extension within it works fine too.

Any help would be much appreciated

tenrandomdigits avatar Jul 27 '23 01:07 tenrandomdigits

My comfy-zluda has been working correctly before, today I've launched it, updated it, and after first try of generation it crashed and no longer opens.

I have the same issue as you.

[START] Security scan
[DONE] Security scan
## ComfyUI-Manager: installing dependencies done.
** ComfyUI startup time: 2024-08-18 20:33:14.314398
** Platform: Windows
** Python version: 3.10.6 (tags/v3.10.6:9c7b4bd, Aug  1 2022, 21:53:49) [MSC v.1932 64 bit (AMD64)]
** Python executable: P:\StableDiffusion\ComfyUI-Zluda\venv\Scripts\python.exe
** ComfyUI Path: P:\StableDiffusion\ComfyUI-Zluda
** Log path: P:\StableDiffusion\ComfyUI-Zluda\comfyui.log

Prestartup times for custom nodes:
   0.0 seconds: P:\StableDiffusion\ComfyUI-Zluda\custom_nodes\rgthree-comfy
   2.1 seconds: P:\StableDiffusion\ComfyUI-Zluda\custom_nodes\ComfyUI-Manager

Traceback (most recent call last):
  File "P:\StableDiffusion\ComfyUI-Zluda\main.py", line 73, in <module>
    import comfy.utils
  File "P:\StableDiffusion\ComfyUI-Zluda\comfy\utils.py", line 1, in <module>
    import torch
  File "P:\StableDiffusion\ComfyUI-Zluda\venv\lib\site-packages\torch\__init__.py", line 141, in <module>
    raise err
OSError: [WinError 126] The specified module could not be found. Error loading "P:\StableDiffusion\ComfyUI-Zluda\venv\lib\site-packages\torch\lib\caffe2_nvrtc.dll" or one of its dependencies.

I've tried running install.bat but it does not help.

Acrivec avatar Aug 18 '24 18:08 Acrivec