From 097780be266c527de0ff901b463da776225500a8 Mon Sep 17 00:00:00 2001 From: cmdr2 Date: Mon, 11 Dec 2023 22:28:19 +0530 Subject: [PATCH 1/8] Setting to enable/disable VAE tiling --- ui/easydiffusion/tasks/render_images.py | 5 +++++ ui/easydiffusion/types.py | 1 + ui/index.html | 7 +++++++ ui/media/js/main.js | 2 ++ 4 files changed, 15 insertions(+) diff --git a/ui/easydiffusion/tasks/render_images.py b/ui/easydiffusion/tasks/render_images.py index 9260349f..50c76c2e 100644 --- a/ui/easydiffusion/tasks/render_images.py +++ b/ui/easydiffusion/tasks/render_images.py @@ -278,6 +278,11 @@ def generate_images_internal( setattr(pipe.unet, "_allocate_trt_buffers_backup", pipe.unet._allocate_trt_buffers) delattr(pipe.unet, "_allocate_trt_buffers") + if task_data.enable_vae_tiling: + pipe.enable_vae_tiling() + else: + pipe.disable_vae_tiling() + images = generate_images(context, callback=callback, **req.dict()) user_stopped = False except UserInitiatedStop: diff --git a/ui/easydiffusion/types.py b/ui/easydiffusion/types.py index ec331c29..f16e9aa3 100644 --- a/ui/easydiffusion/types.py +++ b/ui/easydiffusion/types.py @@ -84,6 +84,7 @@ class RenderTaskData(TaskData): filters: List[str] = [] filter_params: Dict[str, Dict[str, Any]] = {} control_filter_to_apply: Union[str, List[str]] = None + enable_vae_tiling: bool = True show_only_filtered_image: bool = False block_nsfw: bool = False diff --git a/ui/index.html b/ui/index.html index fcbcfa73..3aa213d2 100644 --- a/ui/index.html +++ b/ui/index.html @@ -387,6 +387,13 @@ + + + + + + +
From 85eaa305cccd11fa09407d3ed8062902ee1a6207 Mon Sep 17 00:00:00 2001 From: cmdr2 Date: Tue, 12 Dec 2023 18:07:56 +0530 Subject: [PATCH 3/8] Hotfix for #1701 - run disable VAE tiling only on pipelines that support it --- ui/easydiffusion/tasks/render_images.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/ui/easydiffusion/tasks/render_images.py b/ui/easydiffusion/tasks/render_images.py index 50c76c2e..7d8fbc5e 100644 --- a/ui/easydiffusion/tasks/render_images.py +++ b/ui/easydiffusion/tasks/render_images.py @@ -279,9 +279,11 @@ def generate_images_internal( delattr(pipe.unet, "_allocate_trt_buffers") if task_data.enable_vae_tiling: - pipe.enable_vae_tiling() + if hasattr(pipe, "enable_vae_tiling"): + pipe.enable_vae_tiling() else: - pipe.disable_vae_tiling() + if hasattr(pipe, "disable_vae_tiling"): + pipe.disable_vae_tiling() images = generate_images(context, callback=callback, **req.dict()) user_stopped = False From 547febafba2117dcda6d142896be1098124c4efd Mon Sep 17 00:00:00 2001 From: cmdr2 Date: Tue, 12 Dec 2023 18:10:04 +0530 Subject: [PATCH 4/8] Autosave the VAE tiling setting --- ui/media/js/auto-save.js | 1 + 1 file changed, 1 insertion(+) diff --git a/ui/media/js/auto-save.js b/ui/media/js/auto-save.js index 1aec8a55..47a2885b 100644 --- a/ui/media/js/auto-save.js +++ b/ui/media/js/auto-save.js @@ -56,6 +56,7 @@ const SETTINGS_IDS_LIST = [ "extract_lora_from_prompt", "embedding-card-size-selector", "lora_model", + "enable_vae_tiling", ] const IGNORE_BY_DEFAULT = ["prompt"] From 8660a79ccd7255d291be4741f647d12170110999 Mon Sep 17 00:00:00 2001 From: cmdr2 Date: Wed, 13 Mar 2024 18:44:17 +0530 Subject: [PATCH 5/8] v3.0.8 - update diffusers to v0.26.3 --- CHANGES.md | 1 + scripts/check_modules.py | 2 +- ui/index.html | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/CHANGES.md b/CHANGES.md index 389ea7b7..7b649b11 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -17,6 +17,7 @@ - **Major rewrite of the code** - We've switched to using diffusers under-the-hood, which allows us to release new features faster, and focus on making the UI and installer even easier to use. ### Detailed changelog +* 3.0.8 - 13 Mar 2024 - Update diffusers version to v0.26.3. * 3.0.7 - 11 Dec 2023 - Setting to enable/disable VAE tiling (in the Image Settings panel). Sometimes VAE tiling reduces the quality of the image, so this setting will help control that. * 3.0.6 - 18 Sep 2023 - Add thumbnails to embeddings from the UI, using the new `Upload Thumbnail` button in the Embeddings popup. Thanks @JeLuf. * 3.0.6 - 15 Sep 2023 - Fix broken embeddings dialog when LoRA information couldn't be fetched. diff --git a/scripts/check_modules.py b/scripts/check_modules.py index 4509dfad..a6f9eb24 100644 --- a/scripts/check_modules.py +++ b/scripts/check_modules.py @@ -21,7 +21,7 @@ os_name = platform.system() modules_to_check = { "torch": ("1.11.0", "1.13.1", "2.0.0", "2.0.1"), "torchvision": ("0.12.0", "0.14.1", "0.15.1", "0.15.2"), - "sdkit": "2.0.15", + "sdkit": "2.0.16", "stable-diffusion-sdkit": "2.1.5", "rich": "12.6.0", "uvicorn": "0.19.0", diff --git a/ui/index.html b/ui/index.html index 7abfa70c..77113985 100644 --- a/ui/index.html +++ b/ui/index.html @@ -35,7 +35,7 @@

Easy Diffusion - v3.0.7 + v3.0.8

From 47432fe54ef17bced0fc384d09d38e3ece4da324 Mon Sep 17 00:00:00 2001 From: cmdr2 Date: Wed, 13 Mar 2024 19:01:09 +0530 Subject: [PATCH 6/8] diffusers 0.26.3 --- scripts/check_modules.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/check_modules.py b/scripts/check_modules.py index a6f9eb24..336cf16b 100644 --- a/scripts/check_modules.py +++ b/scripts/check_modules.py @@ -21,7 +21,7 @@ os_name = platform.system() modules_to_check = { "torch": ("1.11.0", "1.13.1", "2.0.0", "2.0.1"), "torchvision": ("0.12.0", "0.14.1", "0.15.1", "0.15.2"), - "sdkit": "2.0.16", + "sdkit": "2.0.17", "stable-diffusion-sdkit": "2.1.5", "rich": "12.6.0", "uvicorn": "0.19.0", From 5924d017896ebfd1b60698135bc798f5a669d254 Mon Sep 17 00:00:00 2001 From: cmdr2 Date: Wed, 13 Mar 2024 19:05:55 +0530 Subject: [PATCH 7/8] Temporarily revert to sdkit 2.0.15 --- scripts/check_modules.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/check_modules.py b/scripts/check_modules.py index 336cf16b..4509dfad 100644 --- a/scripts/check_modules.py +++ b/scripts/check_modules.py @@ -21,7 +21,7 @@ os_name = platform.system() modules_to_check = { "torch": ("1.11.0", "1.13.1", "2.0.0", "2.0.1"), "torchvision": ("0.12.0", "0.14.1", "0.15.1", "0.15.2"), - "sdkit": "2.0.17", + "sdkit": "2.0.15", "stable-diffusion-sdkit": "2.1.5", "rich": "12.6.0", "uvicorn": "0.19.0", From d1bd9e2a16c021aede7ad6f18db7694d94f56dac Mon Sep 17 00:00:00 2001 From: cmdr2 Date: Wed, 13 Mar 2024 19:53:14 +0530 Subject: [PATCH 8/8] Prev version --- CHANGES.md | 1 - ui/index.html | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/CHANGES.md b/CHANGES.md index 7b649b11..389ea7b7 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -17,7 +17,6 @@ - **Major rewrite of the code** - We've switched to using diffusers under-the-hood, which allows us to release new features faster, and focus on making the UI and installer even easier to use. ### Detailed changelog -* 3.0.8 - 13 Mar 2024 - Update diffusers version to v0.26.3. * 3.0.7 - 11 Dec 2023 - Setting to enable/disable VAE tiling (in the Image Settings panel). Sometimes VAE tiling reduces the quality of the image, so this setting will help control that. * 3.0.6 - 18 Sep 2023 - Add thumbnails to embeddings from the UI, using the new `Upload Thumbnail` button in the Embeddings popup. Thanks @JeLuf. * 3.0.6 - 15 Sep 2023 - Fix broken embeddings dialog when LoRA information couldn't be fetched. diff --git a/ui/index.html b/ui/index.html index 77113985..7abfa70c 100644 --- a/ui/index.html +++ b/ui/index.html @@ -35,7 +35,7 @@

Easy Diffusion - v3.0.8 + v3.0.7