Next attempt to get #stable_diffusion working with my AMD-based setup, using the following instructions:
https://community.amd.com/t5/ai/updated-how-to-running-optimized-automatic1111-stable-diffusion/ba-p/630252

Unfortunately, running into an error upon following the instructions when running webui.bat: "RuntimeError: Torch is not able to use GPU; add --skip-torch-cuda-test to COMMANDLINE_ARGS variable to disable this check"

Need to check where to set COMMANDLINE_ARGS, I guess... ๐Ÿ˜„

[UPDATED HOW-TO] Running Optimized Automatic1111 Stable Diffusion WebUI on AMD GPUs

[UPDATE]: The Automatic1111-directML branch now supports Microsoft Olive under the Automatic1111 WebUI interface, which allows for generating optimized models and running them all under the Automatic1111 WebUI, without a separate branch needed to optimize for AMD platforms. The original blog with ad...

AMD.com

Set COMMANDLINE_ARGS in the environement for an initial test, but also defined it in webui-user.bat, which calls webui.bat:

set COMMANDLINE_ARGS=--skip-torch-cuda-test

Next error message: "launch.py: error: unrecognized arguments: --onnx --backend directml"

Interestingly, just running webui-user.bat seems to progress further...?

> webui-user.bat --onnx --backend directml

#stable_diffusion #automatic111 UI is opening fine, but without ONNX and Olive tabs... ๐Ÿค”

Checked the settings and enabled Olive and ONNX there, but no change. ๐Ÿ˜•
(And yes, I have applied the settings, reloaded the UI, and even tried restarting the whole batch. No ONNX and Olive tabs in the UI.)

And... It doesn't work, just throwing the following error:

ONNX: Failed to convert model: model='v1-5-pruned-emaonly.safetensors', error=Exporting the operator 'aten::scaled_dot_product_attention' to ONNX opset version 14 is not supported.

This comment sounded promising, but to no avail: Still getting the same error. The only thing I didn't do, yet, was to switch the execution provider: Searched for "execution provider" in the #automatic111 settings and switched from "CPUExecutionProvider" to "DmlExecutionProvider".

Still getting the same error, though. ๐Ÿค”

This sounds like the underlying issue so far: https://github.com/pytorch/pytorch/issues/120559

Will see when I have time to investigate further...

ONNX: Failed to convert model / ONNX opset version 14 is not supported ยท Issue #120559 ยท pytorch/pytorch

๐Ÿ› Describe the bug Hello, since a while i am trying to get Stable Diffusion running on my RX 7900 XTX. Finally it is working normal when generating with a normal model that is not opitmized. Now i ...

GitHub