Skip to content

Commit b10b3e4

Browse files
committed
Fix BriaFiboEditPipeline to use passed generator parameter
The pipeline was ignoring the generator parameter and only using the seed parameter. This caused non-deterministic outputs in tests that pass a seeded generator.
1 parent 27d4cfb commit b10b3e4

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

src/diffusers/pipelines/bria_fibo/pipeline_bria_fibo_edit.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -762,7 +762,8 @@ def __call__(
762762
batch_size = prompt_embeds.shape[0]
763763

764764
device = self._execution_device
765-
generator = torch.Generator(device=device).manual_seed(seed) if seed is not None else None
765+
if generator is None and seed is not None:
766+
generator = torch.Generator(device=device).manual_seed(seed)
766767
lora_scale = (
767768
self.joint_attention_kwargs.get("scale", None) if self.joint_attention_kwargs is not None else None
768769
)

0 commit comments

Comments
 (0)