Nodes/ComfyUI-KYNode/KY Save Image Sequence
ComfyUI Node

KY Save Image Sequence

Batch-save frames with alpha and a frame range

By yorkane·Created 2 years ago·Updated 6 months ago· 10
KY Save Image Sequence
  • images
  • mask
  • output_dir
  • frame_count
filename_prefixKY_sequence
formatpng
quality95
start_frame0
end_frame-1

The video-flavored sibling of KY_SaveImageToPath. Both save a batch of images to disk as individual numbered files, but this one leans into what video work specifically needs: an alpha channel from a separate mask, and the ability to save only a slice of the batch rather than every frame in it.

How it differs from KY_SaveImageToPath

This node trades KY_SaveImageToPath's fine-grained controls (custom filename # templates, separate JPEG/WebP/PNG compression settings, overwrite/NOTSAVE/show_preview toggles) for two things that pack doesn't have: alpha support via a dedicated mask input, and a start_frame/end_frame slice. Reach for this one specifically when you're exporting a range out of a video-to-frames pipeline - say, trimming a batch down before compositing it with transparency back into an editor - and reach for KY_SaveImageToPath when raw save speed and template control matter more.

Inputs and outputs

Required: images (the batch), filename_prefix (default KY_sequence), format (png/jpg/tiff/webp, default png), quality (1–100).

Optional: mask - feed a MASK here for alpha, and only on formats that actually support transparency (PNG, TIFF, WebP; JPEG has no alpha channel regardless of what you wire in). start_frame (default 0) and end_frame (default -1) let you slice the batch - -1 follows the common convention of meaning "through the last frame," so leaving it at default saves everything from start_frame onward.

Two outputs: output_dir (where the files landed) and frame_count (how many were actually written).

Installing it

ComfyUI Manager: search ComfyUI-KYNode, install, restart. Or:

cd ComfyUI/custom_nodes
git clone https://github.com/yorkane/ComfyUI-KYNode

Restart ComfyUI. Image saving with alpha support typically leans on Pillow or OpenCV under the hood - the README doesn't spell out which for this specific node, but if it fails to import, check your ComfyUI Python environment has the relevant image library installed the same way you would for KY_SaveImageToPath.

Common issues

If your output has no transparency even though you expected it, check that you actually wired something into mask - it's optional, and skipping it means opaque output even on a format that supports alpha.

Picking jpg as format while also feeding a mask won't give you transparency no matter what - JPEG simply doesn't support an alpha channel, so switch to PNG, TIFF, or WebP if that matters.

If you're getting fewer files than you expected, check start_frame/end_frame before assuming something's broken - a leftover non-default end_frame from a previous test is an easy thing to forget you set, and it'll silently cut your export short.

CategoryKY_Video

Inputs (7)

NameTypeDefaultDescription
imagesIMAGE
filename_prefixSTRINGKY_sequence
formatCOMBOpng4 options: png, jpg, tiff, webp
qualityINT951–100
maskoptMASK
start_frameoptINT00–9007199254740991
end_frameoptINT-1-1–9007199254740991

Outputs (2)

NameTypeDescription
output_dirSTRING
frame_countINT