Bubba Detailer
Bubba Detailer
- pipe
- image
- metadata
- model
- clip
- vae
- positive
- negative
- pipe
- image
- mask
- metadata
- info
Every detailer is the same four-step loop wearing a different hat: detect a region with a model, crop and upscale it, re-render it with an inpainting pass, paste it back. Bubba Detailer is that loop in one node, built on Ultralytics detectors, and the thing that makes it a Bubba node is that it can pull the whole model stack - checkpoint, VAE, conditioning - out of the pipe and write the refined image back into it.
The core use case is the eternal one: a 1024px image where the face occupies maybe 70 pixels. No checkpoint on earth spends enough latent budget on a face that small to make it sharp, so you give that region its own pass. That's what this node automates - one node, no mask painting, and it scales to a batch of images or a video's worth of frames without you touching anything.
The detector and what it needs
detector_model_name lists YOLO models from your models/ultralytics/bbox and models/ultralytics/segm folders. The standard community weights - face_yolov8n/face_yolov8s, hand_yolov8n, person_yolov8n-seg - go in there, the same files the A1111 detailing ecosystem standardized on. If you see a seam where the patch meets the image, that's the classic bbox-rectangle tell; a segmentation detector (the -seg weights) follows the face outline instead and the seam mostly disappears. include_labels / exclude_labels filter which detected classes get processed, so you can say "only faces, not hands."
Everything after detection is ordinary inpainting: mask_dilation expands the mask, mask_blur feathers it, inpaint_padding gives the re-render context, and guide_size/max_size/force_square_crop control the crop resolution. denoise is the dial that decides how much of the region gets re-rolled - for fixing an already-decent face, 0.3–0.4 is the sweet spot from the detailing playbook; crank it higher and you're regenerating the region, not fixing it.
The sampler settings (seed, steps, cfg, sampler_name, scheduler) apply to the refinement pass, with their own detail_positive/detail_negative prompt strings - because the region usually wants a different prompt than the whole image ("detailed face, sharp eyes" beats the full scene prompt for a face patch). max_detections caps how many regions get processed, which is your clone-control: process a crowd and every face re-renders from a related seed, and crowds have a nasty habit of converging into a room full of the same person. If you're detailing a group, that's the input to watch.
The pipe deal
Feed it a pipe and it resolves image, model, clip, VAE, and conditioning from there - explicit image, model, clip, vae, positive, negative inputs override the pipe when connected. Outputs are the refined image, the mask (useful for inspecting what got re-rendered), an updated pipe + metadata, and an info string.
Install - there's a real dependency here
Bubba Nodes via ComfyUI Manager or:
cd ComfyUI/custom_nodes
git clone https://github.com/bubbafett5611/Bubba_Nodes
Restart, and you're not done: this is the one node in the pack that needs an extra dependency. ultralytics is optional in the pack (it's not in the base requirements), so if the node reports it missing:
python -m pip install "ultralytics>=8.0,<9"
into the same Python environment that runs ComfyUI, then restart. And you need detector weights - drop the .pt files into models/ultralytics/bbox or models/ultralytics/segm, or nothing appears in the dropdown. Two honest warnings from the ecosystem knowledge base: Ultralytics is AGPL-3.0 licensed (fine for personal use, a licensing consideration if you're selling), and the December 2024 poisoned Ultralytics release is the reason you should install it from PyPI and keep it updated rather than grabbing random wheels.
The rule of thumb
Automatic detailing fixes the small broken parts of an otherwise-good generation - it is not a quality dial to leave on. If the face is already large and sharp, a second pass changes it without improving it, and you've paid render time for nothing. Run it at native resolution before upscaling, use a segmentation detector if seams show, lower the denoise, and turn it off for anything already clean.
Inputs (29)
| Name | Type | Default | Description |
|---|---|---|---|
| detector_model_name | COMBO | 1 options: No ultralytics models found | |
| confidence | FLOAT | 0.300.01–1 | — |
| mask_dilation | INT | 4-64–128 | — |
| mask_blur | INT | 40–64 | — |
| inpaint_padding | INT | 320–256 | — |
| force_square_crop | BOOLEAN | false | — |
| guide_size | INT | 51264–4096 | — |
| guide_size_for | BOOLEAN | true | — |
| max_size | INT | 102464–4096 | — |
| seed | INT | 00–18446744073709550000 | — |
| steps | INT | 201–10000 | — |
| cfg | FLOAT | 7.00–100 | — |
| sampler_name | COMBO | 44 options: euler, euler_cfg_pp, euler_ancestral, euler_ancestral_cfg_pp, heun, heunpp2, +38 | |
| scheduler | COMBO | 9 options: simple, sgm_uniform, karras, exponential, ddim_uniform, beta, +3 | |
| denoise | FLOAT | 0.450–1 | — |
| max_detections | INT | 51–50 | — |
| pipeopt | BUBBA_PIPE | — | |
| imageopt | IMAGE | — | |
| metadataopt | BUBBA_METADATA | — | |
| modelopt | MODEL | — | |
| clipopt | CLIP | — | |
| vaeopt | VAE | — | |
| positiveopt | CONDITIONING | — | |
| negativeopt | CONDITIONING | — | |
| detail_positiveopt | STRING | — | |
| detail_negativeopt | STRING | — | |
| include_labelsopt | STRING | — | |
| exclude_labelsopt | STRING | — | |
| inpaint_modelopt | BOOLEAN | false | — |
Outputs (5)
| Name | Type | Description |
|---|---|---|
| pipe | BUBBA_PIPE | — |
| image | IMAGE | — |
| mask | MASK | — |
| metadata | BUBBA_METADATA | — |
| info | STRING | — |