Nodes/comfyui_cv/CV Temporal Reduce (Background Plate)
ComfyUI Node

CV Temporal Reduce (Background Plate)

Collapses a whole batch of frames to ONE image by reducing each pixel OVER TIME (across the batch) - the standard way to recover the empty 'background plate' of a fixed-camera video. With the MEDIAN, anything that moves occupies each pixel only a minority of the time and averages out, leaving the static scene (pedestrians, cars vanish); mean is smoother but ghosts moving objects, min/max pick the darkest/brightest value seen. Feed a video IMAGE batch (LoadVideo -> Get Video Components); the plate comes out as a BGR uint8 NPARRAY. A LATENT batch ({'samples': [B,C,H,W]}) also works - the same per-pixel reduction runs over the batch axis in latent space and the plate comes out as a FLOAT32 (H,W,C) NPARRAY (latent values are never uint8-quantized), any channel count. Pair it with 'CV Background Model (Update)' (wire the plate into 'mean', set learning_rate 0) to flag whatever differs from the background in each frame. Also a generic temporal denoiser / long-exposure. Best with frames spread across the clip so moving objects sit in different places.

By bmad4ever·Created 3 months ago·Updated 2 days ago· 0
CV Temporal Reduce (Background Plate)
  • images
  • plate
statisticmedian (robust static background)
Categoryimage/CV/segmentation

Inputs (2)

NameTypeDefaultDescription
imagesIMAGE,LATENTVideo frames to reduce over time: an IMAGE batch (e.g. 'Get Video Components' images) or a LATENT batch ({'samples': [B,C,H,W]}). The reduction runs over the batch dimension, one output pixel per input pixel. A LATENT is reduced in float32 latent space (values untouched, any channel count); an IMAGE reduces to BGR uint8.
statisticCOMBOmedian (robust static background)Per-pixel reduction over time. Median = robust static background (moving objects drop out); mean = smooth average (ghosts movers); min/max = darkest/brightest.

Outputs (1)

NameTypeDescription
plateNPARRAYThe reduced background plate - BGR uint8 (H,W,3) for an IMAGE batch, or FLOAT32 (H,W,C) for a LATENT batch. Wire into 'CV Background Model (Update)' as 'mean', or preview it with 'Preview CV Array'.