mirror of
https://github.com/comfyanonymous/ComfyUI.git
synced 2026-03-17 23:25:05 +08:00
When a reference image is passed via TextEncodeZImageOmni, its VAE-encoded latent may have odd height or width (e.g. from auto_resize rounding to multiples of 8 pixels). The embed_all() function in the Lumina model tries to reshape the latent as view(B, C, H//2, 2, W//2, 2) for patch embedding, which fails when H or W is not divisible by the patch size (2). Add pad_to_patch_size() before the reshape, matching what the main forward pass already does for the primary latent. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| controlnet.py | ||
| model.py | ||