Compare commits

...

1 Commits

Author SHA1 Message Date
sayakpaul
cc605aa33e remove syncs before denoising in Kontext 2025-06-27 10:52:57 +05:30
2 changed files with 5 additions and 0 deletions

View File

@@ -898,6 +898,8 @@ class FluxPipeline(
)
# 6. Denoising loop
# We set the index here to remove DtoH sync, helpful especially during compilation.
# Check out more details here: https://github.com/huggingface/diffusers/pull/11696
self.scheduler.set_begin_index(0)
with self.progress_bar(total=num_inference_steps) as progress_bar:
for i, t in enumerate(timesteps):

View File

@@ -1043,6 +1043,9 @@ class FluxKontextPipeline(
)
# 6. Denoising loop
# We set the index here to remove DtoH sync, helpful especially during compilation.
# Check out more details here: https://github.com/huggingface/diffusers/pull/11696
self.scheduler.set_begin_index(0)
with self.progress_bar(total=num_inference_steps) as progress_bar:
for i, t in enumerate(timesteps):
if self.interrupt: