Skip to content

LouiseMassager/DDE_project_bouncingball

Repository files navigation


Study of the bouncing motion of a ball using Computer Vision and Data-Driven methods

For the MECA-H-419 Data-Driven Engineering course

Link to the report

Demonstrations

Tracking of the ball with color (left) and shape (right):

Features

This project relies on code realised in Python and MATLAB.

The tracking has been realized with opencv and imutils which can be installed with pip:

python -m pip install opencv-python
python -m pip install imutils

Multiple other code on Python rely on sklearn and numpy which can be installed with pip:

python -m pip install numpy

The optimisation has been realised using the MATLAB MPT toolbox.

Codes description

  • DDE_tracking_with_color.ipynb can be used to track and save the position of the center of the ball with based on its color.

  • DDE_tracking_with_shape.ipynb can be used to track and save the position of the center of the ball with based on its shape.

  • outlier_detection.ipynb aims to detect outliers in the experimental data (previously obtained with computer vision).

  • DDE_bounce_clustering.ipynb serves to split the data in each rebound of the ball in order to account for the offset caused by the ball moving slightly towards/away from the camera during the experimentation. This offset must be removed for improved results later on as it makes the accurate height of the ball harder to estimate.

  • optimisation.m is a MATLAB code which has been implemented in order to deduce the actual height at which the ball was released initially from the experimental data and the coefficient of restitution. It has been realised by trying to match the experimental data with the actual physical equation behinf it with a Least-Square optimisation.

  • Trajectory_regression.ipynb revolves around a regression method in order to estimate from the current and previous position of the ball, its next position.

  • removeOutliers.m is a self-written code that aims to detect and remove outliers in a dataset.

  • DDE_velocity_cleaning.m computes the ball velocity from its position and removes outliers.

  • DDE_velocity_LPCA.ipynb applies DBSCAN clustering in order to use Local PCA to each cluster.

Authors

Acknowledgements

(back to top)

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors