Minimax_H3_Seam_Correction
Sanding the seams off your chunked MiniMax H3 videos
- images
- images
Chunked video generation has a tell: the boundaries. Split a long video into pieces, and each chunk comes out with its own exposure and white balance, so the joins show up as brightness and color jumps, plus the occasional motion hiccup where one chunk's ending doesn't quite flow into the next one's opening. This node exists to sand those joins down - in pixel space, after VAE decode, before you save.
It slots in at the end of the pipeline: sampler latent → VAE Decode → H3SeamCorrection → save. Feed it the full decoded frame sequence as images, get the corrected frames back out of the same-named images output. That's the whole wiring job.
The two knobs that do the heavy lifting
fix_color_preset(defaultmedium) handles exposure/color level jumps.off,low,medium,high,max. The low/medium tiers do per-channel brightness gain -mediumonly touches the actual seam-level jump, which is why it's both the default and the recommendation.highswitches to a linear color transfer (MKL) with a longer statistics window, more stable when there's lots of motion.maxnormalizes brightness across the whole clip and kills in-chunk drift - but it also flattens legitimate darkening (sunsets, driving into a tunnel), and the node itself reports it can't do anything useful with near-black frames. Somaxis the "I know what I'm doing" tier.fix_motion_preset(defaultoff) does optical-flow alignment plus local blending across the seam to fix motion and structural discontinuity. Off is the right starting point - the README says to try the color fix alone first. Each step up blends more frames and adds a touch of softness or breathing to fast motion, so don't max this out reflexively.
The finer controls
fix_flash+flash_threshold(0.30) catch transient brightness spikes at boundaries - but if your scene legitimately has lightning or explosions, the suppression will flatten those too.cut_threshold(15) feeds PySceneDetect, the CPU scene detector that tells the node where real cuts are so it doesn't blend across an intentional edit. Lower is more sensitive; the recommended range is 10–20.blend_frames(2) widens the brightness transition window across each seam. Smoother, but blurrier on fast motion; 0 disables it.use_gpu(true) runs the statistics, color transform and optical flow on CUDA, with automatic CPU fallback if CUDA isn't available.
One honest caveat straight from the README: this fixes seams in the decoded video only. Artifacts baked in by a sloppy second pass upstream won't be rescued here - don't treat it as a magic cleanup node for anything that isn't a chunk boundary.
Install and a bit of history
Same install as the rest of the pack - ComfyUI Manager search ComfyUI_MinimaxH3_AutoContext, or:
cd ComfyUI/custom_nodes
git clone https://github.com/supElement/ComfyUI_MinimaxH3_AutoContext.git
then restart ComfyUI. This node is why the pack's requirements.txt includes scenedetect and opencv-python-headless alongside the torch/numpy ComfyUI already has. There's a reason for that pairing: an earlier version shipped a shot-detection model that caused "white screen" previews in the sampler, so v0.5.8 ripped it out and replaced it with PySceneDetect - pure CPU, no contamination risk. It's a small detail, but it tells you the author actively fixes the things that bite.
The defaults here are genuinely sensible. Start with fix_color_preset at medium, fix_motion_preset off, and only escalate when a specific seam misbehaves. It's the least glamorous node in the pack - and the one that makes chunked output look like it was never chunked at all.
Inputs (8)
| Name | Type | Default | Description |
|---|---|---|---|
| images | IMAGE | 解码后的完整视频帧 (接 VAE Decode 输出) | |
| fix_color_preset | COMBO | medium | 色彩/曝光处理档位。 |
| fix_motion_preset | COMBO | off | 接缝连续性处理。基于光流对齐+局部融合,修补运动/结构不连续。 |
| fix_flash | BOOLEAN | false | 闪帧处理,若画面有闪电、爆炸等合理快速明暗变化,抑制会削平这些效果。 |
| flash_threshold | FLOAT | 0.300–1 | 瞬态修正筛选阈值,值越小越激进,推荐 0.20~0.40。 |
| cut_threshold | FLOAT | 15.05–50 | 镜头检测敏感度,值越小越敏感,推荐 10~20 |
| blend_frames | INT | 20–8 | 接缝处电平渐变窗口 (帧)。值越大过渡越缓、但运动大的镜头过大会带来轻微糊感。 |
| use_gpu | BOOLEAN | true | 使用 CUDA GPU 进行统计、色彩变换与光流 |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| images | IMAGE | — |