πŸ€– LateAI
Home β€Ί Tutorials β€Ί Object Detection Mobile Net SSD
πŸš—

Object Detection Mobile Net SSD

Beginner Β· 2-3 hours
πŸ“Ά Beginner ⏱ 2-3 hours πŸ’° Free (software only) 🏷 CV Zone

πŸ“Œ Overview

Do lightweight object detection with the MobileNet SSD model: MobileNet extracts features, SSD handles localisation, and the combined model is small (a few tens of MB) so it runs in real time on an ordinary laptop or even a Raspberry Pi.

OpenCV's DNN module supports the model directly and it recognises the 80 COCO classes - the friendliest way into deep-learning object detection.

🧰 What you need

πŸ”§ Step by step

1

Download the model

Get MobileNetSSD_deploy.caffemodel and the prototxt

It is about 25MB, far smaller than YOLO

2

Load the network

Load the model with readNetFromCaffe

Read in the class labels (person, car, phone, and so on)

3

Pre-process the input

Resize the image to 300x300 and normalise the blob

The OpenCV tutorial uses fixed scaling parameters

4

Infer and parse

net.forward returns the detection output matrix

Each row is one detection: class index, confidence, and normalised box coordinates

5

Filter and draw

Only show detections above a confidence threshold

Scale the normalised coordinates back to the original image size before drawing

6

Compare and apply

Compared with YOLO: faster and lighter, but weaker on small objects

Well suited to embedded and real-time monitoring use cases

πŸ’‘ Tips

View original β†— ← Back to LateAI home