cleanup logging

This commit is contained in:
Vladimir Mandic
2023-12-27 19:49:13 -05:00
parent fd91b4b111
commit 1a0e3c6bee
4 changed files with 10 additions and 9 deletions
+4 -3
View File
@@ -210,7 +210,7 @@ class StableDiffusionProcessing:
self.s_tmax = float('inf') # not representable as a standard ui option
shared.opts.data['clip_skip'] = clip_skip
self.task_args = {}
# TODO a1111 compatibility items
# a1111 compatibility items
self.refiner_switch_at = 0
self.hr_prompt = ''
self.all_hr_prompts = []
@@ -596,8 +596,6 @@ def create_infotext(p: StableDiffusionProcessing, all_prompts=None, all_seeds=No
"Model": None if (not shared.opts.add_model_name_to_info) or (not shared.sd_model.sd_checkpoint_info.model_name) else shared.sd_model.sd_checkpoint_info.model_name.replace(',', '').replace(':', ''),
"Model hash": getattr(p, 'sd_model_hash', None if (not shared.opts.add_model_hash_to_info) or (not shared.sd_model.sd_model_hash) else shared.sd_model.sd_model_hash),
"VAE": (None if not shared.opts.add_model_name_to_info or modules.sd_vae.loaded_vae_file is None else os.path.splitext(os.path.basename(modules.sd_vae.loaded_vae_file))[0]) if p.full_quality else 'TAESD',
"Variation seed": None if p.subseed_strength == 0 else all_subseeds[index],
"Variation 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}",
"Clip skip": p.clip_skip if p.clip_skip > 1 else None,
"Prompt2": p.refiner_prompt if len(p.refiner_prompt) > 0 else None,
@@ -613,6 +611,9 @@ def create_infotext(p: StableDiffusionProcessing, all_prompts=None, all_seeds=No
}
if 'txt2img' in p.ops:
pass
if shared.backend == shared.Backend.ORIGINAL:
args["Variation seed"] = None if p.subseed_strength == 0 else all_subseeds[index],
args["Variation strength"] = None if p.subseed_strength == 0 else p.subseed_strength,
if 'hires' in p.ops or 'upscale' in p.ops:
args["Second pass"] = p.enable_hr
args["Hires force"] = p.hr_force