Skip to main content
This node loads video files and their associated text captions from a selected subfolder in the ComfyUI input directory, and returns them as two lists: videos and captions. The video entries are lazy references, so frames are decoded only when a downstream node needs them. Supported formats are MP4, AVI, MOV, WEBM, MKV, and FLV. Nested folders with a repeat-count prefix (for example 5_classname/, as used by tools like kohya-ss/sd-scripts) are also supported.

Inputs

If the selected folder contains no files with a supported video extension, the node raises an error. For nested folders whose name starts with a number followed by an underscore (for example 5_classname), each video inside that folder is included in the dataset the number of times given by that prefix.

Outputs

This documentation was AI-generated. If you find any errors or have suggestions for improvement, please feel free to contribute! Edit on GitHub

Source fingerprint (SHA-256): 91236fcb1e42b8de1a1100b0aecaad49bd49c159d7d8f502032cd7f5b2b54845