Menu

Why object detectors miss small objects in big photos, and how tiling fixes it
📰

Why object detectors miss small objects in big photos, and how tiling fixes it

DEV Community: computervision·Nookforge Studio·14 days ago
#Wz9xFnfo
Reading 0:00
15s threshold

Point an off-the-shelf object detector at a drone photo of a marina and it will tell you there are five boats. There are dozens. The model isn't bad; the pipeline throws the boats away before the model ever sees them.

The resize problem

Most real-time detectors, YOLO and its relatives included, are trained and run at around 640×640 pixels. A 3613×2400 aerial photo gets shrunk by a factor of about 5.6 to fit. A boat that was 30 pixels long becomes about 5 pixels long, which is below what the network can reliably pick out. The same thing happens to background people in crowd shots and to cars in parking lot photos.

Sliced inference

The fix is to stop shrinking the image and look at it in pieces instead:

Cut the image into overlapping tiles at full resolution, 640 px with about 20% overlap.

Run the detector on every tile, plus one pass on the whole downscaled image so large objects that span tiles are still found.

Shift each tile's boxes back into full-image coordinates.

Merge duplicates.…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.