Scene detect & split π₯ π π π £π
Split your video into scenes inside ComfyUI, no DaVinci required
- images
- scene_1
- scene_2
- scene_3
- scene_4
- scene_5
- remaining_frames
- scene_frames
- scene_summary
- scene_count
Scene detect & split takes a batch of video frames that are already sitting in your graph and cuts it into separate scenes for you. No ffmpeg, no external tool, no leaving ComfyUI. If you've ever manually scrubbed through a video to find where the shot changes so you can treat each scene differently - per-scene prompts, per-scene img2img, a keyframe from each cut - this is the node that stops you doing that by hand. It's the kind of thing people normally offload to DaVinci Resolve or a PySceneDetect script; this packs it onto a wire.
The node is part of Burgstall-labs' helper pack (the "Burgstall Enabling The Awesomeness" suite, hence the π π π £π branding), a small MIT-licensed grab bag of video and text utilities. Nothing to download beyond the pack itself - no model files.
How it works
Under the hood it's PySceneDetect, the standard Python scene-detection library, driven by its ContentDetector. The trick is that PySceneDetect normally wants a video file, so the node writes your image batch out to a temporary mp4 with OpenCV, runs the detector, reads the scene boundaries back, and slices your original tensor at those frame numbers. There's a temp file write/read roundtrip on every run, so don't expect zero-cost - but for a few hundred frames it's effectively instant.
ContentDetector scores how much consecutive frames differ; a big jump means a scene change. That's exactly what threshold tunes.
The inputs that matter
Honestly, there's only one you'll touch:
images- the frame batch. Feed it whatever you already decoded, e.g. the frames output from a video loader or a generated video's VAE-decode.threshold(default 27) - sensitivity. The author's tooltip says it straight: lower values (15β20) detect more scene changes, higher values (30β40) fewer. Start at the default and move up, not down - see the gotchas.
What you get out
scene_1throughscene_5- the first five detected scenes as separate image batches, each containing all the frames of that scene. If the video has only two cuts,scene_3βscene_5come back empty. Wire each into whatever you process per-scene.remaining_frames- everything after scene 5. This is the chain output: feed it into a second Scene detect & split node to grab scenes 6β10, then repeat. That's how you handle long videos.scene_frames- a small preview batch of the start/end frame of each scene, handy for a quick visual check.scene_summary- a string with total frames, scenes detected vs. output, and the exact frame ranges. Read it in a preview node; it tells you if you're over-segmenting.scene_count- total scenes detected in the whole batch, not capped at five. If this is much larger than the five you got, you know chaining is needed.
Install
ComfyUI Manager is easiest - search "BETA-Helpernodes" (or "Burgstall") and install. Manually:
cd ComfyUI/custom_nodes
git clone https://github.com/Burgstall-labs/ComfyUI-BETA-Helpernodes.git
Then restart ComfyUI. The pack ships a requirements.txt that includes scenedetect[opencv] and opencv-python, and Manager normally installs it; if you cloned by hand, run pip install -r requirements.txt in your ComfyUI environment. Worth knowing: this pack was previously named ComfyUI-BETA-Cropnodes and some registry metadata still references the old folder, so if you had that old install, delete it and reinstall under the new name.
Gotchas
The big one is over-segmentation. PySceneDetect's ContentDetector is twitchy - there's a standing complaint in the community that its default segmentation is so fine-grained it "destroys the consistency of the video" when you split on every detected cut. Camera pans, cuts between similar-looking shots, and compression noise all score as changes. If your scene_count looks absurd, raise threshold toward 35β40 before you blame the node.
The other classic: the node exists on the menu but silently doesn't load. The pack wraps its imports in try/except, so if scenedetect is missing, the rest of the pack loads fine and this node just never registers. Check your console for a "[BETA Helper Nodes] Failed to import" line - that means the dependency didn't install.
Inputs (2)
| Name | Type | Default | Description |
|---|---|---|---|
| images | IMAGE | β | |
| threshold | FLOAT | 27.00β100 | Detection sensitivity threshold. Lower values (e.g., 15-20) detect more scene changes (more sensitive). Higher values (e.g., 30-40) detect fewer scene changes (less sensitive). Default: 27.0 |
Outputs (9)
| Name | Type | Description |
|---|---|---|
| scene_1 | IMAGE | β |
| scene_2 | IMAGE | β |
| scene_3 | IMAGE | β |
| scene_4 | IMAGE | β |
| scene_5 | IMAGE | β |
| remaining_frames | IMAGE | β |
| scene_frames | IMAGE | β |
| scene_summary | STRING | β |
| scene_count | INT | β |