Sub topic 14
Benchmarks and Datasets for Multi-Object Tracking
This chapter assumes you know the tracking-by-detection pipeline, IoU matching, and the meaning of ID switches, MOTA, IDF1, and HOTA from earlier chapters. It covers the datasets trackers are measured on, the file formats they use, and the ways a benchmark number can mislead you.
Why benchmarks matter more in tracking than in detection
Detection has one clear unit of evaluation: a box in one image. Tracking quality depends on the detector, the association logic, the video, and the annotation rules together. Two papers can report different scores because they used different detectors, not because one tracker is better.
A benchmark fixes as many of these variables as it can. It provides:
- Videos with ground-truth boxes and identities.
- A fixed train and test split.
- A result file format.
- An evaluation protocol with a defined metric implementation.
MOTChallenge
MOTChallenge is the most widely used family of benchmarks for pedestrian tracking. Its datasets include MOT15, MOT16, MOT17, and MOT20.
- MOT16 and MOT17 use the same set of street and mall scenes. Some are filmed with a static camera and some with a moving camera. MOT17 provides each sequence with three sets of public detections, from the DPM, Faster R-CNN, and SDP detectors.
- MOT20 targets very crowded scenes, such as stations and squares. Dozens of people overlap in a frame, so occlusion and missed detections dominate.
Ground truth for the training sequences is public. Ground truth for the test sequences is hidden. You upload your result files to the benchmark server, which scores them. This stops you from tuning directly on the test labels, although repeated submissions still leak some information.
Public and private detections
MOTChallenge has two tracks, and you must keep them apart when comparing results.
- Public detections: You use the detections the benchmark supplies in
det/det.txt. Only your tracking logic differs from other entries, so the comparison is fair. - Private detections: You bring your own detector, possibly trained on extra data. The score then mixes detector quality with tracker quality.
The file format
MOTChallenge files are plain text with one row per box and comma-separated fields. Frame numbers start at 1.
Ground truth rows (gt/gt.txt) have these fields:
frame: the frame number, starting at 1.id: the identity of the object.x, y, w, h: the box's top-left corner, width, and height, in pixels.conf: a flag. A value of 0 means the row is ignored in evaluation.class: the object class. Pedestrians are evaluated, and other classes such as distractors or static persons are used to avoid penalizing matches to them.visibility: the fraction of the object that is visible.
Detection rows (det/det.txt) use -1 for the id, and the confidence field holds the detector score.
Your result file has one row per tracked box: frame, id, bb_left, bb_top, bb_width, bb_height, conf, -1, -1, -1. The last three fields are 3D coordinates, which 2D tracking leaves as -1.
Note that the format stores width and height, while many trackers work with [x1, y1, x2, y2] corners, as the IoU code in earlier chapters does. Converting between them is a common source of bugs. A box written as corners but read as width and height still looks like a valid box, but it is far too large, and your score drops without any error message.
The script below reads a MOT-format file, writes tracker output in the same format, and checks for the mistakes that most often break a submission.
import csv
import io
from collections import defaultdict
def read_mot(text):
"""Parse MOT-format text into {frame: [(id, x, y, w, h, conf), ...]}."""
frames = defaultdict(list)
for rec in csv.reader(io.StringIO(text)):
if not rec:
continue
frame, tid = int(rec[0]), int(rec[1])
x, y, w, h = (float(v) for v in rec[2:6])
conf = float(rec[6])
frames[frame].append((tid, x, y, w, h, conf))
return frames
def corners_to_row(frame, tid, box, conf=1.0):
"""Turn [x1, y1, x2, y2] into a MOT result row."""
x1, y1, x2, y2 = box
return f"{frame},{tid},{x1:.2f},{y1:.2f},{x2 - x1:.2f},{y2 - y1:.2f},{conf:.2f},-1,-1,-1"
def check(frames):
"""Return a list of problems that commonly break a submission."""
problems = []
for frame in sorted(frames):
if frame < 1:
problems.append(f"frame {frame}: frame numbers start at 1")
seen = set()
for tid, x, y, w, h, conf in frames[frame]:
if w <= 0 or h <= 0:
problems.append(f"frame {frame} id {tid}: non-positive size")
if tid in seen:
problems.append(f"frame {frame}: duplicate id {tid}")
seen.add(tid)
return problems
sample = """1,1,10,10,40,40,1,-1,-1,-1
2,1,14,10,40,40,1,-1,-1,-1
2,2,100,100,50,60,0.8,-1,-1,-1
3,1,18,10,40,40,1,-1,-1,-1
3,1,18,10,40,40,1,-1,-1,-1
0,3,5,5,0,10,1,-1,-1,-1
"""
print(corners_to_row(5, 7, [10, 20, 60, 100], 0.9))
for p in check(read_mot(sample)):
print(p)The script prints the converted row, then one line per problem:
5,7,10.00,20.00,50.00,80.00,0.90,-1,-1,-1
frame 0: frame numbers start at 1
frame 0 id 3: non-positive size
frame 3: duplicate id 1A real evaluator also rejects these files, or it scores them wrongly without telling you. Running a check like this before each submission saves failed uploads.
Datasets beyond pedestrians
MOTChallenge covers one object class in mostly street scenes. Other datasets stress different parts of the tracker.
| Dataset | Scene | What it stresses |
|---|---|---|
| MOT17 | Street and mall pedestrians | Standard baseline, static and moving cameras |
| MOT20 | Crowded pedestrians | Heavy occlusion, many overlapping boxes |
| KITTI tracking | Driving, cars and pedestrians | Camera on a moving vehicle |
| BDD100K MOT | Driving, many classes | Weather, lighting, and class diversity |
| DanceTrack | Group dancing | Uniform appearance, complex motion |
| SportsMOT | Team sports | Fast motion, similar uniforms |
| TAO | Everyday video | Large, long-tailed set of categories |
| nuScenes | Driving with lidar and cameras | 3D tracking across sensors |
The dataset you choose should match the weakness you want to expose.
- MOT20 punishes trackers that rely on IoU alone, since boxes overlap constantly.
- DanceTrack punishes trackers that rely on appearance, because every dancer looks alike. Detection is easy there, so the score mostly reflects association quality.
- KITTI and BDD100K add camera motion, which breaks the assumption behind a constant-velocity Kalman filter.
- TAO and nuScenes change the problem itself. TAO has so many categories that detection is the bottleneck, and nuScenes asks for 3D positions. Both use their own metrics, such as track-level mAP on TAO and AMOTA on nuScenes, rather than the MOTA, IDF1, and HOTA from MOTChallenge.
The evaluation workflow
Most published numbers follow the same path. The detector and tracker are separate stages, so changing either one changes the final score.
The standard open-source evaluation tool is TrackEval. It implements HOTA, CLEAR MOT (which includes MOTA), and Identity (which includes IDF1). It is also the reference implementation behind the MOTChallenge server. Using it locally on a training split gives numbers that are comparable to published results.
Splits and honest evaluation
Each benchmark gives you labeled training sequences and hidden test sequences. A tracker has hyperparameters such as the IoU threshold, the maximum number of misses, and the detection confidence cutoff. You have to choose them somewhere.
- Do not tune on the test server. Each submission tells you something about the hidden labels, and many submissions overfit them.
- Hold out part of the training data as a validation set. Splitting by sequence is safer than splitting by frame, because neighboring frames are nearly identical and leak information.
- Report the benchmark's official numbers for the final result only.
Common pitfalls
- Mismatched detections. Comparing a tracker with public detections against one with a stronger private detector.
- Wrong box format. Writing corners where the file expects width and height, or mixing 0-based and 1-based frame numbers.
- Confidence thresholds. Detection confidence cutoffs change MOTA and IDF1 considerably. A tracker with a tuned threshold can beat a stronger tracker with a poor one.
- Metric choice. MOTA is dominated by detection errors, while IDF1 and HOTA give more weight to identity. A method that improves association may show little change in MOTA.
- Overfitting to one benchmark. A score on MOT17 says little about behavior on moving-camera driving footage or on uniform-looking dancers. Evaluate on at least two datasets with different failure profiles.
- Ignoring runtime. Benchmarks report accuracy, but a tracker that needs a heavy re-identification network may not meet a real-time budget. Report speed alongside accuracy when you compare methods.
Choosing a benchmark for your project
Match the benchmark to your deployment.
- Retail, surveillance, or crowds: MOT17 and MOT20.
- Autonomous driving: KITTI, BDD100K, or nuScenes, depending on whether you need 2D or 3D output.
- Sports analytics: SportsMOT, and DanceTrack as a stress test for identity.
- Open-world or many categories: TAO.
If none of these resembles your footage, annotate a small validation set of your own. Even a few minutes of labeled video in MOT format lets you reuse the same evaluation tools and measure the failure modes that matter to you.
Exercise
Tracker A reports a MOT17 score using the public detections. Tracker B reports a higher MOT17 score using its own detector trained on extra pedestrian data. A colleague says B has the better tracking algorithm. What is wrong with that conclusion, and what would you run to make the comparison fair?
Show answer
B's score mixes detector quality with tracker quality, so the higher number may come entirely from the better detector. To compare the tracking algorithms, run both trackers on the same detections, either the public ones or one shared private detector. Evaluate both with the same tool (TrackEval) on the same sequences, and look at IDF1 or HOTA as well as MOTA, since those reflect identity quality more directly.
Exercise
Your tracker writes the result row "3,4,100,50,160,130,0.9,-1,-1,-1" for a box whose corners are [100, 50, 160, 130]. Why is this row wrong for MOTChallenge, and what should it be?
Show answer
MOTChallenge expects the box as left, top, width, and height, but this row has the right and bottom corners in the width and height fields. The width should be 160 - 100 = 60 and the height 130 - 50 = 80, so the row should be "3,4,100,50,60,80,0.9,-1,-1,-1". The wrong row still parses as a valid box, so no error appears, but the boxes are oversized and the score falls.
Exercise
You tune the max-misses and IoU threshold of your tracker by submitting 20 variants to the MOT17 test server and keeping the best one. Why is the final score not a reliable estimate of how the tracker will perform on new video, and what should you do instead?
Show answer
Each submission reveals how well that setting fits the hidden test sequences, so choosing the best of 20 fits the parameters to the test data and overestimates performance on new footage. Instead, hold out validation sequences from the training data, split by sequence rather than by frame, tune the parameters there, and submit to the test server once with the chosen settings.