Update app.py
Browse files668 unmodified lines669670671672673674675676677678679680681668 unmodified linesrequested_steps = steps if custom_schedule else steps + 1started = time.time()with pk.use_schedule(PIPE, steps, schedule, video_shift, audio_shift, sampler_name=sampler, seed=int(seed),total_steps=total_steps, stage_from=stage_from,):with use_dpmpp_2s_ancestral(PIPE, int(seed), enabled=(sampler == "dpmpp_2s_ancestral")):with use_dpmpp_sde_gpu(PIPE, int(seed), enabled=(sampler == "dpmpp_sde_gpu")):with use_seeds_2(PIPE, int(seed), enabled=(sampler == "seeds_2")):# Staged Denoising: resuming hands the pipeline the previous stage's own latents instead of# letting `PrepareLatentsStep` draw fresh noise — both are declared-optional inputs on that# step precisely for this ("used instead of the draw"), so nothing else about the call668 unmodified lines669670671672673674675676677678679680681682683684685686687668 unmodified linesrequested_steps = steps if custom_schedule else steps + 1started = time.time()# A fresh generator per stage (see `use_schedule`'s docstring) is fine on its own — each stage's noise is# still a mathematically valid draw, just not a continuation of the last stage's stream. What isn't fine:# reseeding to the *identical* literal seed every single stage means every stage's first draws are the# exact same bits, every time — offsetting by `stage_from` (0 on a fresh/single-stage call, so this changes# nothing there) means each stage actually draws a different stream.effective_seed = int(seed) + stage_fromwith pk.use_schedule(PIPE, steps, schedule, video_shift, audio_shift, sampler_name=sampler, seed=effective_seed,total_steps=total_steps, stage_from=stage_from,):with use_dpmpp_2s_ancestral(PIPE, effective_seed, enabled=(sampler == "dpmpp_2s_ancestral")):with use_dpmpp_sde_gpu(PIPE, effective_seed, enabled=(sampler == "dpmpp_sde_gpu")):with use_seeds_2(PIPE, effective_seed, enabled=(sampler == "seeds_2")):# Staged Denoising: resuming hands the pipeline the previous stage's own latents instead of# letting `PrepareLatentsStep` draw fresh noise — both are declared-optional inputs on that# step precisely for this ("used instead of the draw"), so nothing else about the call
app.py+10-4