camenduru's picture
Create app.py
1facd3e
raw
history blame
1.31 kB
import os
os.chdir(f"/home/user/app")
os.system(f"git clone -b v2.6 https://github.com/camenduru/stable-diffusion-webui /home/user/app/stable-diffusion-webui")
os.chdir(f"/home/user/app/stable-diffusion-webui")
os.system(f"git lfs install")
os.system(f"git reset --hard")
# os.system(f"sed -i -e '/demo:/r /home/user/app/header.py' /home/user/app/stable-diffusion-webui/modules/ui.py")
os.system(f"sed -i -e '253,258d' /home/user/app/stable-diffusion-webui/modules/ui_settings.py")
os.system(f"sed -i -e '186,228d' /home/user/app/stable-diffusion-webui/modules/ui_settings.py")
os.system(f"sed -i -e '171,178d' /home/user/app/stable-diffusion-webui/modules/ui_settings.py")
os.system(f"sed -i -e '108,113d' /home/user/app/stable-diffusion-webui/modules/ui_settings.py")
os.system(f"sed -i -e '225,227d' /home/user/app/stable-diffusion-webui/modules/ui_loadsave.py")
os.system(f"sed -i -e '214,217d' /home/user/app/stable-diffusion-webui/modules/ui_loadsave.py")
os.system(f"aria2c --console-log-level=error -c -x 16 -s 16 -k 1M https://huggingface.co/ckpt/counterfeit-xl/resolve/main/counterfeitxl_v10.safetensors -d /home/user/app/stable-diffusion-webui/models/Stable-diffusion -o counterfeitxl_v10.safetensors")
os.system(f"python launch.py --cors-allow-origins=* --xformers --theme dark --gradio-queue")