Unbatch π₯π ₯π π ’
Unbatch
- batched
- unbatched
Unbatch takes a list of things and squashes it down into one concatenated thing. If some part of your graph produced several separate chunks - say, a handful of image batches that each came out of their own branch - and you want a single continuous sequence at the end, this is the node that glues them together.
The name trips people up, so let's be precise about what it isn't. This has no relation to the Meta Batch system of VHS (the thing that streams a long render through in pieces to save memory). It's purely about collapsing a list into one item. Think of it less as "un-batching" in the memory sense and more as "flatten this list into a single output."
Why you'd reach for it
You'd reach for it, in the author's own words, "when you want a single video output from a complex workflow." Some node upstream - a loop, a batch iterator, a fan-out of branches - emitted a list of image batches rather than one big batch. Video Combine wants a single sequence, not a list. Drop an Unbatch in between and the list becomes one concatenated batch you can hand straight to the encoder. It's the connective tissue that turns "several pieces" into "one clip."
How it works
Unbatch is a wildcard node - the input and output types are *, so it accepts whatever you plug in. What it does with the contents depends on the type:
- Torch tensors (images, latents, masks - anything that's really a stacked tensor) get concatenated across dim 0. That's the frame axis, so this genuinely stitches sequences end to end.
- Everything else gets added together. For strings and arrays, "add" means concatenation, which is what you want. For other odd types, adding them may not do anything sensible - the author flags this outright.
So it's rock-solid for the image/latent/mask/string case it was built for, and a bit of a "hold it right" tool outside that.
Inputs and outputs
- batched (input, wildcard
*) - any input that may or may not be a list. If it's already a single item, nothing bad happens. - unbatched (output, wildcard
*) - one element, with the list concatenated down as described above.
There are no widgets. You wire it inline and it just resolves the list.
Installing it
comfy.icu already has VideoHelperSuite in the image, so it's ready to use.
Locally: ComfyUI Manager β search ComfyUI-VideoHelperSuite β install β restart. Or:
cd ComfyUI/custom_nodes
git clone https://github.com/Kosinkadink/ComfyUI-VideoHelperSuite
then restart ComfyUI. It's Kosinkadink's suite, the de facto video toolkit for ComfyUI.
Common issues
The trap is feeding it a type that isn't a tensor, string, or array and expecting clean concatenation. The node will "add" the items and you may get something you didn't intend - the description warns about exactly this. If your unbatched output looks scrambled, check what type is actually flowing through; for images, latents, and masks you're fine.
Second, don't confuse this with Meta Batch. If your goal is streaming a huge render in memory-friendly chunks, Unbatch is the wrong tool entirely - that's a separate VHS system.
And the standing pack-level note: if VideoHelperSuite fails to import (missing ffmpeg, a NumPy version clash), every VHS node including this one drops out of the menu. The real error prints in the ComfyUI startup log; reinstall through Manager to fix it.
Inputs (1)
| Name | Type | Default | Description |
|---|---|---|---|
| batched | * | β |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| unbatched | * | β |