What happens after the network?
Introduction
Project introduction
What happens after the network?
An object detector finds every object in an image and draws a box around each one, with a class and a confidence. You might expect the network to output that list directly. Most detectors do not. They output a fixed grid of guesses, and ordinary code turns the guesses into the final list.
The guesses start from anchors, which are fixed boxes of a few sizes and shapes placed all over the image. For every anchor the network predicts four numbers that move and resize it, and one confidence per class. A small image can have hundreds of anchors; a real one has tens of thousands.
Why the back half matters
Everything after the network is plain code that converts box formats, measures overlap, decodes anchors into boxes, chooses which anchors learn which object, removes duplicate boxes, and scores the result. None of it is learned, so none of it can learn to cover for a mistake.
Those mistakes rarely crash. A box in the wrong format still looks like four reasonable numbers. A decoder that starts from the wrong point still draws boxes near the objects. The only sign is a worse number, so you will learn to read the numbers.
From raw outputs to a score
64 × 64 sceneWhat you will build
01
From offsets to boxes
IoU in any format, decoding anchors, and choosing training targets.
02
One box per object
Class-aware NMS, and what its threshold trades off in a crowd.
03
An honest score
Average precision and mAP, computed the way COCO does.
Start with overlap
Compute IoU between two sets of boxes in any of three formats.