fix: SDXL Refiner not working properly with Inpainting

This commit is contained in:
blessedcoolant
2024-04-09 07:19:16 +05:30
committed by psychedelicious
parent 381b41a56e
commit fd1f240853
3 changed files with 5 additions and 68 deletions

View File

@ -336,9 +336,6 @@ class StableDiffusionGeneratorPipeline(StableDiffusionPipeline):
).to(device=orig_latents.device, dtype=orig_latents.dtype)
latents = self.scheduler.add_noise(latents, noise, batched_t)
latents = torch.lerp(
orig_latents, latents.to(dtype=orig_latents.dtype), mask.to(dtype=orig_latents.dtype)
)
if is_inpainting_model(self.unet):
if masked_latents is None: