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

The specified module could not be found Error loading caffe2_nvrtc.dll" or one of its dependencies. #14

Open
diogocorreiaf opened this issue Dec 25, 2024 · 7 comments

Comments

@diogocorreiaf
Copy link

GPU: Radeon 7900GRE
OS: Windows 11

Error Installing ComfyUI, i followed your instructions, I even installed automatic1111 before this and works wonders (tyvm)

I will leave the error log bellow

>## ComfyUI-Manager: installing dependencies. (GitPython) [2024-12-25 22:35:35.710] ## ComfyUI-Manager: installing dependencies done. [2024-12-25 22:35:35.710] ** ComfyUI startup time: 2024-12-25 22:35:35.710771 [2024-12-25 22:35:35.722] ** Platform: Windows [2024-12-25 22:35:35.722] ** Python version: 3.10.11 (tags/v3.10.11:7d4cc5a, Apr 5 2023, 00:38:17) [MSC v.1929 64 bit (AMD64)] [2024-12-25 22:35:35.722] ** Python executable: C:\AI\SD-Zluda\ComfyUI\venv\Scripts\python.exe [2024-12-25 22:35:35.722] ** ComfyUI Path: C:\AI\SD-Zluda\ComfyUI [2024-12-25 22:35:35.722] ** Log path: C:\AI\SD-Zluda\ComfyUI\comfyui.log [2024-12-25 22:35:41.369] Prestartup times for custom nodes: [2024-12-25 22:35:41.369] 14.1 seconds: C:\AI\SD-Zluda\ComfyUI\custom_nodes\ComfyUI-Manager [2024-12-25 22:35:41.369] Traceback (most recent call last): [2024-12-25 22:35:41.413] File "C:\AI\SD-Zluda\ComfyUI\main.py", line 89, in <module> [2024-12-25 22:35:41.413] import comfy.utils [2024-12-25 22:35:41.413] File "C:\AI\SD-Zluda\ComfyUI\comfy\utils.py", line 20, in <module> [2024-12-25 22:35:41.414] import torch [2024-12-25 22:35:41.414] File "C:\AI\SD-Zluda\ComfyUI\venv\lib\site-packages\torch\__init__.py", line 143, in <module> [2024-12-25 22:35:41.414] raise err [2024-12-25 22:35:41.414] OSError: [WinError 126] The specified module could not be found. Error loading "C:\AI\SD-Zluda\ComfyUI\venv\lib\site-packages\torch\lib\caffe2_nvrtc.dll" or one of its dependencies.

I'm pretty sure i copied the correct files and renamed them before pasting them

Important notice, the first time i run the bat file (even before copying the files from Zluda) it opens the web user interface but obviously doesnt run.

After i copy and pasted the files i get this error.

@CS1o
Copy link
Owner

CS1o commented Dec 25, 2024

Hey, which HIP SDK Version did you installed? 6.1.2 or 6.2.4 ?
And which ZLUDA Version did you download?
Also make sure your Python 3.10.11 64bit is listed in the Environment Path. If you have Python installed trough the Microsoft Store then uninstall that first and reboot, then delete the venv folder and relaunch.
Also check if its below and not above the normal Python in Path like here:
398600511-e65295d0-1482-4b0e-9ae3-c427c17cbede

Also please screenshot how you added the C:\ZLUDA Folder and the %HIP_PATH%bin to the Environment Path.

@diogocorreiaf
Copy link
Author

Ok so i checked my downloads and I downloaded 6.1.2 version of HIP SDK, but i remember at the time i didn't see anything about pro driver at any point in the install.

the zluda version was also rocm6.

As for the environment variables i simply searched environment variables on windows clicked environment variable on the system properties window that pops up and then added them to the Path variable
hipversion
environmentvars

@CS1o
Copy link
Owner

CS1o commented Dec 26, 2024

The variables need to be in the system environment not in the User environment.
See the example here: #7 (comment)

Change that and reboot the PC. Then delete the venv folder of comfyui and run the comfyui-bat again.
Then replace the DLL files again and relaunch.

@diogocorreiaf
Copy link
Author

diogocorreiaf commented Dec 26, 2024

Ok so i did as you said and changed the variables to be in the system instead of user.

Deleted the venv and ran the bat file again, it actually opens comfyUI.

then it shut if off to put the renamed dlls and now were back to the original error

@CS1o
Copy link
Owner

CS1o commented Dec 26, 2024

Okay, damn. The caffe2 error is the hardest to fix as its cause is not known to 100%.
Its a Path or DLL issue.
Meaning rocm path or python path is not correct.

What you can try is:
Delete the venv of comfyui.
Then open up a cmd and run
Pip cache purge
Then reinstall python 3.10.11 64bit and check its correctly added in the system environment path.
Make sure your on the latest AMD Driver 24.12.1.
Reboot the PC and after that relaunch the ComfyUI bat.
After that replace the DLL files and relaunch it again.

Let me know if that worked.

@diogocorreiaf
Copy link
Author

Well nope that didnt work, guess i will stick with Automatic1111 for now and just roll with it
Thanks for the help.

@CS1o
Copy link
Owner

CS1o commented Jan 10, 2025

No problem. If you want to use Flux you can do that in Forge with Zluda too.
Also if you want to try to get it working again with my help on Discord let me know.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants