LocateAnything Unload Model
The LocateAnything Unload node
- model
- status
This is the least glamorous node in the pack and possibly the one that saves you a headache: LocateAnything Unload Model drops the loaded LocateAnything model and clears the CUDA cache. It exists because LocateAnything-3B is a 3-billion-parameter vision-language model, and once your Grounding node is done with it, that thing is just sitting in VRAM doing nothing while your sampler runs.
ComfyUI is good at unloading diffusion models it loaded itself, but this model lives inside the pack's own runtime - the loader hands the Grounding node a LOCATEANYTHING_MODEL object, and nothing in core ComfyUI knows or cares how to release it. This node is the explicit "I'm done" signal. Behind the scenes it nulls out the model, tokenizer, processor and batch-runtime references, runs a garbage collection pass, and calls torch.cuda.empty_cache(). What comes out the other end is a status string ("LocateAnything model unloaded") you can route to a Show Text node if you like confirmation.
Where it fits
Use it as the end of the LocateAnything arm of your graph:
LocateAnything Model Loader
-> LocateAnything Grounding
-> LocateAnything Unload Model
Wire the model from the loader through Grounding, then run it into Unload. If the whole thing is a single workflow run, the node fires after Grounding finishes - which is exactly when you want the VRAM back, before the KSampler starts chewing on the same card.
When you actually need it
Honestly? For a single quick test run, you don't. Close the workflow and the runtime goes with it. You'll feel it in the cases that matter:
- Tight VRAM - LocateAnything + a big diffusion model on the same card. Unloading frees room for the sampler.
- Batch/API workflows - the kind that run repeatedly or via the API. Memory leaks compound; this keeps them from stacking up.
- Sitting in a workflow after testing - you loaded LocateAnything to make a mask, and you don't want 3B of VL model parked next to your sampler for the rest of the session.
One honest quirk: because it's an output node and the model wire is required, you can't just bolt it on the side of an existing workflow - you have to route the model through it. That's a small edit to your graph, and it's the correct behavior anyway: it forces you to think about where the release happens.
Install
Same pack as the rest - no extra work. Search ComfyUI-LocateAnything in ComfyUI Manager, or:
cd ComfyUI/custom_nodes
git clone https://github.com/alisson-anjos/ComfyUI-LocateAnything.git
cd ComfyUI-LocateAnything
pip install -r requirements.txt
Restart, and it's under the LocateAnything category alongside the loader and the Grounding node.
The model itself is NVIDIA-licensed for non-commercial use, worth remembering if you deploy this anywhere. The unload node is just housekeeping - but housekeeping that keeps a 3B model from squatting on your VRAM all afternoon.
Inputs (1)
| Name | Type | Default | Description |
|---|---|---|---|
| model | LOCATEANYTHING_MODEL | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| status | STRING | Confirmation that model references and the CUDA cache were released. |