JbPasquier / stable-diffusion-onnx-ui

Stable Diffusion UI - 2.1 + Inpainting + ∞ - ONNX for CPU or AMD graphic card
Apache License 2.0
29 stars 2 forks source link

Crashes with error in module numpy #2

Closed benoegen closed 1 year ago

benoegen commented 1 year ago

I followed the instructions, but the generation fails with:

File "D:\StableDiffusion\21_gui\venv\lib\site-packages\diffusers\pipelines\stable_diffusion\pipeline_onnx_stable_diffusion.py", line 250, in __call__ latents = latents * np.float(self.scheduler.init_noise_sigma) File "D:\StableDiffusion\21_gui\venv\lib\site-packages\numpy\__init__.py", line 284, in __getattr__ raise AttributeError("module {!r} has no attribute " AttributeError: module 'numpy' has no attribute 'float'

Any idea how to fix this? Thank you!

JbPasquier commented 1 year ago

Thanks,

It's related to an issue with the upstream of diffusers, it will work only when this PR gets merged.

GrizCliz commented 1 year ago

You can fix this by just downgrading numpy to version 1.23 (pip install numpy==1.23)

benoegen commented 1 year ago

Downgrading worked, also the mentioned PR was merged recently, so it works as described. Thank you!