--- license: agpl-3.0 tags: - soccer - video - foul - recognition - classification --- # ⚽ OpenSportsLib Classification Model (MViT - V2) ## 📌 Overview This model is a **video-based classification model** built using the **OpenSportsLib**, designed for **soccer action classification**. - **Task**: Action / Event Classification - **Architecture**: MViT (Multiscale Vision Transformer) - **Library**: OpenSportsLib - **Input**: Video clips --- ## 📂 Dataset ### Training Dataset This model is trained on the **SoccerNet – MVFouls (Classification subset)**: 👉 https://huggingface.co/datasets/OpenSportsLab/soccernetpro-classification-vars/tree/mvfouls/train - **Domain**: Soccer video understanding - **Task**: Event classification - **Modality**: Video --- ## 📊 Benchmark Results | Metric | Score | |--------------|------| | Accuracy | 0.57 | | Balanced Accuracy | 0.4 | | Top-2 | 0.78 | --- ## 🔧 Using with OpenSportsLib For more details about OpenSportsLib visit the below link 👉 Github - https://github.com/OpenSportsLab/opensportslib 👉 PyPi - https://pypi.org/project/opensportslib/ 👉 Documentations - https://opensportslab.github.io/opensportslib/ ### Import the library ```python import opensportslib print("OpenSportsLib imported successfully") ``` ### Run inference ```python from opensportslib.apis import ClassificationModel my_model = ClassificationModel( config="/path/to/classification.yaml", 👉 weights="OpenSportsLab/OSL-cls-action-mvitv2", ) predictions = my_model.infer( test_set="/path/to/test.json", ) saved_predictions = my_model.save_predictions( output_path="/path/to/predictions.json", predictions=predictions, ) metrics = my_model.evaluate( test_set="/path/to/test.json", predictions=saved_predictions, ) print(metrics) ``` --- ## 📜 License - **Open source license**: AGPL 3.0 for research, academic, and community use. - **Commercial license**: For proprietary or commercial deployment, please contact the project maintainers. __ ## 📎 Citation ``` @misc{opensportslib_mvitv2_classification, title={OpenSportsLib Classification MViT V2}, author={OpenSportsLab}, year={2026}, howpublished={https://huggingface.co/OpenSportsLab/oslib-MViTv2-classification} } ``` --- ## 🙏 Acknowledgements - **Dataset**: SoccerNet / OpenSportsLab - **Library**: https://github.com/OpenSportsLab/opensportslib