BBOX Detector Combined Batch MXD
Run your Impact Pack detector over a whole batch in one node
- bbox_detector
- images
- mask
Impact Pack's BBOX Detector (combined) node is the standard way to get a mask out of a detection model - you point a YOLO-style bbox detector at an image, set a threshold, and get a mask you can feed into detail passes or inpainting. It has one limitation that annoys anyone doing video or batches: it's built around a single image. BBOX Detector Combined Batch MXD is the loop version - it takes your BBOX_DETECTOR and an entire IMAGE batch, runs detection on every frame, and returns a stacked MASK batch.
What it is and why you'd reach for it
If you're doing frame-by-frame face or subject detection on a video clip, or running detection over a batch of images before a consistent detail pass, you normally have to wire up per-frame handling yourself - Impact Pack's detector isn't batch-friendly in one call. This node wraps the loop: same inputs you already know from the original (detector, threshold, dilation), but images is a whole batch, and it iterates internally with a progress bar.
It's one of those "I had to do this in my own workflows, so I packaged it" nodes - which is exactly how Maxed-Out-99 describes the pack's mission.
How it works
For each frame in the batch it calls the detector's detect_combined(frame, threshold, dilation) method - the same call the Impact Pack node makes - collects the resulting masks, and stacks them into one [B, H, W] mask tensor. Two safety behaviors worth knowing:
- If a detector returns nothing for a frame, it substitutes an all-zeros mask instead of erroring. Empty detection doesn't kill the batch.
- Masks are normalized to float32 on CPU, and the node validates each shape before stacking, so you get a clean error rather than a cryptic
torch.catcrash.
The threshold (0.5) controls how confident the detector must be before something counts as a detection; dilation (default 4) grows the mask so downstream detail passes or inpaints cover a margin around the subject.
Dependencies - this is the important part
The node only accepts a BBOX_DETECTOR, and that type comes from Impact Pack. So you need:
- Impact Pack installed (
ltdrdata/ComfyUI-Impact-Pack- via Manager), to supply a detector model loader (e.g. the UltralyticsDetectorProvider) whoseBBOX_DETECTORoutput feeds this node's input. - A detection model - the usual YOLO/Ultralytics .pt in your
ComfyUI/models/ultralyticsfolder.
The MaxedOut pack itself has no extra dependencies, but this specific node is dead in the water without Impact Pack's type system. You've been warned - most "why won't this connect" reports about it are really "I don't have Impact Pack."
Install
cd ComfyUI/custom_nodes
git clone https://github.com/Maxed-Out-99/ComfyUI-MaxedOut.git
Restart, or use Manager → search "Maxed Out". Then install Impact Pack the same way.
Troubleshooting
- Can't connect anything to
bbox_detector- Impact Pack isn't installed (or its nodes didn't load). Install it and restart. - "Expected IMAGE tensor [B,H,W,C]" - your input isn't a 4D batch. A single image arriving as 3D gets auto-expanded, but anything else will trip the guard.
- All-black masks - threshold too high or a detector model that doesn't match your content. Drop
thresholdtoward 0.3 and check the detector is actually the one you think it is.
For batch detection this is a genuine timesaver - one node where you'd otherwise build a loop graph. Just remember it rides on Impact Pack's shoulders.
Inputs (4)
| Name | Type | Default | Description |
|---|---|---|---|
| bbox_detector | BBOX_DETECTOR | — | |
| images | IMAGE | — | |
| threshold | FLOAT | 0.500–1 | — |
| dilation | INT | 4-512–512 | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| mask | MASK | — |