diff --git a/CHANGES.md b/CHANGES.md index ac31a612..280e7248 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -2,6 +2,7 @@ ## v2.4 ### Major Changes +- **Automatic scanning for malicious model files** - using `picklescan`. Thanks @JeLuf - **Support for custom VAE models**. You can place your VAE files in the `models/vae` folder, and refresh the browser page to use them. More info: https://github.com/cmdr2/stable-diffusion-ui/wiki/VAE-Variational-Auto-Encoder - **Experimental support for multiple GPUs!** It should work automatically. Just open one browser tab per GPU, and spread your tasks across your GPUs. For e.g. open our UI in two browser tabs if you have two GPUs. You can customize which GPUs it should use in the "Settings" tab, otherwise let it automatically pick the best GPUs. Thanks @madrang . More info: https://github.com/cmdr2/stable-diffusion-ui/wiki/Run-on-Multiple-GPUs - **Cleaner UI design** - Show settings and help in new tabs, instead of dropdown popups (which were buggy). Thanks @mdiller @@ -20,6 +21,12 @@ - A `What's New?` tab in the UI ### Detailed changelog +* 2.4.11 - 19 Nov 2022 - Address a regression in how long images take to generate. Use the previous code for moving a model to CPU. This improves things by a second or two per image, but we still have a regression (investigating). +* 2.4.10 - 18 Nov 2022 - Textarea for negative prompts. Thanks @JeLuf +* 2.4.10 - 18 Nov 2022 - Improved design for Settings, and rounded toggle buttons instead of checkboxes for a more modern look. Thanks @mdiller +* 2.4.9 - 18 Nov 2022 - Add Picklescan - a scanner for malicious model files. If it finds a malicious file, it will halt the web application and alert the user. Thanks @JeLuf +* 2.4.8 - 18 Nov 2022 - A `Use these settings` button to use the settings from a previously generated image task. Thanks @patriceac +* 2.4.7 - 18 Nov 2022 - Don't crash if a VAE file fails to load * 2.4.7 - 17 Nov 2022 - Fix a bug where Face Correction (GFPGAN) would fail on cuda:N (i.e. GPUs other than cuda:0), as well as fail on CPU if the system had an incompatible GPU. * 2.4.6 - 16 Nov 2022 - Fix a regression in VRAM usage during startup, which caused 'Out of Memory' errors when starting on GPUs with 4gb (or less) VRAM * 2.4.5 - 16 Nov 2022 - Add checkbox for "Open browser on startup". diff --git a/scripts/on_sd_start.bat b/scripts/on_sd_start.bat index 51a51549..abc63ef5 100644 --- a/scripts/on_sd_start.bat +++ b/scripts/on_sd_start.bat @@ -191,6 +191,16 @@ call WHERE uvicorn > .tmp exit /b ) +@>nul 2>nul call python -m picklescan --help +@if "%ERRORLEVEL%" NEQ "0" ( + @echo. & echo Picklescan not found. Installing + @call pip install picklescan || ( + echo "Error installing the picklescan package necessary for Stable Diffusion UI. Sorry about that, please try to:" & echo " 1. Run this installer again." & echo " 2. If that doesn't fix it, please try the common troubleshooting steps at https://github.com/cmdr2/stable-diffusion-ui/wiki/Troubleshooting" & echo " 3. If those steps don't help, please copy *all* the error messages in this window, and ask the community at https://discord.com/invite/u9yhsFmEkB" & echo " 4. If that doesn't solve the problem, please file an issue at https://github.com/cmdr2/stable-diffusion-ui/issues" & echo "Thanks!" + pause + exit /b + ) +) + @>nul findstr /m "conda_sd_ui_deps_installed" ..\scripts\install_status.txt @if "%ERRORLEVEL%" NEQ "0" ( @echo conda_sd_ui_deps_installed >> ..\scripts\install_status.txt @@ -275,7 +285,7 @@ echo. > "..\models\vae\Put your VAE files here.txt" for %%I in ("RealESRGAN_x4plus.pth") do if "%%~zI" EQU "67040989" ( echo "Data files (weights) necessary for ESRGAN (Resolution Upscaling) x4plus were already downloaded" ) else ( - echo. & echo "The GFPGAN model file present at %cd%\RealESRGAN_x4plus.pth is invalid. It is only %%~zI bytes in size. Re-downloading.." & echo. + echo. & echo "The RealESRGAN model file present at %cd%\RealESRGAN_x4plus.pth is invalid. It is only %%~zI bytes in size. Re-downloading.." & echo. del "RealESRGAN_x4plus.pth" ) ) @@ -305,7 +315,7 @@ echo. > "..\models\vae\Put your VAE files here.txt" for %%I in ("RealESRGAN_x4plus_anime_6B.pth") do if "%%~zI" EQU "17938799" ( echo "Data files (weights) necessary for ESRGAN (Resolution Upscaling) x4plus_anime were already downloaded" ) else ( - echo. & echo "The GFPGAN model file present at %cd%\RealESRGAN_x4plus_anime_6B.pth is invalid. It is only %%~zI bytes in size. Re-downloading.." & echo. + echo. & echo "The RealESRGAN model file present at %cd%\RealESRGAN_x4plus_anime_6B.pth is invalid. It is only %%~zI bytes in size. Re-downloading.." & echo. del "RealESRGAN_x4plus_anime_6B.pth" ) ) diff --git a/scripts/on_sd_start.sh b/scripts/on_sd_start.sh index d4bb1ad1..adcba1f2 100755 --- a/scripts/on_sd_start.sh +++ b/scripts/on_sd_start.sh @@ -156,6 +156,13 @@ else echo conda_sd_ui_deps_installed >> ../scripts/install_status.txt fi +if python -m picklescan --help >/dev/null 2>&1; then + echo "Picklescan is already installed." +else + echo "Picklescan not found, installing." + pip install picklescan || fail "Picklescan installation failed." +fi + mkdir -p "../models/stable-diffusion" diff --git a/ui/index.html b/ui/index.html index 43a327ad..becc2418 100644 --- a/ui/index.html +++ b/ui/index.html @@ -5,12 +5,12 @@ - - - - - - + + + + + + @@ -20,7 +20,7 @@