diff options
author | AUTOMATIC <16777216c@gmail.com> | 2023-01-04 23:56:43 +0300 |
---|---|---|
committer | AUTOMATIC <16777216c@gmail.com> | 2023-01-04 23:56:43 +0300 |
commit | bc43293c640aef65df3136de9e5bd8b7e79eb3e0 (patch) | |
tree | e30f03fe9ab658d44f3225b1d0ceb65c4e9e41f9 /modules/processing.py | |
parent | 81490780949fffed77493b4bd741e96ec737fe27 (diff) |
fix incorrect display/calculation for number of steps for hires fix in progress bars
Diffstat (limited to 'modules/processing.py')
-rw-r--r-- | modules/processing.py | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/modules/processing.py b/modules/processing.py index 9cad05f2..f28e7212 100644 --- a/modules/processing.py +++ b/modules/processing.py @@ -685,10 +685,13 @@ class StableDiffusionProcessingTxt2Img(StableDiffusionProcessing): def init(self, all_prompts, all_seeds, all_subseeds):
if self.enable_hr:
- if state.job_count == -1:
- state.job_count = self.n_iter * 2
- else:
+ if not state.processing_has_refined_job_count:
+ if state.job_count == -1:
+ state.job_count = self.n_iter
+
+ shared.total_tqdm.updateTotal((self.steps + (self.hr_second_pass_steps or self.steps)) * state.job_count)
state.job_count = state.job_count * 2
+ state.processing_has_refined_job_count = True
if self.hr_resize_x == 0 and self.hr_resize_y == 0:
self.extra_generation_params["Hires upscale"] = self.hr_scale
|