dustysys / ddetailer

340 stars 74 forks source link

Error loading script: ddetailer.py #59

Closed rasydev closed 9 months ago

rasydev commented 1 year ago

Please help me I got error like this

Error loading script: ddetailer.py Traceback (most recent call last): File "E:\Document AI\stable-diffusion\stable-diffusion-webui\modules\scripts.py", line 257, in load_scripts script_module = script_loading.load_module(scriptfile.path) File "E:\Document AI\stable-diffusion\stable-diffusion-webui\modules\script_loading.py", line 11, in load_module module_spec.loader.exec_module(module) File "", line 883, in exec_module File "", line 241, in _call_with_frames_removed File "E:\Document AI\stable-diffusion\stable-diffusion-webui\extensions\ddetailer\scripts\ddetailer.py", line 61, in startup() File "E:\Document AI\stable-diffusion\stable-diffusion-webui\extensions\ddetailer\scripts\ddetailer.py", line 49, in startup run(f'"{python}" -m mim install mmcv-full', desc=f"Installing mmcv-full", errdesc=f"Couldn't install mmcv-full") File "E:\Document AI\stable-diffusion\stable-diffusion-webui\launch.py", line 111, in run raise RuntimeError(message) RuntimeError: Couldn't install mmcv-full. Command: "E:\Document AI\stable-diffusion\stable-diffusion-webui\venv\Scripts\python.exe" -m mim install mmcv-full Error code: 1 stdout: Looking in links: https://download.openmmlab.com/mmcv/dist/cu118/torch2.0.0/index.html Collecting mmcv-full Using cached mmcv-full-1.7.1.tar.gz (605 kB) Preparing metadata (setup.py): started Preparing metadata (setup.py): finished with status 'error'

stderr: WARNING: Ignoring invalid distribution -rotobuf (e:\document ai\stable-diffusion\stable-diffusion-webui\venv\lib\site-packages) error: subprocess-exited-with-error

python setup.py egg_info did not run successfully. exit code: 1

[14 lines of output] Traceback (most recent call last): File "", line 2, in File "", line 34, in File "C:\Users\Rika Me\AppData\Local\Temp\pip-install-7_zi4dsu\mmcv-full_303a581eb7114da6bb4f48b14e9511c7\setup.py", line 465, in ext_modules=get_extensions(), File "C:\Users\Rika Me\AppData\Local\Temp\pip-install-7_zi4dsu\mmcv-full_303a581eb7114da6bb4f48b14e9511c7\setup.py", line 369, in get_extensions ext_ops = extension( File "E:\Document AI\stable-diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\utils\cpp_extension.py", line 1048, in CUDAExtension library_dirs += library_paths(cuda=True) File "E:\Document AI\stable-diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\utils\cpp_extension.py", line 1186, in library_paths paths.append(_join_cuda_home(lib_dir)) File "E:\Document AI\stable-diffusion\stable-diffusion-webui\venv\lib\site-packages\torch\utils\cpp_extension.py", line 2223, in _join_cuda_home raise EnvironmentError('CUDA_HOME environment variable is not set. ' OSError: CUDA_HOME environment variable is not set. Please set it to your CUDA install root. [end of output]

jmarasch commented 1 year ago

has there been any movement on this? I'm having the same issue.

naduarte2 commented 1 year ago

That error of CUDA_HOME is because you don't have it installed, also you need a C++ compiler to install mmcv and mmdet, so you need to have installed:

FYI, never install the last CUDA Toolkit (now 12.2), because Pytorch is not compatible yet, so 11.8 is the option to follow for now.