Select Scene
Pull one chunk out of a segmented video
- scenes_video
- video frames (batch)
- count
Select Scene is the node that turns "I split my video into chunks" into "now give me chunk 3." It pairs directly with Mixlab's Load Video And Segment node, which takes a source clip and chops it into a list of scene clips (fixed-length chunks by frame count, not actual shot-boundary detection despite the name). That list comes out typed SCENE_VIDEO, and Select Scene is what you use to reach into it and pull one scene back out as a plain, workable IMAGE batch.
The mechanism is about as simple as it looks. scenes_video is the segmented list from upstream, and index (an integer starting at 0) tells the node which scene in that list you want. It hands back two things: video frames (batch), the actual frames of that one scene as an IMAGE batch you can feed into a sampler, an upscaler, or anything else that expects frames, and count, the number of frames in that particular scene. That second output matters more than it looks - if your segmenter used overlapping transition frames, or the source video's length doesn't divide evenly into your chunk size, the last scene in the list can end up shorter than the rest, and count is how you'd notice that from inside the graph rather than by eyeballing the output.
The point of splitting this into two nodes instead of one is exactly what you'd guess: it lets you process scenes independently. Load once, segment once, then run one Select Scene node per index you care about - or drive index from a loop - and treat each chunk as its own little img2img or upscale pass, without holding the whole video's frames in memory at once or forcing every scene through an identical pipeline.
Because scenes_video is a Mixlab-specific type, this node is only ever useful sitting right after Load Video And Segment (or another Mixlab node that emits the same type) - it won't accept a plain video load from VHS or any other pack's video nodes. Once you're past this node, though, you're back in ordinary IMAGE territory and free to route into anything.
Getting the pack is the usual route. Through ComfyUI Manager: search "comfyui-mixlab-nodes," install, restart. Manually:
cd ComfyUI/custom_nodes
git clone https://github.com/shadowcz007/comfyui-mixlab-nodes.git
cd comfyui-mixlab-nodes
install.bat
or pip3 install -r requirements.txt in a venv, or the embedded-python pip call on a portable Windows build. No model download needed - this is indexing into an already-loaded video, not running inference.
The most common way this trips people up is an out-of-range index - set it higher than the number of scenes your video actually produced, and there's nothing there to return. Check scenes_count on the upstream Load Video And Segment node first (or just count how many segments you'd expect given your source video's length and video_segment_frames) before assuming the node is misbehaving. Second: don't expect video frames (batch) to plug straight into a third-party video-combine node without a beat of friction - some downstream nodes are pickier about frame batches that came out of Mixlab's own video plumbing versus a plain VHS load, so if a connection looks like it should work but the graph complains, check that both ends agree on what kind of IMAGE batch is flowing between them. And if you set your segmenter's video_segment_frames very small on a long source clip, remember you're now iterating over a lot of scenes - a Select Scene-per-index loop over a hundred tiny segments adds up fast if each pass is doing real generation work.
Inputs (2)
| Name | Type | Default | Description |
|---|---|---|---|
| scenes_video | SCENE_VIDEO | — | |
| index | INT | 0 | — |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| video frames (batch) | IMAGE | — |
| count | INT | — |