YOLOv2 and YOLOv3: Incremental Improvements
What you'll learn: How YOLOv2 and YOLOv3 evolved YOLO's architecture through batch normalization, anchor boxes, and multi-scale feature predictions.
The Evolution Story
The original YOLO was revolutionary but had limitations—especially with small objects and localization accuracy. YOLOv2 and YOLOv3 introduced targeted improvements that made YOLO faster, more accurate, and better at detecting objects of varying sizes.
Key Improvements in YOLOv2
Batch Normalization: Added after every convolutional layer, stabilizing training and eliminating the need for dropout. This alone improved mAP by ~2%.
Anchor Boxes: Instead of directly predicting bounding box coordinates, YOLOv2 predicts offsets from predefined anchor boxes (similar to those you learned about in concept 949). The model learns to adjust these anchors rather than guess coordinates from scratch—think of anchors as "starting templates" for common object shapes.
Multi-Scale Training: The network randomly resizes input images during training (320×320, 416×416, etc.), learning to detect objects at different scales. This makes the detector robust to various input sizes.
YOLOv3's Advanced Features
Feature Pyramid Network (FPN): YOLOv3 makes predictions at three different scales by extracting features from different depths of the network. Small objects are detected using fine-grained features (early layers), while large objects use coarse features (deep layers). It's like having three detectors specialized for different object sizes.
Better Backbone: Uses a deeper feature extractor (Darknet-53) with residual connections, borrowing ideas from ResNet architectures you studied earlier.
More Anchor Boxes: Uses 9 anchors across 3 scales (3 per scale), improving detection of various aspect ratios.
Key Takeaway: YOLOv2 and YOLOv3 refined YOLO through batch normalization for stability, anchor boxes for better localization, and multi-scale feature pyramids for detecting objects of all sizes—making one-stage detection both fast and accurate.