Nodes/ComfyUI-MiniMaxH3-Context-Loop/MiniMaxH3ChainUpscaleHandoff
ComfyUI Node

MiniMaxH3ChainUpscaleHandoff

The node that eats the big frames so the next scene doesn't blow up your VRAM

By ethanfel·Created 30 days ago·Updated about 19 hours ago· 383
MiniMaxH3ChainUpscaleHandoff
  • state
  • images
  • segment
  • upscaled_latent
  • H3_CHAIN_UPSCALE_STATE

MiniMaxH3ChainUpscaleHandoff is the other half of the MiniMax H3 Context Loop pack's upscale memory trick. Where its partner MiniMaxH3ChainUpscaleAdvance keeps the recursion going, this one does the dirty work up front: it consumes the heavy tensors of a just-finished scene and turns them into compact state before the next scene starts. Internal category, auto-generated, not something you add by hand - but understanding it explains why the pack's deferred upscale can chew through a long video without holding every scene's full-resolution frames in memory at once.

What it actually does

Deferred upscale works scene by scene: a saved H3 scene is decoded to RAW HQ frames, pushed through an external upscaler, saved by Upscale Segment Save, and then Upscale Loop End recurses to the next scene. The moment that could kill you is the handover - if the loop kept the finished scene's RGB frames and latent around while it waited, ComfyUI's cache would pin gigabytes per scene.

The handoff node exists to close that gap. It takes in the state plus the scene's full pixel data and persisted record, computes the context/state outputs the next scene needs, and finishes - so by the time the loop advances, those big tensors can be freed.

Its inputs tell the story:

  • state - the current child-run state from Upscale Current Scene.
  • images - the same RAW HQ frames that were sent to Upscale Segment Save.
  • segment - the persisted HQ scene record from Segment Save.
  • upscaled_latent (optional) - a transient HQ latent carry for the next scene. Note it's independent of whether the segment save stores a latent; it's about handing compact context forward, not about disk.

The single output is an H3_CHAIN_UPSCALE_STATE, which feeds straight into the Advance node as its next_state.

What that means for you

Practically: nothing to click, everything to understand. If you're running a deferred-upscale example and see this node appear in the executed graph between Segment Save and the next scene, it's the recursion behaving correctly. Don't rewire it, and definitely don't try to satisfy its inputs by hand - those H3_CHAIN_UPSCALE_STATE and H3_CHAIN_UPSCALE_SEGMENT wires only exist inside the loop.

Install is the pack-wide routine (ComfyUI Manager → search "MiniMax H3 Context Loop", or clone from custom_nodes as in the pack README) with the MiniMax H3 model files installed separately. Where the handoff really earns its keep: multi-scene pixel upscale workflows at high resolution, where a single full RGB buffer runs to gigabytes. If that's your use case, keep the pack current - the handoff/advance split is part of an ongoing memory-improvement effort, and the latest release is where the fixes land.

Category_internal/minimax/upscale

Inputs (4)

NameTypeDefaultDescription
stateH3_CHAIN_UPSCALE_STATECurrent child-run state from Upscale Current Scene.
imagesIMAGESame RAW HQ frames sent to Upscale Segment Save.
segmentH3_CHAIN_UPSCALE_SEGMENTPersisted HQ scene record from Upscale Segment Save.
upscaled_latentoptLATENTOptional transient HQ carry for the next scene. It is independent of save_latent.

Outputs (1)

NameTypeDescription
H3_CHAIN_UPSCALE_STATEH3_CHAIN_UPSCALE_STATE