diff options
author | DaniAndTheWeb <57776841+DaniAndTheWeb@users.noreply.github.com> | 2023-01-19 18:23:40 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-01-19 18:23:40 +0000 |
commit | 48045545d9a3f174621a62086812d9bbfb3ce1c2 (patch) | |
tree | 30c8f344a76a2a5f7dcb3f0d0910b0193220fba6 /webui.sh | |
parent | c09fb3d8f1f71bc66d7c4cea603885619d6a1cd4 (diff) | |
download | stable-diffusion-webui-gfx803-48045545d9a3f174621a62086812d9bbfb3ce1c2.tar.gz stable-diffusion-webui-gfx803-48045545d9a3f174621a62086812d9bbfb3ce1c2.tar.bz2 stable-diffusion-webui-gfx803-48045545d9a3f174621a62086812d9bbfb3ce1c2.zip |
Small reformat of the GPU check
Diffstat (limited to 'webui.sh')
-rwxr-xr-x | webui.sh | 10 |
1 files changed, 5 insertions, 5 deletions
@@ -109,6 +109,10 @@ if echo "$gpu_info" | grep -q "Navi" then export HSA_OVERRIDE_GFX_VERSION=10.3.0 fi +if echo "$gpu_info" | grep -q "AMD" && [[ -z "${TORCH_COMMAND}" ]] +then + export TORCH_COMMAND="pip install torch torchvision --extra-index-url https://download.pytorch.org/whl/rocm5.2" +fi for preq in "${GIT}" "${python_cmd}" do @@ -170,10 +174,6 @@ then else printf "\n%s\n" "${delimiter}" printf "Launching launch.py..." - printf "\n%s\n" "${delimiter}" - if echo "$gpu_info" | grep -q "AMD" && [[ -z "${TORCH_COMMAND}" ]] - then - export TORCH_COMMAND="pip install torch torchvision --extra-index-url https://download.pytorch.org/whl/rocm5.2" - fi + printf "\n%s\n" "${delimiter}" exec "${python_cmd}" "${LAUNCH_SCRIPT}" "$@" fi |