How to convert civitai models to ONNX! AMD GPU's on windows can use tons of SD models!

Published on:

Views: 0

Likes: 0

Tags:

AMD
DirectML
ONNX
Civitai
Stable Diffusion
how to
safetensor to ONNX
convert to ONNX
Watch video on Youtube

I had numerous folks from comments asking how to convert models from civitai. I went and looked at several different ways of doing this, and spent days fighting through broken programs, bad code, worse documentation, only to find out, the Olive tab already worked just fine. For anyone who has no idea what is going on, this is using Automatic1111 fork for DirectML on windows 11. See how to install Automatic1111 form for directML here: https://youtu.be/Db0HuRY2p84 In the Olive tab, optimize from the Optimize Checkpoint tab don't click on optimize onnx model tab at all copy the name of your entire file and paste it in at checkpoint name copy the filename without an extension for onnx model folder name output folder name hit optimize. After a while it should get optimized. If it complains about no config.json file for safety checker, sorry I have not been able to get those to work (looking at you SD 2-1). Also while most seem to work fine, I did find some that constantly created "grainy, washed out, faded" looking images. I have not found any way to make those models work properly on ONNX yet, I suspect it is a side effect of the ONNX conversion. Hope this helps! Happy holidays to everyone!