fix
Browse files- pipeline.py +2 -2
pipeline.py
CHANGED
@@ -971,8 +971,8 @@ class StableDiffusionControlNetImg2ImgPipeline(DiffusionPipeline, TextualInversi
|
|
971 |
with self.progress_bar(total=num_inference_steps) as progress_bar:
|
972 |
for i, t in enumerate(timesteps):
|
973 |
# expand the latents if we are doing classifier free guidance
|
974 |
-
|
975 |
-
latent_model_input = torch.cat([latents] * 2) if do_classifier_free_guidance else latents.clone()
|
976 |
|
977 |
|
978 |
latent_model_input = self.scheduler.scale_model_input(latent_model_input, t)
|
|
|
971 |
with self.progress_bar(total=num_inference_steps) as progress_bar:
|
972 |
for i, t in enumerate(timesteps):
|
973 |
# expand the latents if we are doing classifier free guidance
|
974 |
+
latent_model_input = torch.cat([latents] * 2) if do_classifier_free_guidance else latents
|
975 |
+
# latent_model_input = torch.cat([latents] * 2) if do_classifier_free_guidance else latents.clone()
|
976 |
|
977 |
|
978 |
latent_model_input = self.scheduler.scale_model_input(latent_model_input, t)
|