Skip to content

A-matindoust/Object-Tracking-with-ByteTrack-BoT-SORT-YOLO

Repository files navigation

Object Tracking with SORT, DeepSORT, ByteTrack, BoT-SORT & YOLO

Overview

This repository demonstrates the fundamentals of Multi-Object Tracking (MOT) using a football video dataset. It explains how modern tracking algorithms maintain the identity of objects across video frames and compares some of the most widely used tracking methods.

The project includes multiple experiments using different detection and tracking combinations to highlight their strengths and limitations.


What is Object Tracking?

A video is simply a sequence of images shown one after another. Each image is called a frame.

The speed of a video is measured in FPS (Frames Per Second), which indicates how many frames are displayed every second.

The goal of object tracking is to detect objects in every frame and keep the same identity for each object throughout the video.


Object Tracking Pipeline

A typical tracking pipeline consists of three main steps:

1. Object Detection

The detector identifies all objects in each frame and provides:

  • Object class (label)
  • Bounding box (BBox)
  • Confidence score

2. Data Association

The tracker determines whether an object detected in the current frame corresponds to an object detected in previous frames.

To make this decision, tracking algorithms use:

  • Motion (location) information
  • Visual (appearance) features

3. ID Assignment

Each detected object receives a unique ID.

The objective is to preserve this ID across all frames as long as the object remains in the scene.


Common Tracking Challenges

ID Switching

Sometimes an object temporarily disappears due to:

  • Occlusion
  • Low detector confidence
  • Motion blur

When it appears again, the tracker may assign a new ID instead of the original one.

This problem is known as ID Switching.


Re-Identification (Re-ID)

If an object disappears for several frames and later reappears, an effective tracker should recognize that it is the same object and assign its original ID.

This process is called Re-Identification (Re-ID).


Tracking Algorithms

SORT (Simple Online and Realtime Tracking)

SORT is one of the earliest and fastest tracking algorithms.

It works by:

  • Predicting the next object location using a Kalman Filter
  • Matching predicted boxes with detected boxes using IoU

Advantages

  • Very fast
  • Simple implementation
  • Real-time performance

Limitations

SORT only uses motion and location information.

It does not use appearance features, so when two nearby objects cross each other, ID switches can easily occur.


DeepSORT

DeepSORT improves SORT by adding a deep neural network that extracts appearance features from every object.

Each object is represented by a feature vector that helps distinguish it from other objects.

DeepSORT combines:

  • Motion information
  • Appearance (visual) features

Another improvement is the Tentative State.

Instead of assigning a permanent ID immediately, a new object is observed for several frames before its track is confirmed, reducing false tracks.

Advantages

  • Better identity preservation
  • Lower ID switching
  • Supports Re-Identification

Limitations

  • Slower than SORT
  • Higher computational cost

ByteTrack

ByteTrack extends SORT by making use of both high-confidence and low-confidence detections.

Instead of discarding low-confidence detections, ByteTrack keeps them and performs a second association step.

  • High-confidence detections → standard SORT association
  • Low-confidence detections → IoU-based association

This significantly reduces the number of lost tracks.

Example

If a football player is temporarily hidden behind another player or the referee, the detector may produce a low-confidence detection.

SORT may discard it, causing the player to receive a new ID later.

ByteTrack keeps these low-confidence detections, allowing the tracker to maintain the same identity.

Advantages

  • Faster than DeepSORT
  • More accurate than SORT
  • Better handling of temporary occlusions

BoT-SORT

BoT-SORT combines the strengths of ByteTrack and DeepSORT.

It uses:

  • Motion information
  • Appearance features
  • High- and low-confidence association

For:

  • High-confidence detections → appearance and motion features are used.

For:

  • Low-confidence detections → association mainly relies on motion information.

This provides both high speed and strong identity preservation.

Advantages

  • High accuracy
  • Better Re-ID performance
  • Reduced ID switching
  • Suitable for crowded scenes

Which Tracker Should You Use?

Scenario Recommended Tracker
Simple scenes with few objects ByteTrack
Crowded scenes with many objects BoT-SORT
Maximum speed SORT
Best identity preservation DeepSORT / BoT-SORT

Project Structure

├── SSD300 + BoT-SORT
├── SSD300 + ByteTrack
├── YOLO Tracking
└── README.md

Dataset

The experiments are performed on a football video dataset containing multiple moving players. https://www.kaggle.com/datasets/iasadpanwhar/football-player-detection-yolov8

Repository Contents

This repository includes four implementations:

  1. SSD300 object detection with BoT-SORT
  2. SSD300 object detection with ByteTrack
  3. YOLO-based object tracking
  4. Comparison of different tracking approaches

Key Concepts Covered

  • Object Detection
  • Bounding Boxes
  • Kalman Filter
  • IoU Matching
  • Data Association
  • Object Tracking
  • Multi-Object Tracking (MOT)
  • Appearance Features
  • Re-Identification (Re-ID)
  • ID Switching
  • SORT
  • DeepSORT
  • ByteTrack
  • BoT-SORT

References

  • SORT
  • DeepSORT
  • ByteTrack
  • BoT-SORT
  • YOLO

About

A practical comparison of modern multi-object tracking algorithms (ByteTrack, and BoT-SORT) on football videos using SSD300 and YOLO object detectors.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors