Nodes/ComfyUI-VideoHelperSuite/Load Video (Path) πŸŽ₯πŸ…₯πŸ…—πŸ…’
ComfyUI Node Runs on cloud

Load Video (Path) πŸŽ₯πŸ…₯πŸ…—πŸ…’

Pull a video into ComfyUI as frames

By KosinkadinkΒ·Created 3 years agoΒ·Updated 3 months agoΒ· 1,727
Load Video (Path) πŸŽ₯πŸ…₯πŸ…—πŸ…’
  • meta_batch
  • vae
  • IMAGE
  • frame_count
  • audio
  • video_info
β—„videoβ€”β–Ί
β—„force_rate0β–Ί
β—„custom_width0β–Ί
β—„custom_height0β–Ί
β—„frame_load_cap0β–Ί
β—„skip_first_frames0β–Ί
β—„select_every_nth1β–Ί
β—„formatAnimateDiffβ–Ί

Every video workflow starts by turning a video file into a batch of frames, and this is the node that does it when the file lives somewhere on disk rather than in ComfyUI's input folder. Point it at a path, and it hands you the frames as an IMAGE batch that any sampler, ControlNet, or vid2vid graph can chew on. It's part of Kosinkadink's VideoHelperSuite - the same author behind AnimateDiff-Evolved, and the pack basically everyone running AnimateDiff, Wan, Hunyuan, or LTX video reaches for. If you've done vid2vid in ComfyUI, you've used this or its upload-button twin.

The "Path" bit is the whole point: instead of a dropdown of files you've uploaded, you type or paste an arbitrary filesystem path. Handy when your clips live on another drive, get generated by an earlier step, or you're scripting things.

How it works

Under the hood it decodes the video with OpenCV and returns the frames as a standard ComfyUI image batch. The extra widgets exist because raw video is rarely the shape a diffusion model wants - you almost always need to trim it, downsample the frame rate, and cap the length so you don't blow up your RAM.

The inputs and outputs that matter

The video input is the path string. Beyond that, four widgets do the real work:

  • force_rate - resample to a target fps. Motion models are trained at a specific rate (AnimateDiff likes 8), and matching it gives cleaner results. 0 means "leave it alone."
  • frame_load_cap - the max number of frames to load, i.e. your batch size. 0 loads everything, which is how people accidentally try to fit a 2000-frame clip in VRAM. Set a real number.
  • skip_first_frames - trim from the start. Bump this by frame_load_cap each run to walk through a long video in chunks.
  • select_every_nth - keep 1 of every N frames. Better than force_rate for variable-rate inputs like gifs.

custom_width and custom_height resize on load (0 disables). The optional format picks a target model preset (None, AnimateDiff, Mochi, LTXV, Hunyuan, Cosmos, Wan) and nudges the other widgets to sane values for it. Connect an optional vae and the node converts frames straight to latents, which slashes RAM on long sequences - strongly worth it unless you need raw images for something like Apply ControlNet.

Outputs: IMAGE (the frames), frame_count, audio (wire into Video Combine to keep sound), and video_info (feeds a Video Info node for fps/duration).

How to install it

Via ComfyUI Manager: Install Custom Nodes, search ComfyUI-VideoHelperSuite, install, restart. Or manually:

cd ComfyUI/custom_nodes
git clone https://github.com/Kosinkadink/ComfyUI-VideoHelperSuite

then restart. No model weights - VHS is pure plumbing. Its pip deps (opencv, imageio-ffmpeg) install automatically through Manager; a system ffmpeg on your PATH is worth having for the fancier output formats down the line.

Common issues & troubleshooting

"Out of memory" or the machine grinds. Almost always frame_load_cap left at 0. Cap it, or connect a vae so frames become latents instead of full images.

The path won't resolve, or nothing shows. On a shared or cloud instance, arbitrary filesystem paths are often locked down - VHS respects a VHS_STRICT_PATHS env var that restricts loading to ComfyUI's own directories. If that's set, put the file under ComfyUI and use the upload node instead.

Preview doesn't reflect my trim settings. Advanced Previews is off by default. Turn on "VHS Advanced Previews" in the settings gear and the preview will honor frame_load_cap, force_rate, and friends.

Colors or timing look off on a variable-rate gif. Reach for select_every_nth rather than force_rate - it handles VFR inputs more predictably.

CategoryVideo Helper Suite πŸŽ₯πŸ…₯πŸ…—πŸ…’

Inputs (10)

NameTypeDefaultDescription
videoSTRINGβ€”
force_rateFLOAT00–60β€”
custom_widthINT00–8192β€”
custom_heightINT00–8192β€”
frame_load_capINT00–9007199254740991β€”
skip_first_framesINT00–9007199254740991β€”
select_every_nthINT11–9007199254740991β€”
meta_batchoptVHS_BatchManagerβ€”
vaeoptVAEβ€”
formatoptCOMBOAnimateDiff7 options: None, AnimateDiff, Mochi, LTXV, Hunyuan, Cosmos, +1

Outputs (4)

NameTypeDescription
IMAGEIMAGEβ€”
frame_countINTβ€”
audioAUDIOβ€”
video_infoVHS_VIDEOINFOβ€”