MiniMax H3 Safe VAE Decode (Video)
A VAE decode that shrugs when there's no video yet — built for first-clip mode
- vae
- samples
- IMAGE
Here's the workflow bug this node exists to prevent. In this pack's Auto chaining mode, the first clip has no previous context - the Clip Bin Picker returns a None latent and a placeholder card as its "initial generation" signal. If that None ever reaches a stock VAEDecode, ComfyUI throws a TypeError and the whole run dies before you've generated a single frame. MiniMaxSafeVAEDecode ("MiniMax H3 Safe VAE Decode (Video)") is the fuse in that circuit: when there's nothing to decode, it returns an empty image batch instead of crashing.
Don't overthink when to use it. It's a drop-in replacement for your video decode slot in a chaining workflow - it handles both halves of the problem with one node. When it receives a real joint AV latent, it unpacks the video stream from the H3 NestedTensor and calls the standard vae.decode() - full fidelity, identical quality to a normal decode. When the samples are None (first clip, empty bin) it logs a friendly note and returns an empty IMAGE tensor, which downstream saver/preview nodes tolerate rather than crash on.
Inputs and output
Minimal surface, which is the point:
vae(required) - your MiniMax H3 VAE loader.samples(optional) - the joint AV latent from the sampler (or wherever your decode source is). When absent or empty, it returns the empty batch; when present, it decodes the video stream inside.
Output: a single IMAGE. Standard RGB frames when decoding, an empty (0, H, W, 3) tensor when there's nothing - and if an actual decode throws, it catches the exception, logs a warning, and returns empty rather than killing the graph. That last bit is worth knowing: a silent empty batch on a real decode failure can hide problems, so watch the console when output unexpectedly comes up blank.
Where it fits
The pack ships this under MiniMaxH3/ClipBin because it sits naturally between the Picker (which can hand you None in initial mode) and anything that consumes frames. Note the pack's own reference workflow actually uses ComfyUI's core VAEDecode/VAEDecodeAudio for the main chain and reserves the safe variants for the branchy cases - but if you're wiring a graph that must survive "no prior clip yet," or you're building your own Auto loop, swapping in the safe decode is cheap insurance and it costs nothing on the normal path since the decode is identical.
One honest limitation: "empty image" is only safe if your downstream nodes accept an empty batch. The pack's own Saver handles it gracefully, but a VHS_VideoCombine that demands a non-empty frame list isn't magically saved by this node - the empty result is designed to keep simple preview/archive chains alive during initial generation, not to satisfy every consumer.
Install
Same pack, same ritual - Manager (search "MiniMaxH3 PrefixStream") or:
cd ComfyUI/custom_nodes
git clone https://github.com/knoic/ComfyUI-MiniMaxH3-PrefixStream.git
cd ComfyUI-MiniMaxH3-PrefixStream
pip install -r requirements.txt
Restart ComfyUI, Ctrl+F5. No model downloads, no API keys, no extra heavyweight dependencies - it's a thin wrapper around your VAE.
Inputs (2)
| Name | Type | Default | Description |
|---|---|---|---|
| vae | VAE | — | |
| samplesopt | LATENT | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| IMAGE | IMAGE | — |