VLM Performance Profile
Five sane speed/quality presets instead of five hidden flags
- max_frames
- max_megapixels
- max_edge
- batch_size
- unload_after
- profile_json
Every VLM workflow eventually asks the same five questions: how many frames, how many megapixels, what's the max edge, what batch size, and should the model unload after running? Answering them by hand every time is how you end up with a 4K, 300-frame prompt on a 6GB card. VLM Performance Profile answers all five at once with a named starting point - one widget, five coherent numbers out.
It's the coordinator of the pack's performance layer, and the README is pointed about its design: these are explicit starting points, not hidden global flags. The node never changes global runtime state - it just emits values that you wire into the sampler, the pixel budget, and the VLM's batch/unload inputs.
The profiles
Pick one, and you get a coherent bundle:
- Live / robotics - 24 frames, 0.5 MP, 896 max edge, batch 8, keep loaded. Built for latency-first loops.
- Fast video - 48 frames, 0.75 MP, 1024 edge, batch 8.
- Balanced - 64 frames, 1.0 MP, 1344 edge, batch 4. The default.
- High detail - 96 frames, 2.0 MP, 2048 edge, batch 2. For when you're willing to pay.
- Low VRAM handoff - 32 frames, 0.75 MP, 1024 edge, batch 1, and
unload_after=trueso the model frees the card for whatever comes next.
Inputs and outputs
The only input is the profile dropdown. Outputs, in order: max_frames (INT), max_megapixels (FLOAT), max_edge (INT), batch_size (INT), unload_after (BOOLEAN), and profile_json (STRING) - the whole bundle serialized, for logging or for nodes that take JSON instead of individual wires.
The intended wiring: max_frames → VLMAdaptiveFrameSampler, max_megapixels/max_edge → VLMImagePixelBudget, batch_size/unload_after → the VLM or detection node's batch/unload inputs. One dropdown drives the whole chain coherently instead of five widgets drifting apart.
Installing this pack
Same install as every node in this pack. ComfyUI Manager: search VLM_nodes. Or:
cd ComfyUI/custom_nodes
git clone https://github.com/gokayfem/ComfyUI_VLM_nodes
cd ComfyUI_VLM_nodes
python -m pip install -r requirements.txt
Run pip with ComfyUI's Python. This node downloads nothing and touches no models.
Common issues
The temptation is to treat the presets as gospel. They're starting points - "Balanced" on a 3090 vs. a 4060 Laptop with 6GB are different worlds, and the numbers won't know which you have. Treat them as a sane baseline, then tune: raise max_megapixels when the model is missing fine detail (it's the single biggest token-cost lever), and reach for Low VRAM handoff the moment you hit OOM between models. And don't forget the outputs are values, not magic - if nothing downstream reads them, the profile changes nothing.
Inputs (1)
| Name | Type | Default | Description |
|---|---|---|---|
| profile | COMBO | Balanced | 5 options: Live / robotics, Fast video, Balanced, High detail, Low VRAM handoff |
Outputs (6)
| Name | Type | Description |
|---|---|---|
| max_frames | INT | — |
| max_megapixels | FLOAT | — |
| max_edge | INT | — |
| batch_size | INT | — |
| unload_after | BOOLEAN | — |
| profile_json | STRING | — |