TrajSV: A Trajectory-based Model for Sports Video Representations and Applications

Zheng Wang, Shihao Xu, Wei Shi · OpenReview

Abstract

Sports analytics has received significant attention from both academia and industry in recent years. Despite the growing interest, several issues remain unresolved, including data unavailability, the lack of an effective trajectory-based framework, and the requirement for sufficient supervision labels. We present TrajSV, a trajectory-based framework that addresses these issues. TrajSV comprises three components: data preprocessing, Clip Representation Network (CRNet), and Video Representation Network (VRNet). The data preprocessing module extracts player and ball trajectories from sports broadcast videos. CRNet utilizes a trajectory-enhanced Transformer module to learn clip representations, while VRNet learns video representations by aggregating these with visual features using an encoder-decoder architecture. A triple contrastive loss is introduced to optimize representations in an unsupervised manner. Experiments on three broadcast video datasets (soccer, basketball, and volleyball) demonstrate that TrajSV achieves state-of-the-art performance in sports video retrieval (nearly 70% improvement), action spotting, and video captioning.

Introduction

Sports analytics is currently caught between a rock and a hard place. High-end professional tracking is prohibitively expensive, while standard computer vision models often struggle with the unique, high-speed spatial dynamics of sports. Furthermore, most existing AI models are task-specific and require massive manually labeled datasets. TrajSV aims to bridge this gap by creating a task-agnostic, unsupervised representation that works using standard TV broadcasts available on the web.

Methodology

The TrajSV framework consists of three main stages designed for both online and offline processing across various sports applications.

Overall architecture of the TrajSV framework and its applications.

Data Preprocessing

Instead of specialized sensors, TrajSV uses a pipeline of standard CV tools (ResNet for segmentation, TVCalib for camera calibration, and FairMOT for tracking) to extract 2D trajectories of players and the ball from raw video. These are mapped to a standardized sports field coordinate system.

Clip Representation Network (CRNet)

CRNet tokenizes trajectories into segment matrices and processes them through a trajectory-enhanced Transformer. These spatial features are fused with visual features from an X-CLIP backbone to create a rich representation of a short video clip.

Video Representation Network (VRNet)

VRNet uses an encoder-decoder architecture with attention blocks (MAB and MSB) to aggregate clip representations. This allows the model to prioritize significant moments, such as goals, when forming a global video representation. To train without human labels, a triple contrastive loss is introduced, forcing the model to learn spatial patterns, temporal dependencies, and robust representations through various augmentations.

Datasets and Evaluation

The framework was evaluated on three major datasets:

  • YouTube: 3,261 soccer videos crawled from various channels.
  • SoccerNet: A massive benchmark with 550 games, 17 action categories, and 36,000+ captions.
  • SportsMOT: 240 videos covering soccer, basketball, and volleyball to test generalization.

Key Results

TrajSV demonstrates significant improvements across multiple downstream tasks, confirming that trajectories capture the "underlying structure" of sports better than pixels alone.

Performance comparison for sports video retrieval across three datasets.
  • Sports Video Retrieval: TrajSV outperformed baselines by nearly 70% (measured by Hit Ratio @ 1) on the YouTube and SoccerNet datasets.
  • Action Spotting: The model achieved state-of-the-art results in 9 out of 17 action categories on SoccerNet, showing particular strength in identifying complex events like yellow-to-red cards and substitutions.
  • Video Captioning: The framework demonstrated a 20% improvement in captioning metrics, proving that better trajectory understanding leads to more accurate natural language descriptions.
  • Multi-Sport Success: The model maintained high performance across soccer, basketball, and volleyball, confirming its versatility.

Conclusion

TrajSV proves that meaningful trajectory data can be reconstructed from standard 2D broadcasts to create powerful, unsupervised video representations. While performance is dependent on the quality of initial tracking and calibration, the framework opens doors for advanced analytics such as automated team tactics discovery and individual player performance analysis.

Summary updated

Abstract

Sports analytics has received significant attention from both academia and industry in recent years. Despite the growing interest and efforts in this field, several issues remain unresolved, including (1) data unavailability, (2) lack of an effective trajectory-based framework, and (3) requirement for sufficient supervision labels. In this paper, we present TrajSV, a trajectory-based framework that addresses various issues in existing studies. TrajSV comprises three components: data preprocessing, Clip Representation Network (CRNet), and Video Representation Network (VRNet). The data preprocessing module extracts player and ball trajectories from sports broadcast videos. CRNet utilizes a trajectory-enhanced Transformer module to learn clip representations based on these trajectories. Additionally, VRNet learns video representations by aggregating clip representations and visual features with an encoder-decoder architecture. Finally, a triple contrastive loss is introduced to optimize both video and clip representations in an unsupervised manner. The experiments are conducted on three broadcast video datasets to verify the effectiveness of TrajSV for three types of sports (i.e., soccer, basketball, and volleyball) with three downstream applications (i.e., sports video retrieval, action spotting, and video captioning). The results demonstrate that TrajSV achieves state-of-the-art performance in sports video retrieval, showcasing a nearly 70% improvement. It outperforms baselines in action spotting, achieving state-of-the-art results in 9 out of 17 action categories, and demonstrates a nearly 20% improvement in video captioning. Additionally, we introduce a deployed system along with the three applications based on TrajSV.
BibTeX
@article{wang2025trajsv,
  author = {Zheng Wang and Shihao Xu and Wei Shi},
  title = {{TrajSV: A Trajectory-based Model for Sports Video Representations and Applications}},
  journal = {IEEE Transactions on Circuits and Systems for Video Technology},
  year = {2025},
  doi = {10.1109/tcsvt.2025.3599544},
}
Figure