Skip to content

Code for visualisations in my winning entry to the Liverpool Analytics Challenge by Friends of Tracking

Notifications You must be signed in to change notification settings

suryako/FoT-Liverpool-Analytics-Surya

Repository files navigation

FoT-Liverpool-Analytics-Surya

Visualisation code for my winning entry to the Liverpool Analytics Challenge by Friends of Tracking. Optimised for x6 speedup.

LINK TO ANALYSIS, on Medium
VIDEO OF PRESENTATION, on FoT Youtube channel

Pitch Control measures the probability that a team will retain possession of the ball if they pass it to another location on the field. It can be used to evaluate passing options for a player, and quantify the probability of success.


Visualisation Code

This repo is for recreating the Pitch Control videos shown above, with a x6 speedup1 from using Python's joblib.

To get started, clone this repo, including submodules2 using:

git clone --recurse-submodules https://github.com/suryako/FoT-Liverpool-Analytics-Surya.git

Install requirements and start a jupyter session with:

pip install -r requirements.txt
jupyter lab

Open main_notebook.ipynb and run the cells in the notebook sequentially.
The Pitch Control videos will be generated at goals_pc/_____.mp4
The notebook will allow you to interact with the data to get a better feel for it.


Acknowledgements

Many thanks to David Sumpter and Friends of Tracking for organising this, Ricardo Tavares for providing the dataset, and Laurie Shaw for the visualisation library.


Footnotes

1 x6 speedup on quad-core MacBook Pro with 8 vCPUs, increase n_jobs accordingly if you have even more CPU cores.

2 The dataset by Ricardo, and Ciaran's data format converter are included as submodules, locked at specific commit tags for reproducibility.
Laurie's code (and Pitch Control model) is directly included in this repo, to keep track of some of my changes that are specific to the Liverpool goal data.

About

Code for visualisations in my winning entry to the Liverpool Analytics Challenge by Friends of Tracking

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published