Kandinsky2.2 Hint Combiner
Kandinsky 2.2 Hint Combiner — Sticking a Depth Map Into the Latents
- hint
- latents
- LATENT
This is the depth-control node, and it's the most unusual thing in the pack. Kandinsky 2.2 doesn't do ControlNet the way SDXL does - it has a special decoder variant, kandinsky-2-2-controlnet-depth, whose UNet accepts a depth hint as part of its conditioning. The Hint Combiner is how you get that hint from an ordinary image into the latents where the UNet expects it.
How it works
The node takes a hint image and the latents from the Latents or Image Latents node, then attaches the hint to the latent object (resizing it to match the latent resolution scaled back up by the VAE's factor). Downstream, the Unet Decoder passes that hint into the UNet's added_cond_kwargs - so the depth structure directly steers the denoising. It's a neat, lightweight take on guided generation that predates most of what people call ControlNet today.
The depth map itself comes from elsewhere. The pack's depth workflow uses MarigoldDepthEstimation (a separate node the README says you can install via ComfyUI Manager) followed by ColorizeDepthmap, and the README's warning is worth quoting: "Don't forget to switch to kandinsky-2-2-controlnet-depth in decoder node." Wire the whole depth chain with the plain decoder and the hint is silently ignored.
Inputs and output
hint- an IMAGE, i.e. your depth map (colorized or not - it gets normalized anyway).latents- aLATENTfromcomfy-kandinsky22-latentsorcomfy-kandinsky22-img-latents.
Output: LATENT, back into the Unet Decoder's latents port.
Installing it
Manual install, per the README (not in ComfyUI Manager's list):
cd ComfyUI/custom_nodes
git clone https://github.com/vsevolod-oparin/comfyui-kandinsky22
cd comfyui-kandinsky22
python -s -m pip install -r requirements.txt
Models - note the third one is the whole point for depth:
git clone --depth 1 https://huggingface.co/kandinsky-community/kandinsky-2-2-prior
git clone --depth 1 https://huggingface.co/kandinsky-community/kandinsky-2-2-decoder
git clone --depth 1 https://huggingface.co/kandinsky-community/kandinsky-2-2-controlnet-depth
Gotchas
- The decoder mismatch is the #1 failure. Hint attached but no depth effect? Check that the Decoder Loader is on
kandinsky-2-2-controlnet-depth. It's the only thing that makes this node do anything. - Latents must come from the Latents/Image Latents nodes, not the Unet Decoder's output. A hint gets attached to the initial latents; the decoder then uses them. Reversing the order means the hint never reaches the UNet.
- Dependency pin. Old
diffuserscommit andaccelerate==0.27.2inrequirements.txtcan break other nodes in the shared environment. - History lesson, honestly. Kandinsky 2.2's depth control was impressive in 2023 and the community has since moved on - this is a fun archaeology project, not something you'd reach for to guide Flux.
Wired right, the chain is: Latents → Hint Combiner (with a Marigold depth map as hint) → Unet Decoder → MovQ Decoder. That's the entire depth workflow.
Inputs (2)
| Name | Type | Default | Description |
|---|---|---|---|
| hint | IMAGE | — | |
| latents | LATENT | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| LATENT | LATENT | — |