From b0eb1654730e02e3d571c49c0ce90327a5d68101 Mon Sep 17 00:00:00 2001 From: huangfeice Date: Mon, 6 Jul 2026 16:58:50 +0800 Subject: [PATCH] small note: why JoyImage text-encode nodes emit the bucketed image Unlike TextEncodeQwenImageEdit, the JoyImage nodes resize to a discrete bucket, so the target size can't be recomputed downstream. Keep the image output and document that it feeds VAEEncode for a matching-size init latent. --- comfy_extras/nodes_joyimage.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/comfy_extras/nodes_joyimage.py b/comfy_extras/nodes_joyimage.py index 00f7b072d..bc5eb05aa 100644 --- a/comfy_extras/nodes_joyimage.py +++ b/comfy_extras/nodes_joyimage.py @@ -74,6 +74,8 @@ class TextEncodeJoyImageEdit(io.ComfyNode): ref_latent = vae.encode(resized_image) conditioning = node_helpers.conditioning_set_values(conditioning, {"reference_latents": [ref_latent]}, append=True) + # Return the bucketed image so VAEEncode can build a matching-size init latent; + # the bucket size isn't reproducible outside this node. return io.NodeOutput(conditioning, resized_image) @@ -140,8 +142,8 @@ class TextEncodeJoyImageEditPlus(io.ComfyNode): conditioning, {"reference_latents": ref_latents}, append=True, ) - # The last reference sets the target resolution; return it for VAEEncode and the - # matching negative encode. + # The last reference sets the target resolution; return it for VAEEncode + # since the bucket size isn't reproducible outside this node. return io.NodeOutput(conditioning, resized_images[-1])