huggingface / huggingface/diffusers
Failed to import diffusers.pipelines.onnx_utils
- Lingua principale
- Python
- Stelle
- 34.5k
- Fork
- 7.3k
- Merge medio
- 3g 3h
- PR unite (30g)
- 91
Descrizione
### Describe the bug
Running error:
```
diffusers\utils\import_utils.py", line 922, in _get_module
raise RuntimeError(
RuntimeError: Failed to import diffusers.pipelines.onnx_utils because of the following error (look up to see its traceback):
DLL load failed while importing onnxruntime_pybind11_state
```
It seems to be a bug , You can manually modify lines 30/31 of the file:onnx_utils.py
lib\site-packages\diffusers\pipelines\onnx_utils.py
```
if is_onnx_available():
import onnxruntime as ort
```
Change it to
```
if False:
import onnxruntime as ort
```
### Reproduction
lib\site-packages\diffusers\pipelines\onnx_utils.py
```
if is_onnx_available():
import onnxruntime as ort
```
Change it to
```
if False:
import onnxruntime as ort
```
### Logs
```shell
Running error:
diffusers\utils\import_utils.py", line 922, in _get_module
raise RuntimeError(
RuntimeError: Failed to import diffusers.pipelines.onnx_utils because of the following error (look up to see its traceback):
DLL load failed while importing onnxruntime_pybind11_state
```
### System Info
diffusers-0.32.2
onnxruntime-gpu=1.21.0
### Who can help?
_No response_
Guida per i contributori
Apri la guida per i contributori
Direzione di ricerca
Start by reproducing the import failure with diffusers-0.32.2 and onnxruntime-gpu=1.21.0, then inspect lib/site-packages/diffusers/pipelines/onnx_utils.py and the _get_module path in diffusers/utils/import_utils.py. Done means importing diffusers.pipelines.onnx_utils no longer raises the reported onnxruntime DLL-load error.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- python
- Ambito
- machine-learning
- Tipo di issue
- Bug
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Stato di attività
- Ferma
- Chiarezza
- Da chiarire
- Idoneità per principianti
- 25/100