Nodes/ComfyUI-MiniMaxH3-Contex-Loop/MiniMax H3 Upscale Current Scene
ComfyUI Node

MiniMax H3 Upscale Current Scene

Lazily load one MiniMax H3 checkpoint for its upscale pass, exactly as saved

By ethanfel·Created 17 days ago·Updated about 20 hours ago· 315
MiniMax H3 Upscale Current Scene
  • state
  • state
  • source_latent
  • source_video_latent
  • source_audio_latent
  • clip_index
  • clip_count
  • prompt
  • width
  • height
  • seed
  • trim_frames
  • raw_frames
  • delivered_frames
  • source_audio
  • previous_upscaled_frames
  • previous_upscaled_latent
  • status

Upscale Current Scene is the workhorse of the child upscale loop: it verifies and lazily loads one source scene checkpoint from the selected parent branch, then hands you everything you need to refine it. It's the upscale-loop counterpart to Current Shot in the generation chain - same job (feed the loop the current scene), different diet (it reads checkpoints from disk instead of live state).

"Lazily" is the word that matters. The child loop walks a multi-scene chain, but only the scene being processed is ever pulled out of its checkpoint at a time. You don't load the whole production's latents into VRAM to upscale scene three; you load scene three, upscale it, save it, and move on. That's what makes a deferred upscale pass on a long chain feasible on a single consumer card.

What you get out

The outputs are a checklist of everything an upscale body might want, and they split into two useful halves:

The source material. source_latent - the verified joint H3 video/audio x0 for combined learned upscalers - plus source_video_latent (the 24-channel video-only x0) and source_audio_latent (the original audio latent, so you can recombine it with a refined video rather than re-generating sound). And source_audio, the decoded delivered parent audio when the checkpoint contains it. If your upscaler is video-only and you want to preserve the parent's audio exactly, you take source_video_latent for the refinement and stitch source_audio_latent back in - that's the documented pattern for the H3 latent upscale body.

The context contract. clip_index, clip_count, prompt (the exact saved prompt for this scene), width, height, seed, trim_frames, raw_frames, and delivered_frames - the exact numbers a pass-2 conditioning rebuild needs so your refined frames match the source clock instead of drifting off it. Plus previous_upscaled_frames (the prior scene's delivered HQ context) and previous_upscaled_latent (the prior scene's transient HQ latent, when Loop End received one) for backend continuity between scenes. A status string summarizes the selected x0 route and the exact frame contract.

The state input is the child-run state from Upscale Adapter, passed through unchanged as the state output for Segment Save and Loop End.

Why the contract outputs matter

Upscaling video is a "more pixels over time" job, and that's the least-settled of the three upscaling jobs in the community playbook (the KB's upscaling essay calls it exactly that). The upscale body needs to know precisely how many frames the source scene really has after trimming, what the parent canvas was, and what seed produced it - otherwise a "refinement" quietly becomes a re-generation that changes motion, and you've turned an upscale into a reroll. This node exists to make that impossible to get wrong by hand.

Install

From ComfyUI-MiniMaxH3-Contex-Loop (the Adapter → Current → [your upscale body] → Segment Save → Loop End chain). ComfyUI Manager → search the pack, or:

cd ComfyUI/custom_nodes
git clone https://github.com/ethanfel/ComfyUI-MiniMaxH3-Contex-Loop.git

Restart. No pip deps; current ComfyUI with native Add Guide for MiniMax H3 expected; H3 weights not bundled (and geofenced out of the US/EU/UK/South Korea).

Gotchas

This node loads a checkpoint it trusts - so the checkpoint side of the pipeline (Segment Save in the generation loop, save_latent on the Adapter) has to have been honest. A scene saved without its audio latent won't have source_audio_latent to hand back, and the only fix is re-checkpointing. Also remember the x0 route matters: if your upscaler wants video-only, feed it source_video_latent; feeding it the joint latent is how you get weird cross-stream artifacts.

Categoryconditioning/minimax/contex_loop/upscale

Inputs (1)

NameTypeDefaultDescription
stateH3_CHAIN_UPSCALE_STATECurrent child-run state from Upscale Adapter.

Outputs (17)

NameTypeDescription
stateH3_CHAIN_UPSCALE_STATEUnchanged current child-run state for Segment Save and Loop End.
source_latentLATENTVerified joint H3 video/audio x0 for combined learned upscalers.
source_video_latentLATENTVerified 24-channel H3 video x0 for video-only upscalers.
source_audio_latentLATENTOriginal H3 audio latent to preserve when recombining a refined video.
clip_indexINTOne-based source scene index.
clip_countINTTotal scene count in the selected parent branch.
promptSTRINGExact saved prompt for this source scene.
widthINTParent generation width used to rebuild H3 pass-2 conditioning.
heightINTParent generation height used to rebuild H3 pass-2 conditioning.
seedINTSaved parent scene seed, suitable for deterministic pass-2 noise.
trim_framesINTRepeated raw head frames that Segment Save removes after refinement.
raw_framesINTExpected raw frame count before the repeated head is removed.
delivered_framesINTExpected delivered frame count after trimming.
source_audioAUDIODecoded delivered parent audio, when the checkpoint contains it.
previous_upscaled_framesIMAGEPrior scene's delivered HQ context frames for backend continuity.
previous_upscaled_latentLATENTPrior scene's transient HQ latent, when Loop End received one.
statusSTRINGSource scene, selected x0 route, and exact frame contract.