This repository provides a Python script to analyze soccer videos by detecting and tracking players, referees, and the ball, assigning teams by jersey colors, compensating for camera movement, transforming perspectives for accurate measurements, and visualizing speeds, distances, and ball possession.
How It Works
You find a handy tool online that analyzes soccer videos to track players and the ball like a coach would.
Download the example soccer video and the smart detection file from the provided links to get started.
Put your own soccer match video into the input folder so the tool can work on it.
Run the main program, and it automatically detects players, referees, teams, and the ball while adjusting for camera shakes.
Sit back as it calculates speeds, distances in real meters, and who controls the ball most.
Open the new output video to see colorful tracks, speed labels, team possession percentages, and all the insights overlaid on your match.
Star Growth
Repurpose is a Pro feature
Generate ready-to-use prompts for X threads, LinkedIn posts, blog posts, YouTube scripts, and more -- with full repo context baked in.
Unlock RepurposeSimilar repos coming soon.