FlashVSR Postprocess
Take off the padding FlashVSR put on, optionally fix color
- images
- video
- IMAGE
FlashVSR is a one-step 4x video super-resolution model, and like most video diffusion it doesn't output frames in the shape you handed in. Prepare Video for FlashVSR padded your clip - spatial padding to line up on 128-pixel boundaries, plus tail frames so the temporal layout works - and this node is the cleanup crew: it strips the padding, restores your original frame count and dimensions, and optionally fixes color drift while it's at it. In the intended graph it sits after your VAE decode (stock Wan VAE or Tiny Decode) and before your save node. Every FlashVSR output you've ever seen passed through one of these.
The display name says "Postprocess," and the class says CropFrames, and both are accurate: cropping the padding is the postprocess.
How it works
Two required inputs: images (the decoded, padded IMAGE batch) and video (the FLASHVSR_VIDEO metadata from Prepare Video for FlashVSR). That metadata is load-bearing - it's how the node knows the requested frame count, width, and height, so it can trim the duplicated tail frames and crop the right/bottom alignment padding. FlashVSR's official causal layout starts directly at source frame zero, which is why the output lines up cleanly once the padding goes. One IMAGE comes out, ready to save.
Skip the video wire and the node can't know what to restore to - the graph will either error or give you padded frames you then save by mistake. Keep this node's video input fed from the same Prepare Video node that fed the rest of the chain.
The color correction option
The real decision is color_correction, default off, which preserves the decoder output exactly. When you turn it on:
adain- the fast option. Matches each frame's per-channel mean and contrast to the resized input. This is the one to reach for when the decode looks washed out or shifted versus the source.wavelet_quarter_res- transfers spatially varying low-frequency color at quarter width and height. The README calls it "the practical wavelet mode" - much of the correction with a fraction of the cost.wavelet_full_res- all five blur passes at full output resolution. Exact, and the README is clear that it's the slowest and most memory-intensive option. Only when you're chasing the last bit of color fidelity.
The supporting knobs are memory controls in disguise: color_chunk_size (default 4, min 1) batches the correction to bound temporary memory; color_device (auto/cuda/cpu, default auto) picks where it runs, with GPU work bounded by chunk size in FP16; and inplace_correction (default true) corrects the decoder tensor in chunks instead of allocating a second complete video - disable it only if another workflow branch also consumes the uncorrected output. profile_stages (default off) prints per-stage timings; useful once, annoying always.
Installing it
It ships in the ComfyUI-FlashVSR-Stock pack with the other nine nodes. ComfyUI Manager: search ComfyUI FlashVSR Stock Wan, install, restart. Manual:
cd ComfyUI/custom_nodes
git clone https://github.com/Pizzawookiee/ComfyUI-FlashVSR-Stock.git
cd ComfyUI-FlashVSR-Stock
python -m pip install -r requirements.txt
Restart afterward. This node itself needs no model files (it reads only the decode output and the video metadata), but the rest of the pack needs the FlashVSR weights from pizzawookiee/FlashVSR-1.1 on Hugging Face in ComfyUI/models/flashvsr/. Python deps: einops, safetensors, a Triton runtime.
Common issues
- Output still has padding. You bypassed this node or the
videowire came from somewhere that isn't the matching Prepare Video node. - Color correction changed the whole look. That's its job - if you liked the raw decode, leave
color_correction=off. It's default-off for a reason. - AdaIN looks wrong on dark clips. It's a per-frame mean/contrast match; extreme source grading can exaggerate.
wavelet_quarter_resis the gentler middle ground.
If you remember one thing: this node isn't optional polish, it's the thing that turns padded model output back into the video you asked for.
Inputs (7)
| Name | Type | Default | Description |
|---|---|---|---|
| images | IMAGE | Decoded padded frames from stock VAE Decode. The node removes duplicated tail frames and right/bottom spatial alignment padding. | |
| video | FLASHVSR_VIDEO | Prepared-video metadata used to restore the requested frame count, width, and height. | |
| color_correction | COMBO | off | off preserves the VAE output. adain is the fast option: it matches each frame's per-channel mean and contrast to the resized input. wavelet_quarter_res transfers spatially varying low-frequency color at quarter width and height and is the practical wavelet option. wavelet_full_res performs all five blur passes at the complete output resolution for an exact but much slower result. |
| color_chunk_size | INT | 41–64 | Frames color-corrected together. Larger batches reduce per-frame overhead; 1 minimizes temporary memory. This also batches AdaIN when that mode is selected. |
| color_device | COMBO | auto | Device used by AdaIN/wavelet correction. auto uses a CUDA GPU when available and otherwise CPU. GPU work is bounded by color_chunk_size and uses FP16 workspaces. |
| inplace_correction | BOOLEAN | true | Correct the decoder IMAGE tensor in bounded chunks instead of allocating a second complete video. Disable only when the uncorrected decoder output is also used by another workflow branch. |
| profile_stages | BOOLEAN | false | Print wall time and per-stage color-correction timing for transfers, downsampling, lowpass, upsampling, clamping and output transfer. |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| IMAGE | IMAGE | — |