Skip to content

averad/OnnxInpaintingUI

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Onnx Inpainting UI

UI for Stable Diffusion Inpainting using Onnx with DirectML

ui_sample

Requirements

Installation

Create a Folder to Store Stable Diffusion Related Files

  • Open File Explorer and navigate to your prefered storage location.
  • Create a new folder named "Stable Diffusion" and open it.
  • In the navigation bar, in file explorer, highlight the folder path and type cmd and press enter.

Install 🤗 diffusers

The following steps creates a virtual environment (using venv) named sd_env (in the folder you have the cmd window opened to). Then it installs diffusers (latest from main branch), transformers, onnxruntime, onnx, onnxruntime-directml, protobuf and gradio:

pip install virtualenv
python -m venv sd_env
sd_env\scripts\activate
python -m pip install --upgrade pip
pip install git+https://github.com/huggingface/diffusers.git
pip install transformers onnxruntime onnx torch ftfy spacy scipy gradio
pip install onnxruntime-directml --force-reinstall
pip install protobuf==3.20.1

To exit the virtual environment, close the command prompt. To start the virtual environment go to the scripts folder in sd_env and open a command prompt. Type activate and the virtual environment will activate.

Running Onnx Inpainting UI

Loads runwayml/stable-diffusion-inpainting from Huggingface website into local cache.

sd_env\scripts\activate
python inpainting_ui.py

Note:

  • stable-diffusion-inpainting uses 5.10 GB of disk space

Running Onnx Inpainting Legacy UI

Loads runwayml/stable-diffusion-v1-5 from Huggingface website into local cache.

Inpainting Legacy is used for loading non inpainting trained models

sd_env\scripts\activate
python inpainting_legacy_ui.py

Note:

  • stable-diffusion-v1-5 uses 5.10 GB of disk space

About

UI for ONNX based Stable Diffusion Inpainting using DirectML

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages