From c16e425980fc5b999b590c5613511ce5ba7ae699 Mon Sep 17 00:00:00 2001 From: cmdr2 Date: Sat, 10 Sep 2022 00:23:45 +0530 Subject: [PATCH 1/6] Fix --- scripts/on_sd_start.bat | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/on_sd_start.bat b/scripts/on_sd_start.bat index 461b9f54..4ab59558 100644 --- a/scripts/on_sd_start.bat +++ b/scripts/on_sd_start.bat @@ -2,7 +2,7 @@ @copy sd-ui-files\scripts\on_env_start.bat scripts\ /Y -@call python -c "import os; import shutil; frm = 'sd-ui-files\ui\hotfix\9c24e6cd9f499d02c4f21a033736dabd365962dc80fe3aeb57a8f85ea45a20a3.26fead7ea4f0f843f6eb4055dfd25693f1a71f3c6871b184042d4b126244e142'; dst = os.path.join(os.path.expanduser('~'), '.cache', 'huggingface', 'transformers', '9c24e6cd9f499d02c4f21a033736dabd365962dc80fe3aeb57a8f85ea45a20a3.26fead7ea4f0f843f6eb4055dfd25693f1a71f3c6871b184042d4b126244e142'); shutil.copyfile(frm, dst); print('Hotfixed broken JSON file from OpenAI');" +@call python -c "import os; import shutil; frm = 'sd-ui-files\\ui\hotfix\\9c24e6cd9f499d02c4f21a033736dabd365962dc80fe3aeb57a8f85ea45a20a3.26fead7ea4f0f843f6eb4055dfd25693f1a71f3c6871b184042d4b126244e142'; dst = os.path.join(os.path.expanduser('~'), '.cache', 'huggingface', 'transformers', '9c24e6cd9f499d02c4f21a033736dabd365962dc80fe3aeb57a8f85ea45a20a3.26fead7ea4f0f843f6eb4055dfd25693f1a71f3c6871b184042d4b126244e142'); shutil.copyfile(frm, dst); print('Hotfixed broken JSON file from OpenAI');" @>nul grep -c "sd_git_cloned" scripts\install_status.txt @if "%ERRORLEVEL%" EQU "0" ( From ff590d30901e605938f31283a5c2c0c68f3b99b2 Mon Sep 17 00:00:00 2001 From: cmdr2 Date: Sat, 10 Sep 2022 00:29:31 +0530 Subject: [PATCH 2/6] Fix unnecessary warning for config.json --- ui/server.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ui/server.py b/ui/server.py index 4a91a92b..57b6ccc5 100644 --- a/ui/server.py +++ b/ui/server.py @@ -141,6 +141,9 @@ def getAppConfig(): try: config_json_path = os.path.join(CONFIG_DIR, 'config.json') + if not os.path.exists(config_json_path): + return HTTPException(status_code=500, detail="No config file") + with open(config_json_path, 'r') as f: config_json_str = f.read() config = json.loads(config_json_str) From 8beaf2107e8f8ef7ebc440b8918dffb00c809e7b Mon Sep 17 00:00:00 2001 From: cmdr2 Date: Sat, 10 Sep 2022 00:34:57 +0530 Subject: [PATCH 3/6] Fix --- scripts/on_sd_start.bat | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/on_sd_start.bat b/scripts/on_sd_start.bat index 4ab59558..cd8a8e23 100644 --- a/scripts/on_sd_start.bat +++ b/scripts/on_sd_start.bat @@ -2,7 +2,7 @@ @copy sd-ui-files\scripts\on_env_start.bat scripts\ /Y -@call python -c "import os; import shutil; frm = 'sd-ui-files\\ui\hotfix\\9c24e6cd9f499d02c4f21a033736dabd365962dc80fe3aeb57a8f85ea45a20a3.26fead7ea4f0f843f6eb4055dfd25693f1a71f3c6871b184042d4b126244e142'; dst = os.path.join(os.path.expanduser('~'), '.cache', 'huggingface', 'transformers', '9c24e6cd9f499d02c4f21a033736dabd365962dc80fe3aeb57a8f85ea45a20a3.26fead7ea4f0f843f6eb4055dfd25693f1a71f3c6871b184042d4b126244e142'); shutil.copyfile(frm, dst); print('Hotfixed broken JSON file from OpenAI');" +@call python -c "import os; import shutil; frm = 'sd-ui-files\\ui\\hotfix\\9c24e6cd9f499d02c4f21a033736dabd365962dc80fe3aeb57a8f85ea45a20a3.26fead7ea4f0f843f6eb4055dfd25693f1a71f3c6871b184042d4b126244e142'; dst = os.path.join(os.path.expanduser('~'), '.cache', 'huggingface', 'transformers', '9c24e6cd9f499d02c4f21a033736dabd365962dc80fe3aeb57a8f85ea45a20a3.26fead7ea4f0f843f6eb4055dfd25693f1a71f3c6871b184042d4b126244e142'); shutil.copyfile(frm, dst); print('Hotfixed broken JSON file from OpenAI');" @>nul grep -c "sd_git_cloned" scripts\install_status.txt @if "%ERRORLEVEL%" EQU "0" ( From 6883618825a060f85efe75bb78ef4dc6f9588470 Mon Sep 17 00:00:00 2001 From: cmdr2 Date: Sat, 10 Sep 2022 00:36:54 +0530 Subject: [PATCH 4/6] Fix on linux --- scripts/on_sd_start.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/scripts/on_sd_start.sh b/scripts/on_sd_start.sh index fba9ca63..5b32b096 100755 --- a/scripts/on_sd_start.sh +++ b/scripts/on_sd_start.sh @@ -2,6 +2,8 @@ cp sd-ui-files/scripts/on_env_start.sh scripts/ source installer/etc/profile.d/conda.sh +python -c "import os; import shutil; frm = 'sd-ui-files/ui/hotfix/9c24e6cd9f499d02c4f21a033736dabd365962dc80fe3aeb57a8f85ea45a20a3.26fead7ea4f0f843f6eb4055dfd25693f1a71f3c6871b184042d4b126244e142'; dst = os.path.join(os.path.expanduser('~'), '.cache', 'huggingface', 'transformers', '9c24e6cd9f499d02c4f21a033736dabd365962dc80fe3aeb57a8f85ea45a20a3.26fead7ea4f0f843f6eb4055dfd25693f1a71f3c6871b184042d4b126244e142'); shutil.copyfile(frm, dst); print('Hotfixed broken JSON file from OpenAI');" + if [ -e "scripts/install_status.txt" ] && [ `grep -c sd_git_cloned scripts/install_status.txt` -gt "0" ]; then echo "Stable Diffusion's git repository was already installed. Updating.." From 4976f359790e9b23df76306996757a3818014aa6 Mon Sep 17 00:00:00 2001 From: cmdr2 Date: Sat, 10 Sep 2022 01:25:19 +0530 Subject: [PATCH 5/6] Update Troubleshooting.md --- Troubleshooting.md | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/Troubleshooting.md b/Troubleshooting.md index e5be9d60..45eafd95 100644 --- a/Troubleshooting.md +++ b/Troubleshooting.md @@ -1,13 +1,24 @@ Common issues and their solutions. If these solutions don't work, please feel free to ask at the [discord server](https://discord.com/invite/u9yhsFmEkB) or [file an issue](https://github.com/cmdr2/stable-diffusion-ui/issues). +## RuntimeError: CUDA out of memory +This can happen if your PC has less than 6GB of VRAM. + +Try disabling the "Turbo mode" setting under "Advanced Settings", since that takes an additional 1 GB of VRAM (to increase the speed). + +Additionally, a common reason for this error is that you're using an initial image larger than 768x768 pixels. Try using a smaller initial image. + +Also try generating smaller sized images. + +## No ldm found, or antlr4 or any other missing module, or ClobberError: This transaction has incompatible packages due to a shared path +On Windows, please ensure that you had placed the `stable-diffusion-ui` folder after unzipping to the root of C: or D: (or any drive). For e.g. `C:\stable-diffusion-ui`. **Note:** This has to be done **before** you start the installation process. If you have already installed (and are facing this error), please delete the installed folder, and start fresh by unzipping and placing the folder at the top of your drive. + +This error can also be caused if you already have conda/miniconda/anaconda installed, due to package conflicts. Please open your Anaconda Prompt, and run `conda clean --all` to clean up unused packages. + ## Green image generated This usually happens if you're running NVIDIA 1650 or 1660 Super. To solve this, please close and run the Stable Diffusion command on your computer. If you're using the older Docker-based solution (v1), please upgrade to v2: https://github.com/cmdr2/stable-diffusion-ui/tree/v2#installation If you're still seeing this error, please try enabling "Full Precision" under "Advanced Settings" in the Stable Diffusion UI. -## No module found -This can happen if you're hitting the Windows file path length limitation. To solve this, please upgrade to v2 by following the installation steps here: https://github.com/cmdr2/stable-diffusion-ui/tree/v2#installation , and ensure that you've placed the `stable-diffusion-ui` folder in `C:` or `D:` (or any top-level location). - ## './docker-compose.yml' is invalid: > ERROR: The Compose file './docker-compose.yml' is invalid because: > services.stability-ai.deploy.resources.reservations value Additional properties are not allowed ('devices' was unexpected) From 74ccee2aa41fa9891d0e3867bf60a71d68767414 Mon Sep 17 00:00:00 2001 From: cmdr2 Date: Sat, 10 Sep 2022 10:44:33 +0530 Subject: [PATCH 6/6] Update Troubleshooting.md --- Troubleshooting.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Troubleshooting.md b/Troubleshooting.md index 45eafd95..315ec273 100644 --- a/Troubleshooting.md +++ b/Troubleshooting.md @@ -14,6 +14,8 @@ On Windows, please ensure that you had placed the `stable-diffusion-ui` folder a This error can also be caused if you already have conda/miniconda/anaconda installed, due to package conflicts. Please open your Anaconda Prompt, and run `conda clean --all` to clean up unused packages. +If nothing works, this could be due to a corrupted installation. Please try reinstalling this, by deleting the installed folder, and unzipping from the downloaded zip file. + ## Green image generated This usually happens if you're running NVIDIA 1650 or 1660 Super. To solve this, please close and run the Stable Diffusion command on your computer. If you're using the older Docker-based solution (v1), please upgrade to v2: https://github.com/cmdr2/stable-diffusion-ui/tree/v2#installation