Skip to content

About

End-to-end billiard match video analysis using purely classical computer vision: Table segmentation, ball classification, tracking, and 2D minimap projection.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

38 Commits

Folders and files

Repository files navigation

Sport Video Analysis for Billiard Matches

Tracking and Minimap Projection

Overview

This project implements a complete classical computer vision techniques pipeline to analyze billiard match videos. What makes it more challenging, no machine learning is implemented. The process automatically extracts key information from the video feed through a series of steps:

  1. Table Detection: Isolates the playing surface.

Table Detection

  1. Ball Detection & Classification: Localizes each ball and classifies it as white, black, solid, or striped.

Table Detection

Table Detection

  1. Tracking & Projection: Tracks the balls' trajectories over time and projects their movements onto a standardized 2D minimap.

For an in-depth explanation of the algorithms, methodology, and detailed evaluation metrics, please refer to the complete report: Report_Computer_Visionaries.pdf.

How to Build and Run

1. Navigate to the build folder:

mkdir build
cd build

2. Clean the build directory (if necessary):

rm -rf *

3. Build the project:

cmake ..
make

4. Run the program: Pass the path to a specific game clip as an argument, example:

./Billiard_CV path/to/Billiard_CV/data/game1_clip3/game1_clip3.mp4

Execution Flow

The process allows for the visualization, in order, of:

  • The first frame of the video
  • The results of the ball localization and classification
  • The plotting on the minimap
  • The segmentation mask
  • The resulting mAP and IoU of the process, in the terminal
  • The tracking of the balls that are moved in the video

To move onto the next image, press any key.

All generated images and videos resulting from the various computations (such as table/ball detection and tracking) are automatically saved to the data/output folder.

About

End-to-end billiard match video analysis using purely classical computer vision: Table segmentation, ball classification, tracking, and 2D minimap projection.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages