Skip to content

Commit de64146

Browse files
committed
add number of itter
1 parent a9e9799 commit de64146

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

modules/processing.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -510,7 +510,7 @@ def infotext(iteration=0, position_in_batch=0):
510510
break
511511

512512
if p.scripts is not None:
513-
p.scripts.process_one(p)
513+
p.scripts.process_one(p, n)
514514

515515
with devices.autocast():
516516
uc = prompt_parser.get_learned_conditioning(shared.sd_model, len(prompts) * [p.negative_prompt], p.steps)

modules/scripts.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ def process(self, p, *args):
7070

7171
pass
7272

73-
def process_one(self, p, *args):
73+
def process_one(self, p, n, *args):
7474
"""
7575
Same as process(), but called for every iteration
7676
"""
@@ -301,11 +301,11 @@ def process(self, p):
301301
print(f"Error running process: {script.filename}", file=sys.stderr)
302302
print(traceback.format_exc(), file=sys.stderr)
303303

304-
def process_one(self, p):
304+
def process_one(self, p, n):
305305
for script in self.alwayson_scripts:
306306
try:
307307
script_args = p.script_args[script.args_from:script.args_to]
308-
script.process_one(p, *script_args)
308+
script.process_one(p, n, *script_args)
309309
except Exception:
310310
print(f"Error running process_one: {script.filename}", file=sys.stderr)
311311
print(traceback.format_exc(), file=sys.stderr)

0 commit comments

Comments
 (0)