Skip to content

Instantly share code, notes, and snippets.

@enryu43
Last active April 27, 2024 05:00
Show Gist options
  • Star 4 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save enryu43/858999bf69dc92b97fdad6137c3c45e6 to your computer and use it in GitHub Desktop.
Save enryu43/858999bf69dc92b97fdad6137c3c45e6 to your computer and use it in GitHub Desktop.
# install torch with CUDA support. See https://pytorch.org/get-started/locally/ for more instructions if this fails.
pip install torch --extra-index-url https://download.pytorch.org/whl/cu113
# check if torch supports GPU; this must output "True". You need CUDA 11. installed for this. You might be able to use
# a different version, but this is what I tested.
python -c "import torch; print(torch.cuda.is_available())"
# clone web ui and go into its directory
git clone https://github.com/enryu43/anifusion-sd-webui.git
cd anifusion-sd-webui
mkdir repositories
git clone https://github.com/enryu43/anifusion-stable-diffusion.git repositories/stable-diffusion
git clone https://github.com/CompVis/taming-transformers.git repositories/taming-transformers
# install requirements of Stable Diffusion
pip install transformers==4.19.2 diffusers invisible-watermark --prefer-binary
# install k-diffusion
pip install git+https://github.com/crowsonkb/k-diffusion.git --prefer-binary
# install requirements of web ui
pip install -r requirements.txt --prefer-binary
# update numpy to latest version
pip install -U numpy --prefer-binary
wget https://huggingface.co/enryu43/anifusion_unet/resolve/main/original_ckpt.bin -O model.ckpt
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment