996 B
996 B
Select Every Nth
Keeps every nth frame of an IMAGE batch — halve a video's frame count
before an expensive stage, or thin a long sweep down to samples.
Controls
- images: The BHWC batch to thin out.
- Every nth (
nth): Keep one frame in everynth.2keeps every other frame,1keeps everything (useful with offset alone to drop leading frames). - offset: Frames to skip before the first kept frame. With
nth2, offset0keeps frames 1, 3, 5 and offset1keeps frames 2, 4, 6 (one-based, as the rest of the pack counts frames). - fps (optional socket): The batch's frame rate, such as Load Video's
fpsoutput.
Outputs
- images: The kept frames, in their original order.
- fps: The wired rate divided by
nth, so the kept frames still span the same time;0when no fps is wired.
An offset at or past the end of the batch stops with the batch's size instead of returning an empty batch, which no downstream node could use.