diff options
author | AUTOMATIC1111 <16777216c@gmail.com> | 2023-07-19 12:49:31 +0000 |
---|---|---|
committer | AUTOMATIC1111 <16777216c@gmail.com> | 2023-07-19 12:49:31 +0000 |
commit | 05ccb4d0e3ff38503a2863889e21290e77590ee2 (patch) | |
tree | 2779a542c41b16e7780a229a2c78d1cfb207499a /modules/images.py | |
parent | b010eea520caa90d2a31d98ec7c4a9d9d540c9ad (diff) | |
download | stable-diffusion-webui-gfx803-05ccb4d0e3ff38503a2863889e21290e77590ee2.tar.gz stable-diffusion-webui-gfx803-05ccb4d0e3ff38503a2863889e21290e77590ee2.tar.bz2 stable-diffusion-webui-gfx803-05ccb4d0e3ff38503a2863889e21290e77590ee2.zip |
bugfix: model name was added together with directory name to infotext and to [model_name] filename pattern
Diffstat (limited to 'modules/images.py')
-rw-r--r-- | modules/images.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/images.py b/modules/images.py index fb5d2e75..38aa933d 100644 --- a/modules/images.py +++ b/modules/images.py @@ -363,7 +363,7 @@ class FilenameGenerator: 'styles': lambda self: self.p and sanitize_filename_part(", ".join([style for style in self.p.styles if not style == "None"]) or "None", replace_spaces=False),
'sampler': lambda self: self.p and sanitize_filename_part(self.p.sampler_name, replace_spaces=False),
'model_hash': lambda self: getattr(self.p, "sd_model_hash", shared.sd_model.sd_model_hash),
- 'model_name': lambda self: sanitize_filename_part(shared.sd_model.sd_checkpoint_info.model_name, replace_spaces=False),
+ 'model_name': lambda self: sanitize_filename_part(shared.sd_model.sd_checkpoint_info.name_for_extra, replace_spaces=False),
'date': lambda self: datetime.datetime.now().strftime('%Y-%m-%d'),
'datetime': lambda self, *args: self.datetime(*args), # accepts formats: [datetime], [datetime<Format>], [datetime<Format><Time Zone>]
'job_timestamp': lambda self: getattr(self.p, "job_timestamp", shared.state.job_timestamp),
|