Nodes/comfyui_imgutils/Mask to BBox
ComfyUI Node

Mask to BBox

Calculates the bounding box(es) of a mask. Can combine all regions or separate them with NMS.

By LK-168·Created about a year ago·Updated about a year ago· 1
Mask to BBox
  • mask
  • BBOX
threshold0.50
combinefalse
nms_threshold0.50
Categoryimgutils/bbox

Inputs (4)

NameTypeDefaultDescription
maskMASK
thresholdFLOAT0.500–1Threshold to binarize the mask before finding bbox
combineBOOLEANfalseIf True, combine all mask regions into one bbox. If False, output separate bboxes for each connected component.
nms_thresholdFLOAT0.500–1IoU threshold for Non-Maximum Suppression. Higher values merge more overlapping boxes.

Outputs (1)

NameTypeDescription
BBOXBBOX