📚 Course contents

AI & Computer Vision, lesson 25 of 52

Real-Time Detection: Making It Fast on a Laptop

intermediate26 min readFull course

Introduction

A detector that takes half a second per frame isn't much use at a live match. Today you'll build the live pipeline, time every stage of it, find the slow one, and speed it up four different ways, keeping an honest record of what each trick gains and what it costs.

By the end of this lesson you'll be able to:

  • Build the four-stage live pipeline: capture, detect, annotate, display
  • Measure frames per second (FPS) and the time each stage takes
  • Find the bottleneck and fix that stage first
  • Apply four speed-ups: a smaller model, a smaller image, frame skipping and an optimised export (ONNX or OpenVINO)
  • Read a camera in a background thread so the detector always sees the newest frame
  • Report honestly what each change gained, and what it cost in accuracy
Real-Time Detection: Making It Fast on a Laptop