fix sample_images type

This commit is contained in:
minux302
2024-11-17 11:09:05 +00:00
parent b2660bbe74
commit 35778f0218
2 changed files with 15 additions and 18 deletions

View File

@@ -235,7 +235,7 @@ def sample_image_inference(
with accelerator.autocast(), torch.no_grad():
x = denoise(flux, noise, img_ids, t5_out, txt_ids, l_pooled, timesteps=timesteps, guidance=scale, t5_attn_mask=t5_attn_mask, controlnet=controlnet, controlnet_img=controlnet_image)
x = x.float()
# x = x.float() # TODO: check
x = flux_utils.unpack_latents(x, packed_latent_height, packed_latent_width)
# latent to image