Bounding box prediction estimates an object’s rectangle inside an image. In a YOLO-style detector, each grid location emits four box values plus one confidence value, alongside class probabilities. section 12.2.2
A 6 × 6 prediction grid
Resize an image to 448 × 448, run it through a ResNet backbone, and reshape the prediction head into a 6 × 6 grid. Each cell produces five box-related values and 91 class scores. The box values are split from the class predictions; the class scores receive softmax activation. Because the dense head uses the entire feature map, a detector can use whole-image context even when an object extends across multiple cells. section 12.2.2
Use these rules when training the box output:
- Compare predicted and target box parameters with squared error, computing placement error only for cells containing labeled objects. section 12.2.4
- Set confidence targets to zero for empty cells; for occupied cells, use Intersection over Union (IoU) between predicted and target boxes. section 12.2.4
- Scale placement error up, reduce empty-cell confidence error, and compare square-root-transformed width and height to prevent large boxes dominating training. section 12.2.4
