diff options
author | AUTOMATIC <16777216c@gmail.com> | 2022-09-06 08:51:34 +0000 |
---|---|---|
committer | AUTOMATIC <16777216c@gmail.com> | 2022-09-06 08:51:34 +0000 |
commit | 5e20657146139557d82dc4d0054ceab619caa700 (patch) | |
tree | 3e397e70bfc1b673d9aa9a80edbb9a82d6fbb62c /modules/images.py | |
parent | 3f55d9a932145133e63000331fac1e180aed41f6 (diff) | |
download | stable-diffusion-webui-gfx803-5e20657146139557d82dc4d0054ceab619caa700.tar.gz stable-diffusion-webui-gfx803-5e20657146139557d82dc4d0054ceab619caa700.tar.bz2 stable-diffusion-webui-gfx803-5e20657146139557d82dc4d0054ceab619caa700.zip |
fix grid overwriting bug
Diffstat (limited to 'modules/images.py')
-rw-r--r-- | modules/images.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/images.py b/modules/images.py index 4226db00..3399887d 100644 --- a/modules/images.py +++ b/modules/images.py @@ -267,8 +267,8 @@ def save_image(image, path, basename, seed=None, prompt=None, extension='png', i filecount = len([x for x in os.listdir(path) if os.path.splitext(x)[1] == '.' + extension])
fullfn = "a.png"
fullfn_without_extension = "a"
- for i in range(100):
- fn = f"{filecount:05}" if basename == '' else f"{basename}-{filecount:04}"
+ for i in range(500):
+ fn = f"{filecount+i:05}" if basename == '' else f"{basename}-{filecount+i:04}"
fullfn = os.path.join(path, f"{fn}{file_decoration}.{extension}")
fullfn_without_extension = os.path.join(path, f"{fn}{file_decoration}")
if not os.path.exists(fullfn):
|