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

dll load failed while importing "onnxruntime_pybind11_state" #33

Open
DiegoRRR opened this issue Feb 21, 2024 · 1 comment
Open

dll load failed while importing "onnxruntime_pybind11_state" #33

DiegoRRR opened this issue Feb 21, 2024 · 1 comment

Comments

@DiegoRRR
Copy link

Since I installed stable-diffusion-webui-rembg I have this error :

venv "D:\apps\stable-diffusion\webui__automatic1111\webui\venv\Scripts\Python.ex
e"
Python 3.10.6 (main, Sep 19 2022, 15:45:37) [MSC v.1933 64 bit (AMD64)]
Version: v1.7.0
Commit hash: cf2772fab0af5573da775e7437e6acdca424f26e
Launching Web UI with arguments: --xformers --skip-torch-cuda-test --medvram-sdx
l
Style database not found: D:\apps\stable-diffusion\webui__automatic1111\webui\st
yles.csv
ControlNet preprocessor location: D:\apps\stable-diffusion\webui__automatic1111
webui\extensions\sd-webui-controlnet\annotator\downloads
2024-02-21 22:46:36,993 - ControlNet - INFO - ControlNet v1.1.438
2024-02-21 22:46:37,165 - ControlNet - INFO - ControlNet v1.1.438
*** Error loading script: api.py
Traceback (most recent call last):
File "D:\apps\stable-diffusion\webui__automatic1111\webui\modules\scripts.
py", line 469, in load_scripts
script_module = script_loading.load_module(scriptfile.path)
File "D:\apps\stable-diffusion\webui__automatic1111\webui\modules\script_l
oading.py", line 10, in load_module
module_spec.loader.exec_module(module)
File "", line 883, in exec_module
File "", line 241, in call_with_frames_remov
ed
File "D:\apps\stable-diffusion\webui__automatic1111\webui\extensions\stabl
e-diffusion-webui-rembg\scripts\api.py", line 7, in
import rembg
File "D:\apps\stable-diffusion\webui__automatic1111\webui\venv\lib\site-pa
ckages\rembg_init
.py", line 5, in
from .bg import remove
File "D:\apps\stable-diffusion\webui__automatic1111\webui\venv\lib\site-pa
ckages\rembg\bg.py", line 21, in
from .session_factory import new_session
File "D:\apps\stable-diffusion\webui__automatic1111\webui\venv\lib\site-pa
ckages\rembg\session_factory.py", line 4, in
import onnxruntime as ort
File "D:\apps\stable-diffusion\webui__automatic1111\webui\venv\lib\site-pa
ckages\onnxruntime_init_.py", line 56, in
raise import_capi_exception
File "D:\apps\stable-diffusion\webui__automatic1111\webui\venv\lib\site-pa
ckages\onnxruntime_init_.py", line 23, in
from onnxruntime.capi._pybind_state import ExecutionMode # noqa: F401
File "D:\apps\stable-diffusion\webui__automatic1111\webui\venv\lib\site-pa
ckages\onnxruntime\capi_pybind_state.py", line 32, in
from .onnxruntime_pybind11_state import * # noqa
ImportError: DLL load failed while importing onnxruntime_pybind11_state: La
procédure spécifiée est introuvable.


*** Error loading script: postprocessing_rembg.py
Traceback (most recent call last):
File "D:\apps\stable-diffusion\webui__automatic1111\webui\modules\scripts.
py", line 469, in load_scripts
script_module = script_loading.load_module(scriptfile.path)
File "D:\apps\stable-diffusion\webui__automatic1111\webui\modules\script_l
oading.py", line 10, in load_module
module_spec.loader.exec_module(module)
File "", line 883, in exec_module
File "", line 241, in call_with_frames_remov
ed
File "D:\apps\stable-diffusion\webui__automatic1111\webui\extensions\stabl
e-diffusion-webui-rembg\scripts\postprocessing_rembg.py", line 6, in
import rembg
File "D:\apps\stable-diffusion\webui__automatic1111\webui\venv\lib\site-pa
ckages\rembg_init
.py", line 5, in
from .bg import remove
File "D:\apps\stable-diffusion\webui__automatic1111\webui\venv\lib\site-pa
ckages\rembg\bg.py", line 21, in
from .session_factory import new_session
File "D:\apps\stable-diffusion\webui__automatic1111\webui\venv\lib\site-pa
ckages\rembg\session_factory.py", line 4, in
import onnxruntime as ort
File "D:\apps\stable-diffusion\webui__automatic1111\webui\venv\lib\site-pa
ckages\onnxruntime_init_.py", line 56, in
raise import_capi_exception
File "D:\apps\stable-diffusion\webui__automatic1111\webui\venv\lib\site-pa
ckages\onnxruntime_init_.py", line 23, in
from onnxruntime.capi._pybind_state import ExecutionMode # noqa: F401
File "D:\apps\stable-diffusion\webui__automatic1111\webui\venv\lib\site-pa
ckages\onnxruntime\capi_pybind_state.py", line 32, in
from .onnxruntime_pybind11_state import * # noqa
ImportError: DLL load failed while importing onnxruntime_pybind11_state: La
procédure spécifiée est introuvable.

I installed last VC_redist.x64.exe.
I installed : pip install onnxruntime==1.15.0
but I still have this error :(

Please help

@paras-B
Copy link

paras-B commented Aug 8, 2024

Try installing latest c++ windows runtime https://aka.ms/vs/17/release/vc_redist.x64.exe
and then try it again.

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