Hunyuan 3 Clear Downstream Models
The cleanup node that keeps your 80B model loaded
- trigger_image
- trigger_latent
- memory_report
The dumbest-sounding node in this pack is also one of the smartest. "Hunyuan 3 Clear Downstream Models" clears every other model out of VRAM - Flux, SAM2, Florence, whatever your workflow chain loaded after the Hunyuan generation - while deliberately keeping the 80B Hunyuan model loaded. It's a targeted version of "free up VRAM," designed for the workflow shape that makes HunyuanImage-3.0 painful: you generate with an 80B model, then hand the image to a Detailer and a segmenter, and suddenly you have four models fighting over one GPU.
Why not just unload Hunyuan? Because reloading 45–160GB of weights from disk takes minutes. Keeping it cached while evicting the small downstream models means the next Hunyuan run is instant, and the downstream models are cheap to reload. The README's phrase for it: "Clears Flux/SAM2/etc but KEEPS Hunyuan."
How to wire it
It's an output node - you don't read anything useful out of it, you place it at the end of the pipeline:
[Hunyuan Loader] → [Generate] → [Flux Detailer] → [SAM2] → [Save] → [Clear Downstream Models]
The two booleans:
- clear_comfy_models (default true) - uses ComfyUI's own model management (
unload_all_models) to evict non-Hunyuan models. This is what does the actual work. - aggressive_gc (default true) - runs aggressive garbage collection afterward to pick up what the unload missed.
The trigger inputs - trigger_image, trigger_string, trigger_latent - exist so you can guarantee ordering: connect an IMAGE output from your final Save node (or a STRING like a filepath) and this node only fires after that node completes. It doesn't consume the data; it just waits for it. The memory_report STRING output tells you what got cleared and how much VRAM was freed.
This is the cleaner alternative to the pack's Force Unload (Nuclear) node: that one clears everything including Hunyuan, and it's for emergency OOM situations. This one is for normal multi-model workflow hygiene. (If you prefer the nuclear option, the standard Unload node with clear_for_downstream also exists.)
Installing
cd ComfyUI/custom_nodes
git clone https://github.com/EricRollei/Comfy_HunyuanImage3
cd Comfy_HunyuanImage3
pip install -r requirements.txt
Restart ComfyUI, or install through ComfyUI Manager (search "Comfy_HunyuanImage3"). No model download - this node manages memory, not weights.
One caveat
It can only clear models ComfyUI knows about. Models loaded by other custom-node packs that don't register with ComfyUI's model management will evade it - which is exactly the cross-tab VRAM pollution problem the pack's Force Unload was built for. If you've got orphaned VRAM that won't go away, that's a different tool's job. And while the aggressive_gc flag is a good default, don't be surprised if your system RAM doesn't fully drop after heavy multi-model runs; the author's own known-issues list mentions RAM can creep upward across successive loads, with a restart as the reliable reset.
Inputs (5)
| Name | Type | Default | Description |
|---|---|---|---|
| clear_comfy_models | BOOLEAN | true | Use ComfyUI's model management to unload non-Hunyuan models |
| aggressive_gc | BOOLEAN | true | Run aggressive garbage collection |
| trigger_imageopt | IMAGE | Connect an IMAGE output to trigger after that node completes | |
| trigger_stringopt | STRING | Connect a STRING output (like filepath) to trigger after that node | |
| trigger_latentopt | LATENT | Connect a LATENT output to trigger after that node completes |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| memory_report | STRING | — |