Nodes/ComfyUI/CosmosImageToVideoLatent
ComfyUI Node Runs on cloud

CosmosImageToVideoLatent

Start frame, end frame, and the NVIDIA world-model video it belongs to

By Comfy-Org·Created 4 years ago·Updated 30 minutes ago· 129,853
CosmosImageToVideoLatent
  • vae
  • start_image
  • end_image
  • LATENT
width1280
height704
length121
batch_size1

This is the latent-and-conditioning builder for NVIDIA's Cosmos video world models, and it does one thing Wan's I2V node doesn't: it can anchor both ends of the clip. Give it a start_image, an end_image, or both, and it builds a latent video where the start and/or end are fixed frames and everything between is generated. That makes it the tool for transition shots, loop-ish clips, and "start here, end there, invent the middle" prompts - the kind of framing you can't get from a first-frame-only pipeline.

How it works

The node creates an empty latent tensor with the Cosmos VAE's temporal compression (8x: length frames become ((length-1)//8)+1 latent frames), then optionally encodes your start_image and writes it into the front, encodes your end_image and writes it into the back. It also builds a noise mask that's zero (locked, no sampling) over the anchored frames and one elsewhere, so the sampler knows the endpoints are fixed facts rather than regions to redraw. No conditioning in, no conditioning out - this node is purely latent-side, and it pairs with a separate text/conditioning encode upstream. The width/height/length/batch_size inputs define the canvas (defaults 1280x704 at 121 frames), and if you leave both images empty it just returns an empty latent - the plain text-to-video case.

The inputs that matter

  • start_image - the first frame. The I2V anchor. If you only feed this, you've built a normal first-frame-to-video setup.
  • end_image - the last frame. The thing the other video nodes can't do. Both anchors together is where this node earns its keep: the model has to connect them, which gives you deliberate transitions and a degree of temporal structure.
  • length / width / height - the clip. The step rules (multiples of 16 for size, 8 for length) come straight from the VAE's compression grid.

The output is a single LATENT that goes into a KSampler using the Cosmos video checkpoint.

How you get it and the honest context

It ships with ComfyUI core. The model files are NVIDIA's Cosmos checkpoints plus the Cosmos VAE and text encoder in models/. And now the honesty: Cosmos never really got adopted by the local generation community. It was built as a "world foundation model" for robotics and simulation - the image/video head was a component, not a product - and its own release thread wrote it off as not competitive with Flux. NVIDIA archived the original Cosmos repo in favor of Cosmos-Predict2.5. The interesting second life is indirect: the 2B variant of Cosmos-Predict2 became the base of Anima, which did take off, but that's a different node (CosmosPredict2ImageToVideoLatent serves the Predict2 line). So if you found this node while chasing Anima, you're in the wrong place; if you're here for NVIDIA's video world models, the end-image anchoring is a genuinely unique feature worth playing with - just don't expect a thriving ecosystem around it.

Categorymodel/conditioning/cosmos

Inputs (7)

NameTypeDefaultDescription
vaeVAE
widthINT128016–16384
heightINT70416–16384
lengthINT1211–16384
batch_sizeINT11–4096
start_imageoptIMAGE
end_imageoptIMAGE

Outputs (1)

NameTypeDescription
LATENTLATENT