From d0a12763feb4d71b7700f49f98b314354a147220 Mon Sep 17 00:00:00 2001 From: orionaskatu <100234619+orionaskatu@users.noreply.github.com> Date: Tue, 20 Sep 2022 14:28:20 +0200 Subject: [PATCH 1/3] Comment variables with default values --- webui-user.sh | 36 ++++++++++++++++++------------------ 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/webui-user.sh b/webui-user.sh index 20f05b69..cc81004f 100644 --- a/webui-user.sh +++ b/webui-user.sh @@ -1,40 +1,40 @@ #!/bin/bash -########################################### -# Change the variables below to your need:# -########################################### +######################################################### +# Uncomment and change the variables below to your need:# +######################################################### # Install directory without trailing slash -install_dir="/home/$(whoami)" +#install_dir="/home/$(whoami)" -# Name of the subdirectory (defaults to stable-diffusion-webui) -clone_dir="stable-diffusion-webui" +# Name of the subdirectory +#clone_dir="stable-diffusion-webui" -# Commandline arguments for webui.py, for example: export COMMANDLINE_ARGS=(--medvram --opt-split-attention) +# Commandline arguments for webui.py, for example: export COMMANDLINE_ARGS="--medvram --opt-split-attention" export COMMANDLINE_ARGS="" # python3 executable -python_cmd="python3" +#python_cmd="python3" # git executable -#export GIT="" +#export GIT="git" # python3 venv without trailing slash (defaults to ${install_dir}/${clone_dir}/venv) -venv_dir="venv" +#venv_dir="venv" # install command for torch -export TORCH_COMMAND="pip install torch==1.12.1+cu113 --extra-index-url https://download.pytorch.org/whl/cu113" +#export TORCH_COMMAND="pip install torch==1.12.1+cu113 --extra-index-url https://download.pytorch.org/whl/cu113" # Requirements file to use for stable-diffusion-webui -#export REQS_FILE="" +#export REQS_FILE="requirements_versions.txt" # Fixed git repos -#export K_DIFFUSION_PACKAGE="" -#export GFPGAN_PACKAGE="" +#export K_DIFFUSION_PACKAGE="git+https://github.com/crowsonkb/k-diffusion.git@1a0703dfb7d24d8806267c3e7ccc4caf67fd1331" +#export GFPGAN_PACKAGE="git+https://github.com/TencentARC/GFPGAN.git@8d2447a2d918f8eba5a4a01463fd48e45126a379" # Fixed git commits -#export STABLE_DIFFUSION_COMMIT_HASH="" -#export TAMING_TRANSFORMERS_COMMIT_HASH="" -#export CODEFORMER_COMMIT_HASH="" -#export BLIP_COMMIT_HASH="" +#export STABLE_DIFFUSION_COMMIT_HASH="69ae4b35e0a0f6ee1af8bb9a5d0016ccb27e36dc" +#export TAMING_TRANSFORMERS_COMMIT_HASH="24268930bf1dce879235a7fddd0b2355b84d7ea6" +#export CODEFORMER_COMMIT_HASH="c5b4593074ba6214284d6acd5f1719b6c5d739af" +#export BLIP_COMMIT_HASH="48211a1594f1321b00f14c9f7a5b4813144b2fb9" ########################################### From f2ad00bc8ef995c32ff40d5db58fc6ae8d50d916 Mon Sep 17 00:00:00 2001 From: orionaskatu <100234619+orionaskatu@users.noreply.github.com> Date: Tue, 20 Sep 2022 15:20:45 +0200 Subject: [PATCH 2/3] Remove default git variables to prevent issues --- webui-user.sh | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/webui-user.sh b/webui-user.sh index cc81004f..0ce41d3f 100644 --- a/webui-user.sh +++ b/webui-user.sh @@ -28,13 +28,13 @@ export COMMANDLINE_ARGS="" #export REQS_FILE="requirements_versions.txt" # Fixed git repos -#export K_DIFFUSION_PACKAGE="git+https://github.com/crowsonkb/k-diffusion.git@1a0703dfb7d24d8806267c3e7ccc4caf67fd1331" -#export GFPGAN_PACKAGE="git+https://github.com/TencentARC/GFPGAN.git@8d2447a2d918f8eba5a4a01463fd48e45126a379" +#export K_DIFFUSION_PACKAGE="" +#export GFPGAN_PACKAGE="" # Fixed git commits -#export STABLE_DIFFUSION_COMMIT_HASH="69ae4b35e0a0f6ee1af8bb9a5d0016ccb27e36dc" -#export TAMING_TRANSFORMERS_COMMIT_HASH="24268930bf1dce879235a7fddd0b2355b84d7ea6" -#export CODEFORMER_COMMIT_HASH="c5b4593074ba6214284d6acd5f1719b6c5d739af" -#export BLIP_COMMIT_HASH="48211a1594f1321b00f14c9f7a5b4813144b2fb9" +#export STABLE_DIFFUSION_COMMIT_HASH="" +#export TAMING_TRANSFORMERS_COMMIT_HASH="" +#export CODEFORMER_COMMIT_HASH="" +#export BLIP_COMMIT_HASH="" ########################################### From c2775528c9e5336b37987832795621fa49ff97d3 Mon Sep 17 00:00:00 2001 From: Rahul Kolasseri Date: Tue, 20 Sep 2022 11:56:07 +0000 Subject: [PATCH 3/3] added __name__ == __main__ to launch.py so it can be imported without launching the webUI --- launch.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/launch.py b/launch.py index 197e656b..a357b917 100644 --- a/launch.py +++ b/launch.py @@ -123,5 +123,5 @@ def start_webui(): import webui webui.webui() - -start_webui() +if __name__ == "__main__": + start_webui()