People Counter

  • Python
  • Vue.js
  • Coral Dev Board
  • Firebase
  • RethinkDB
  • TFLite
Picture of People Counter

Together with three other students, we created an on-device people counter. This project was made for ML6 . The use case was to count the amount people who enter and exit the train. That way you could track the amount of people at any given time on the train.

This project consists of three parts, the Coral Dev Board with camera, the cloud backend with Firebase Realtime Database and Pub/Sub system, and the last part the frontend to display all of the data.

Original

Coral Dev Board

Each camera has a Coral Dev Board to process the images. These cameras need to be set up at an entrance or exit. A Tensorflow Lite model runs on the Dev Board to detect people in the images. Next a centroid tracker is used to track the people moving along the image. When someone crosses a certain hardcoded line it is counted as entering or exiting.

To comply with EU data protection laws, no images are saved and the only thing sent to the backend is +1 or -1 (person entered or left). No user identifiable data is saved or transmitted.

Backend

The backend consists of a Pub/Sub system with Firebase Realtime Database. The Pub/Sub is used to register new devices (cameras) and send data to. The Firebase Realtime Database holds all of the devices, locations and the amount of people in those locations.

Frontend

The frontend is a Vue.js application tailored towards the NMBS (use case). You can view the current amount of people in a location (train), view a graph that shows the occupancy at any given time. In the setting you can change which camera is used for which location. You can also add multiple cameras to a single location for multiple entrances / exits.

Rework

This project has been reworked to be cloud independent and use a more generic dashboard.

Coral Dev Board

A new web interface was added to view the video stream with osd elements to help debugging.

Backend

The backend was completely reworked. Instead of using Firebase and Google Cloud Pub/Sub it now uses RethinkDB as backend. RethinkDB is a realtime database that can be deployed anywhere. The Coral Dev Board now also directly communicates with the database.

Frontend

The frontend was also completely reworked. Instead of using Vue.js I opted to use a default node application with Express as the dashboard is not super complicated. It also has a completely new design to not be associated with the NMBS and be more generic.

Original project available on GitHub

Reworked dashboard and coral project also on GitHub.

Authors

  • Picture of Céline Bogaerts

    Céline Bogaerts

  • Picture of Ruben Delaet

    Ruben Delaet

  • Picture of Jarne Demeulemeester

    Jarne Demeulemeester

  • Picture of Lex Eggermont

    Lex Eggermont