Files
homelab/systemd/incubating/stablediffusion/README.md
2024-11-04 14:11:24 -05:00

1.6 KiB

Stable Diffusion

Web UI

https://github.com/AUTOMATIC1111/stable-diffusion-webui/wiki/Install-and-Run-on-AMD-GPUs#arch-specific-dependencies

python3.10 -m ensurepip --upgrade

# Check https://download.pytorch.org/whl/nightly/ for versions
# Specifically you want the "rocm" versions for AMD
pip install torch==2.6.0.dev20241103+rocm6.2 --index-url https://download.pytorch.org/whl/nightly
pip install torchvision==0.20.0.dev20241103+rocm6.2 --index-url https://download.pytorch.org/whl/nightly
sudo pacman -S python-pytorch-rocm

git clone https://aur.archlinux.org/python-torchvision-rocm.git
cd python-torchvision-rocm
makepkg -si

git clone https://github.com/AUTOMATIC1111/stable-diffusion-webui.git
cd stable-diffusion-webui

python3.10 -m venv venv --system-site-packages
source venv/bin/activate
# Check https://download.pytorch.org/whl/nightly/ for versions
# Specifically you want the "rocm" versions for AMD
pip install torch==2.6.0.dev20241103+rocm6.2 --index-url https://download.pytorch.org/whl/nightly
pip install torchvision==0.20.0.dev20241103+rocm6.2 --index-url https://download.pytorch.org/whl/nightly
pip install -r requirements.txt

./webui.sh

Models

https://stable-diffusion-art.com/models/#How_to_install_and_use_a_model

SDXC

  • Use 1024x1024
  • First generation is really really slow, subsequent generations are fast

https://stable-diffusion-art.com/sdxl-model/#Download_and_install_SDXL_10_models

Flux AI

  • You must use Stable Diffusion WebUI Forge
  • In the UI, click "flux"
  • First generation is really really really really slow

https://stable-diffusion-art.com/flux-forge/