BboxToCropData
BboxToCropData – ComfyUI Node
- bbox
- crop_data
What it is
BboxToCropData is a translator, not a tool. It doesn't detect anything, crop anything, or change a single pixel - it takes a bounding box and rewrites it into a different bounding box format so a downstream node stops complaining. Specifically, it converts the (x, y, w, h) shape that a lot of detection nodes emit into the ((w, h), (x, y, x+w, y+h)) shape that WAS Node Suite's crop nodes expect. If you've ever wired a face or object detector into a WAS crop node and gotten a cryptic shape mismatch or a garbage crop, this is almost certainly the node you were missing.
This is the unglamorous plumbing side of the detect-crop-refine pattern that shows up everywhere in ComfyUI - Impact Pack's FaceDetailer, InstantID's face boxes, any custom detector - all built on the same idea: find a region, crop it tight, do a focused pass, paste it back. The catch nobody warns you about is that "bbox" isn't one format. Some packs store corners, some store a corner plus width/height, and WAS Node Suite in particular wants its own tuple-of-tuples crop_data structure. BboxToCropData exists purely to bridge that gap.
Inputs and outputs
You give it one thing that matters: bbox (type BBOX, required), the box coming out of whatever detector or bbox node you're using upstream. There's also is_xywh (boolean, default false), which tells the node how to interpret the box you handed it - true means your bbox is (x, y, w, h), false means it's already corner-pair (x, y, x1, y1). Get this flag backwards and your crop will be silently wrong (wrong size, wrong offset) rather than throwing an error, so it's worth double-checking against whatever produced the bbox in the first place.
The single output is crop_data, typed as * (any) so it can slot straight into a WAS Node Suite crop node's crop_data input without ComfyUI's type checker getting in the way.
Installing it
This node ships inside the comfyui-easyapi-nodes pack, not on its own. Easiest path: open ComfyUI Manager, search for "comfyui-easyapi-nodes" (or "EasyApi"), and install. Manual route if you'd rather:
cd ComfyUI/custom_nodes
git clone https://github.com/lldacing/comfyui-easyapi-nodes.git
cd comfyui-easyapi-nodes
pip install -r requirements.txt
Restart ComfyUI afterward. The pip install -r requirements.txt step matters here - skip it and other nodes in the pack (the InsightFace and SAM-adjacent ones especially) will fail to import even though this particular node itself has no exotic dependencies. To upgrade later, it's just git pull inside the same folder.
You'll also need WAS Node Suite installed if you actually want somewhere to plug crop_data into - BboxToCropData is a bridge, and a bridge needs both banks.
Common issues
"It says my crop is the wrong size or offset." Check is_xywh first. This is the single most likely thing to be wrong, because the node trusts you completely about which format you're feeding it - there's no auto-detection.
"WAS crop node still rejects the input." Confirm WAS Node Suite is actually installed and up to date; its crop nodes expect this exact crop_data shape, and if you're on an old version the internal format may have drifted. Also double check you're feeding crop_data into a WAS crop node specifically, not a generic image-crop node from another pack - the whole point of this node is to match WAS's particular convention, and other packs won't recognize the shape.
"Where do I even get a BBOX to feed this?" Anything that emits BBOX works - Impact Pack's detector nodes, this same pack's own InsightFaceBBOXDetect (its bbox output is a JSON string though, not the typed BBOX this node wants, so you'd need a conversion step in between), or any custom detection node. If your source only gives you raw coordinates as numbers, you'll need to assemble them into a proper BBOX first.
Because this node has zero independent identity outside the pack - it's pure glue - there isn't much of a community footprint to draw on for it specifically. If you hit an edge case, the pack's GitHub issues are the more useful place to look than general searches.
Inputs (2)
| Name | Type | Default | Description |
|---|---|---|---|
| bbox | BBOX | — | |
| is_xywhopt | BOOLEAN | false | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| crop_data | * | — |