Object Detection — YOLO & Faster R-CNN
What is Object Detection?
Object detection simultaneously answers two questions: 1. What objects are in the image? (classification) 2. Where are they? (bounding box regression) Output: a set of (class, confidence, x, y, width, height) tuples. Two major paradigms: • Two-stage (Faster R-CNN): propose regions → classify. High accuracy, slower. • One-stage (YOLO, SSD): predict directly from full image. Faster, slightly less accurate.
YOLO — You Only Look Once
YOLO divides the image into an S×S grid. Each cell predicts B bounding boxes with confidence scores and C class probabilities. YOLO versions: YOLOv5 — PyTorch, easy to use, great community. YOLOv8 — Ultralytics, state-of-the-art, supports detection/segmentation/pose/classification. YOLO-NAS — Neural Architecture Search optimized YOLO, best accuracy/speed tradeoff. RT-DETR — Transformer-based detector, no NMS needed.
Faster R-CNN
Three components: 1. Backbone CNN (ResNet) — extracts feature maps 2. Region Proposal Network (RPN) — proposes candidate object regions 3. ROI Pooling + Classifier Head — classifies and refines each proposal Faster R-CNN is used when accuracy is critical (medical imaging, autonomous driving) and speed is secondary.
YOLOv8 Training & Inference
Complete YOLOv8 workflow from pretrained inference to custom dataset training.
mAP50-95 is the standard COCO metric — mean Average Precision at IoU thresholds from 0.50 to 0.95 in 0.05 steps.
Finished reading? Mark it complete to earn your XP.