Unverified Commit a8322ad7 authored by AUTOMATIC1111's avatar AUTOMATIC1111 Committed by GitHub
Browse files

Merge pull request #6854 from EllangoK/master

Saves Extra Generation Parameters to params.txt
parents 43fd6eaa 5e15a0b4
Loading
Loading
Loading
Loading
+4 −4
Original line number Diff line number Diff line
@@ -538,10 +538,6 @@ def process_images_inner(p: StableDiffusionProcessing) -> Processed:
    if p.scripts is not None:
        p.scripts.process(p)

    with open(os.path.join(shared.script_path, "params.txt"), "w", encoding="utf8") as file:
        processed = Processed(p, [], p.seed, "")
        file.write(processed.infotext(p, 0))

    infotexts = []
    output_images = []

@@ -572,6 +568,10 @@ def process_images_inner(p: StableDiffusionProcessing) -> Processed:
        with devices.autocast():
            p.init(p.all_prompts, p.all_seeds, p.all_subseeds)

        with open(os.path.join(shared.script_path, "params.txt"), "w", encoding="utf8") as file:
            processed = Processed(p, [], p.seed, "")
            file.write(processed.infotext(p, 0))

        if state.job_count == -1:
            state.job_count = p.n_iter