Vehicle Counting

by Yanzi Jin and Jakob Eriksson


This project takes street camera video as input, counts the number of vehicles along each possible trajectory. The main challenge comes from the low quality and various perspectives of those videos, which indicates that some standard computer vision techniques like object detection, are not able to achieve the same performance as good as that on high-quality videos and images.


Our system has two main parts: fully automatic tracking and counting. In tracking part, the system decides entrance and leaving of objects without any manual setting and tracks the objects until leaving.


Main Contributions

  • We assign one single object tracker for each object, using TLD tracker, while share the common image operations among all the objects.
  • Our tracker is fully automatic and does not require any manual labeling work. Initialization of tracked objects are done through a background model called ViBe.
  • Since we usually have small objects in surveillance video and unstable foreground blobs, we need to eliminate noises during tracking. We set strict policy for noisy objects and do reverse tracking to get a complete trajectory. Since the vehicle is regarded as non-noise object and initialized very late.

Results and Demos

Here we give result videos of tracking, counting and validation, as well as demo videos about basic operations of our counting application.

Tracking and Counting Results

To count the number of vehicles passed along each possible trajectory, we need a template for each possible trajectory. This is the only input we require from user. We can either import from file or draw them manually.
We compute minimal average distance to every template until the object leaves. Then we assign the template id to the object and increase the count of the template.

GUI Application Demos

Since the counting requires manual input from user, we design an GUI application for such operation.

Future Work

Currently our work deals well with situation without complex object interaction and scene setting. Our future work includes:
  • Ground truth generation and quantitative counting evaluation.
  • More accurate tracking algorithm combined with background model.
  • More complex object interaction.
  • Occlusion from scene.


  • TLD tracker.
  • ViBe background subtraction model.

-- Main.yjin25 - 2014-09-01

Copyright 2016 The Board of Trustees
of the University of
Helping Women Faculty Advance
Funded by NSF