Spaces:
Running
on
Zero
Running
on
Zero
Update src/flux/xflux_pipeline.py
Browse files
src/flux/xflux_pipeline.py
CHANGED
@@ -285,7 +285,7 @@ class XFluxPipeline:
|
|
285 |
neg_image_proj=None,
|
286 |
ip_scale=1.0,
|
287 |
neg_ip_scale=1.0,
|
288 |
-
spatial_condition=
|
289 |
source_image=None,
|
290 |
share_position_embedding=False
|
291 |
):
|
@@ -312,7 +312,7 @@ class XFluxPipeline:
|
|
312 |
source_image = self.ae.encode(source_image.to(self.device).to(torch.float32))
|
313 |
# print("ae source image shape:", source_image.shape)
|
314 |
source_image = rearrange(source_image, "b c (h ph) (w pw) -> b (h w) (c ph pw)", ph=2, pw=2).to(inp_cond['img'].dtype)
|
315 |
-
|
316 |
# print("rearrange ae source image shape:", source_image.shape)
|
317 |
|
318 |
if self.offload:
|
|
|
285 |
neg_image_proj=None,
|
286 |
ip_scale=1.0,
|
287 |
neg_ip_scale=1.0,
|
288 |
+
spatial_condition=True,
|
289 |
source_image=None,
|
290 |
share_position_embedding=False
|
291 |
):
|
|
|
312 |
source_image = self.ae.encode(source_image.to(self.device).to(torch.float32))
|
313 |
# print("ae source image shape:", source_image.shape)
|
314 |
source_image = rearrange(source_image, "b c (h ph) (w pw) -> b (h w) (c ph pw)", ph=2, pw=2).to(inp_cond['img'].dtype)
|
315 |
+
print("rearrange ae source image shape:", source_image.shape)
|
316 |
# print("rearrange ae source image shape:", source_image.shape)
|
317 |
|
318 |
if self.offload:
|