Every modern discussion about football analytics eventually comes back to one question: where were the players? Positions are the raw material of tactical analysis. For years, collecting them required expensive optical systems installed in stadiums or GPS vests worn by every player. Today, computer vision can extract the same information from ordinary video. Here is how player tracking with computer vision works, step by step, and what coaches should know before relying on it.

What is computer vision?

Computer vision is the field of artificial intelligence that teaches computers to understand images and video. Instead of a human watching a match and noting events, a model analyses each frame and answers questions such as: where are the players, which team is each player in, and where is the ball? Repeated 25 to 50 times per second, those answers become a complete movement record of the game.

The player tracking pipeline in 5 steps

1. Detection: finding players in each frame

A detection model, trained on thousands of labelled football images, draws a bounding box around every person and the ball in a frame. Modern real-time detectors are fast enough to process full matches, even on a single GPU.

2. Tracking: following each player over time

Detection alone tells you where people are in one frame. Tracking links those detections across frames so that player 7 in frame 100 is still player 7 in frame 101. Multi-object tracking algorithms combine motion prediction with visual appearance to keep identities stable, even when players run close to each other.

3. Team assignment

Next, every tracked player is assigned to a team, the referees or the goalkeepers. A common approach is to cluster players by the colours of their kits. Combined with jersey-number recognition, this lets the system build a consistent picture of both teams.

4. Pitch calibration: from pixels to metres

A camera image is distorted by perspective: a metre near the camera looks much bigger than a metre on the far side. By detecting pitch lines, the penalty box and the centre circle, the system calculates a transformation (a homography) that maps every pixel to real pitch coordinates. From this moment, positions are measured in metres instead of pixels.

5. Analytics: turning positions into insight

With calibrated positions for every player, the useful part begins. Typical outputs include:

  • Distance covered, sprint counts and top speed per player
  • Heatmaps and average positions
  • Team shape, line height and compactness
  • Distances between defensive and midfield lines
  • Passing options, pressing distances and space control

In our project on AI player recognition and tactical tracking we use this pipeline to analyse team structures, and in defensive and offensive spaces visualisation we turn tracking data into clear visual maps of space.

Limits every coach should know

Computer vision is powerful, but it is not magic. Results depend heavily on the video:

  • Occlusion: when players overlap, identities can be swapped.
  • Camera angle: broadcast footage zooms and cuts, so players regularly leave the frame. A fixed wide tactical camera gives much better data.
  • The ball: it is small, fast and often hidden, which makes ball tracking the hardest part of the problem.
  • Video quality: low resolution or poor lighting reduces accuracy.

For amateur and youth clubs, the most practical setup is a single elevated camera that sees the whole pitch. It will not match the precision of professional systems, but it is more than enough to analyse team shape and positional behaviour.

How coaches can use tracking data

  1. Pick one tactical question, for example “How compact are we when we lose the ball?”
  2. Record matches with a stable, wide camera angle.
  3. Measure two or three simple KPIs, such as distance between lines or the number of players behind the ball.
  4. Show the results to players with clips and visuals, not just numbers.
  5. Repeat over several matches to see real trends instead of one-off events.

Learn more in Modern Football Intelligence

Computer vision, player tracking and tactical analytics are explained in depth in the book by Anas Skiti – with practical methods for coaches, analysts and students.