> ## Documentation Index
> Fetch the complete documentation index at: https://dripart-docs-nav-cta-ab-test-try-cloud-free.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# VideoFrameSample - ComfyUI Built-in Node Documentation

> The VideoFrameSample node extracts a fixed number of frames from a video using one of four strategies.

The `VideoFrameSample` node extracts a fixed number of frames from a video using one of four strategies. For the contiguous strategies "head" and "tail", the output is a lazy video reference (frames are not decoded); for the non-contiguous strategies "uniform" and "random", only the selected frames are decoded.

## Inputs

| Parameter    | Description                                                                                      | Data Type | Required | Range                                           |
| ------------ | ------------------------------------------------------------------------------------------------ | --------- | -------- | ----------------------------------------------- |
| `video`      | Input video.                                                                                     | VIDEO     | Yes      | –                                               |
| `num_frames` | Number of frames to sample (default: 16).                                                        | INT       | Yes      | 1 – 9999                                        |
| `strategy`   | uniform: evenly spaced, head: first N, tail: last N, random: random sorted (default: "uniform"). | COMBO     | Yes      | "uniform"<br />"head"<br />"tail"<br />"random" |
| `seed`       | Random seed, only used with the "random" strategy (default: 0).                                  | INT       | Yes      | 0 – 18446744073709551615                        |

* `num_frames` is automatically clamped to the total frame count of the input video.
* The `seed` parameter has no effect unless `strategy` is set to `"random"`.
* When `strategy` is `"uniform"` and `num_frames` is 1, the middle frame of the video is selected.
* An unrecognized `strategy` value raises an error.

## Outputs

| Output Name | Description    | Data Type |
| ----------- | -------------- | --------- |
| `video`     | Sampled video. | VIDEO     |

> This documentation was AI-generated. If you find any errors or have suggestions for improvement, please feel free to contribute! [Edit on GitHub](https://github.com/Comfy-Org/embedded-docs/blob/main/comfyui_embedded_docs/docs/VideoFrameSample/en.md)

***

**Source fingerprint (SHA-256):** `727504a9cf7fe5505c33da071cb8f21a38e1b7c0f964c5da172d9cedfc2f2300`
