aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAUTOMATIC1111 <16777216c@gmail.com>2023-09-30 05:58:07 +0000
committerGitHub <noreply@github.com>2023-09-30 05:58:07 +0000
commitdb63cf7d2476ac47b39fa4494c651d47e54b9b88 (patch)
treed1d3827f9cd002ac9befb199a6a25af39febe53d
parentcdafbcaad28dbd4517dc7f2c25c6445a1a9f77d7 (diff)
parentd2878a8b0b952c08d832e0308e575e352a1bc3f1 (diff)
downloadstable-diffusion-webui-gfx803-db63cf7d2476ac47b39fa4494c651d47e54b9b88.tar.gz
stable-diffusion-webui-gfx803-db63cf7d2476ac47b39fa4494c651d47e54b9b88.tar.bz2
stable-diffusion-webui-gfx803-db63cf7d2476ac47b39fa4494c651d47e54b9b88.zip
Merge pull request #13282 from AUTOMATIC1111/XYZ-if-not-Include-Sub-Grids-do-not-save-Sub-Grid
XYZ if not include sub grids do not save sub grid
-rw-r--r--scripts/xyz_grid.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/scripts/xyz_grid.py b/scripts/xyz_grid.py
index 939d8605..99ad96be 100644
--- a/scripts/xyz_grid.py
+++ b/scripts/xyz_grid.py
@@ -773,6 +773,8 @@ class Script(scripts.Script):
# TODO: See previous comment about intentional data misalignment.
adj_g = g-1 if g > 0 else g
images.save_image(processed.images[g], p.outpath_grids, "xyz_grid", info=processed.infotexts[g], extension=opts.grid_format, prompt=processed.all_prompts[adj_g], seed=processed.all_seeds[adj_g], grid=True, p=processed)
+ if not include_sub_grids: # if not include_sub_grids then skip saving after the first grid
+ break
if not include_sub_grids:
# Done with sub-grids, drop all related information: