XB-BOX - VAE解码(原版优化)
The plainest node in the pack, and that's the point
- samples
- vae
- IMAGE
Some nodes in XB_ToolBox are doing physics-level memory surgery. This one is just ComfyUI's stock VAEDecode with a cleanup dropdown stapled to the front. That's not a criticism - after a pack that keeps renaming things and bolting on "ROCm" labels, a node that is exactly what its name says is a relief. XB_VAEDecode takes a latent, decodes it through your VAE, and hands you pixels. Nothing tiled, nothing temporal, nothing clever.
The only difference from the built-in node: the cleanup option runs before decoding, giving you the pack's four-level memory ladder - no cleanup, purge the cache, unload models to system RAM, or unload everything plus a full gc.collect().
The three inputs, and that's it
- samples - the LATENT coming out of your sampler.
- vae - your VAE. If the pack has a "VAE 解码" node in a workflow you downloaded, this is it.
- cleanup - leave it on "no cleanup" until a run OOMs; that's the whole decision tree.
Output is a single IMAGE (the batch of decoded frames), which goes to a Preview Image, Save Image, or video combine node.
When to use this vs. the tiled one
This is the important judgment call, because the pack ships a whole family of decoders and the differences matter:
XB_VAEDecode- plain decode, no tiling. Fast, simple, and the thing that OOMs on big latents. Use it when your latent is modest (still images, short clips) or your VRAM is comfortable.XB_VAEDecodeTiled- the same decode chopped into overlapping spatial chunks (plus temporal chunks for video VAEs). Use it when the plain decode can't fit. Slightly more stitching overhead, occasionally faint seams if overlap is set wrong.
The mental model from the KB's troubleshooting spine: the VAE is usually a small model, but it wants the whole latent resident at once, and on consumer cards that's often the actual bottleneck at the end of a long generation. If a run "samples fine but dies at the end," decode memory is a top suspect - and swapping this node for the tiled variant is the first fix to try, before you touch cleanup levels or start uninstalling things.
The honest take
Do you need it? No - ComfyUI ships the identical VAEDecode. But if you've already got XB_ToolBox installed (for its Wan pipeline nodes or the VRAM hacks), this node costs you nothing, and the cleanup dropdown is a legitimately convenient way to force ComfyUI to free memory before a decode without writing boot flags. It's also the compatibility-friendly choice in old workflows that expect XB_ToolBox's parameter conventions.
Install is pack-standard: ComfyUI Manager → search XB_ToolBox → install → restart, or:
cd ComfyUI/custom_nodes
git clone https://github.com/wjluoxiao/XB_ToolBox.git
No extra pip dependencies for this node - it wraps ComfyUI core, nothing else.
Inputs (3)
| Name | Type | Default | Description |
|---|---|---|---|
| samples | LATENT | The latent to be decoded. | |
| vae | VAE | The VAE model used for decoding the latent. | |
| cleanup | COMBO | 不做任何清理 | 4 options: 不做任何清理, 单次缓存清理, 卸载显存模型, 卸载全量模型 |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| IMAGE | IMAGE | — |