aboutsummaryrefslogtreecommitdiffstats
path: root/modules/processing.py
diff options
context:
space:
mode:
authorAUTOMATIC1111 <16777216c@gmail.com>2022-10-03 04:54:57 +0000
committerGitHub <noreply@github.com>2022-10-03 04:54:57 +0000
commit3fac3764b3fadce828ceffdb7dea2be51bbe7da7 (patch)
treeb2307b40ed86dc825d9954f470a2b1663dfed30a /modules/processing.py
parent32edf1732f27a1fad5133667c22b948adda1b070 (diff)
parent4c2eccf8e96825333ed400f8a8a2be78141ed8ec (diff)
downloadstable-diffusion-webui-gfx803-3fac3764b3fadce828ceffdb7dea2be51bbe7da7.tar.gz
stable-diffusion-webui-gfx803-3fac3764b3fadce828ceffdb7dea2be51bbe7da7.tar.bz2
stable-diffusion-webui-gfx803-3fac3764b3fadce828ceffdb7dea2be51bbe7da7.zip
Merge branch 'master' into #1484_fix_empty_styles_pattern
Diffstat (limited to 'modules/processing.py')
-rw-r--r--modules/processing.py13
1 files changed, 8 insertions, 5 deletions
diff --git a/modules/processing.py b/modules/processing.py
index 1da753a2..0a4b6198 100644
--- a/modules/processing.py
+++ b/modules/processing.py
@@ -56,7 +56,7 @@ class StableDiffusionProcessing:
self.prompt: str = prompt
self.prompt_for_display: str = None
self.negative_prompt: str = (negative_prompt or "")
- self.styles: str = styles
+ self.styles: list = styles or []
self.seed: int = seed
self.subseed: int = subseed
self.subseed_strength: float = subseed_strength
@@ -271,7 +271,7 @@ def create_infotext(p, all_prompts, all_seeds, all_subseeds, comments, iteration
"Variation seed strength": (None if p.subseed_strength == 0 else p.subseed_strength),
"Seed resize from": (None if p.seed_resize_from_w == 0 or p.seed_resize_from_h == 0 else f"{p.seed_resize_from_w}x{p.seed_resize_from_h}"),
"Denoising strength": getattr(p, 'denoising_strength', None),
- "Eta": (None if p.sampler.eta == p.sampler.default_eta else p.sampler.eta),
+ "Eta": (None if p.sampler is None or p.sampler.eta == p.sampler.default_eta else p.sampler.eta),
}
generation_params.update(p.extra_generation_params)
@@ -295,8 +295,11 @@ def process_images(p: StableDiffusionProcessing) -> Processed:
fix_seed(p)
- os.makedirs(p.outpath_samples, exist_ok=True)
- os.makedirs(p.outpath_grids, exist_ok=True)
+ if p.outpath_samples is not None:
+ os.makedirs(p.outpath_samples, exist_ok=True)
+
+ if p.outpath_grids is not None:
+ os.makedirs(p.outpath_grids, exist_ok=True)
modules.sd_hijack.model_hijack.apply_circular(p.tiling)
@@ -323,7 +326,7 @@ def process_images(p: StableDiffusionProcessing) -> Processed:
return create_infotext(p, all_prompts, all_seeds, all_subseeds, comments, iteration, position_in_batch)
if os.path.exists(cmd_opts.embeddings_dir):
- model_hijack.load_textual_inversion_embeddings(cmd_opts.embeddings_dir, p.sd_model)
+ model_hijack.embedding_db.load_textual_inversion_embeddings()
infotexts = []
output_images = []