From 2eec756fab705c103056137473bc571229d488ce Mon Sep 17 00:00:00 2001 From: Bryce Date: Sat, 24 Sep 2022 10:24:51 -0700 Subject: [PATCH] feature: have initial generated images in their own folder --- imaginairy/api.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/imaginairy/api.py b/imaginairy/api.py index de0e6e0..6db5c1a 100755 --- a/imaginairy/api.py +++ b/imaginairy/api.py @@ -124,8 +124,8 @@ def imagine_image_files( ): prompt = result.prompt basefilename = f"{base_count:06}_{prompt.seed}_{prompt.sampler_type}{prompt.steps}_PS{prompt.prompt_strength}_{prompt_normalized(prompt.prompt_text)}" - filepath = os.path.join(outdir, f"{basefilename}.jpg") - + filepath = os.path.join(outdir, "generated", f"{basefilename}.jpg") + os.makedirs(filepath, exist_ok=True) result.save(filepath) logger.info(f" 🖼 saved to: {filepath}") if result.upscaled_img: