SlowFast R50 Basketball Round-State Classifier

This is a binary video classifier for identifying whether a basketball broadcast clip is currently inside an active round/play segment. It was locally fine-tuned from the PyTorchVideo SlowFast R50 model pretrained on Kinetics-400.

Model details

  • Architecture: SlowFast R50
  • Task: binary video classification
  • Input: 32 RGB frames sampled uniformly from a clip
  • Input resolution: 224 × 224
  • Slow pathway: every fourth frame, up to 8 frames
  • Fast pathway: up to 32 frames
  • Classes: 0 = not_in_round, 1 = in_round
  • Selected checkpoint: epoch 4
  • Validation accuracy: 84.68%
  • Validation loss: 0.4825
  • Base implementation and pretrained model: facebookresearch/pytorchvideo, SlowFast R50, Kinetics-400

The accuracy above is taken from the local validation split used during training. It has not been independently reproduced on a public benchmark and should not be compared directly with results obtained using different splits.

Intended use

The model is intended for research and prototyping involving basketball broadcast segmentation, highlight extraction and editing assistance. It predicts whether a short clip resembles active play; it does not identify players, recognize identities, determine official game events or replace human editorial review.

Training procedure

The Kinetics-400 pretrained backbone was loaded from PyTorchVideo. Backbone parameters were frozen and the final classification block was trained with AdamW, cosine learning-rate scheduling, cross-entropy with label smoothing, mixed precision and image augmentation.

Key settings:

  • Epochs: 8
  • Batch size: 4
  • Learning rate: 5e-5
  • Weight decay: 1e-5
  • Clip length: 32 frames
  • Normalization: mean [0.45, 0.45, 0.45], standard deviation [0.225, 0.225, 0.225]

Training-data disclosure

The training data is not included in this repository. It consisted of locally prepared basketball broadcast clips divided into in_round and not_in_round classes. Some source footage was collected from publicly accessible Bilibili videos. Public availability does not necessarily grant redistribution rights; therefore, no original videos, extracted frames, audio, subtitles, uploader information or Bilibili metadata are distributed with this model.

The uploader has not completed a work-by-work copyright clearance of the source footage. Users should independently evaluate whether their use of the weights and any downstream outputs complies with applicable copyright, privacy, publicity and platform rules. Rights holders may request review or removal through the Hugging Face repository contact/discussion channel.

Usage

Install dependencies:

pip install -r requirements.txt

Run inference:

python inference.py path/to/video.mp4 --checkpoint model.pth

The checkpoint is a PyTorch training checkpoint containing model_state_dict, epoch and validation metadata. Only load .pth files from sources you trust because PyTorch pickle-based files can execute code during deserialization.

Limitations

  • Broadcast graphics, replays, close-ups and unusual camera angles may cause false predictions.
  • Performance may degrade outside basketball broadcasts similar to the local training distribution.
  • The model may learn broadcaster-specific overlays or editing patterns.
  • The model has not been audited for demographic bias or memorization.
  • It should not be used for surveillance, biometric identification or decisions about individuals.

License and attribution

Released under Apache License 2.0. The base PyTorchVideo project and SlowFast implementation are also provided under Apache-2.0. See LICENSE and NOTICE.

Suggested citation:

@inproceedings{fan2021pytorchvideo,
  title={PyTorchVideo: A Deep Learning Library for Video Understanding},
  author={Fan, Haoqi and others},
  booktitle={Proceedings of the 29th ACM International Conference on Multimedia},
  year={2021}
}
Downloads last month

-

Downloads are not tracked for this model. How to track
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support