Update README.md
Browse files
README.md
CHANGED
|
@@ -10,8 +10,9 @@ tags:
|
|
| 10 |
- computer-vision
|
| 11 |
- pytorch
|
| 12 |
- ultralytics
|
|
|
|
| 13 |
datasets:
|
| 14 |
-
-
|
| 15 |
metrics:
|
| 16 |
- precision
|
| 17 |
- recall
|
|
@@ -20,12 +21,13 @@ library_name: ultralytics
|
|
| 20 |
pipeline_tag: object-detection
|
| 21 |
---
|
| 22 |
|
| 23 |
-
#
|
| 24 |
|
| 25 |
-
Fine-tuned YOLOv11n model for detecting tennis balls in images and videos.
|
| 26 |
|
| 27 |
## Model Details
|
| 28 |
|
|
|
|
| 29 |
- **Model Type**: Object Detection
|
| 30 |
- **Architecture**: YOLOv11 Nano (n)
|
| 31 |
- **Framework**: Ultralytics YOLOv11
|
|
@@ -48,11 +50,15 @@ Evaluated on validation set (62 images):
|
|
| 48 |
## Training Details
|
| 49 |
|
| 50 |
### Dataset
|
|
|
|
|
|
|
|
|
|
| 51 |
- **Training images**: 408
|
| 52 |
- **Validation images**: 62
|
| 53 |
- **Test images**: 50
|
| 54 |
- **Total**: 520 annotated images
|
| 55 |
- **Annotation format**: YOLO format (bounding boxes)
|
|
|
|
| 56 |
|
| 57 |
### Training Configuration
|
| 58 |
```yaml
|
|
@@ -81,19 +87,17 @@ Training time: ~23 minutes
|
|
| 81 |
## Usage
|
| 82 |
|
| 83 |
### Installation
|
| 84 |
-
|
| 85 |
```bash
|
| 86 |
pip install ultralytics
|
| 87 |
```
|
| 88 |
|
| 89 |
### Python API
|
| 90 |
-
|
| 91 |
```python
|
| 92 |
from ultralytics import YOLO
|
| 93 |
from PIL import Image
|
| 94 |
|
| 95 |
-
# Load model
|
| 96 |
-
model = YOLO('
|
| 97 |
|
| 98 |
# Predict on image
|
| 99 |
results = model.predict('tennis_match.jpg', conf=0.3)
|
|
@@ -109,11 +113,10 @@ for box in results[0].boxes:
|
|
| 109 |
```
|
| 110 |
|
| 111 |
### Video Processing
|
| 112 |
-
|
| 113 |
```python
|
| 114 |
from ultralytics import YOLO
|
| 115 |
|
| 116 |
-
model = YOLO('
|
| 117 |
|
| 118 |
# Process video
|
| 119 |
results = model.predict(
|
|
@@ -125,22 +128,20 @@ results = model.predict(
|
|
| 125 |
```
|
| 126 |
|
| 127 |
### Command Line
|
| 128 |
-
|
| 129 |
```bash
|
| 130 |
# Predict on image
|
| 131 |
-
yolo detect predict model=
|
| 132 |
|
| 133 |
# Predict on video
|
| 134 |
-
yolo detect predict model=
|
| 135 |
|
| 136 |
# Validate model
|
| 137 |
-
yolo detect val model=
|
| 138 |
```
|
| 139 |
|
| 140 |
## Recommended Hyperparameters
|
| 141 |
|
| 142 |
### Inference Settings
|
| 143 |
-
|
| 144 |
```python
|
| 145 |
# Balanced (recommended)
|
| 146 |
conf_threshold = 0.30 # Confidence threshold
|
|
@@ -175,11 +176,12 @@ max_det = 100
|
|
| 175 |
## Use Cases
|
| 176 |
|
| 177 |
โ
**Recommended:**
|
| 178 |
-
- Tennis match analysis
|
| 179 |
- Automated highlight generation
|
| 180 |
-
- Player training and coaching
|
| 181 |
-
-
|
| 182 |
-
-
|
|
|
|
| 183 |
|
| 184 |
โ ๏ธ **Not Recommended:**
|
| 185 |
- Real-time umpiring decisions (use as assistance only)
|
|
@@ -202,20 +204,29 @@ max_det = 100
|
|
| 202 |
| 0.3 - 0.5 | Low confidence - possible tennis ball |
|
| 203 |
| < 0.3 | Very low confidence - likely false positive |
|
| 204 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 205 |
## Model Card Authors
|
| 206 |
|
| 207 |
- **Developed by**: Vuong
|
| 208 |
- **Model date**: November 2024
|
| 209 |
-
- **Model version**: 1
|
| 210 |
- **Model type**: Object Detection (YOLOv11)
|
| 211 |
|
| 212 |
-
##
|
| 213 |
|
| 214 |
-
|
| 215 |
|
|
|
|
| 216 |
```bibtex
|
| 217 |
-
@misc{
|
| 218 |
-
title={
|
| 219 |
author={Vuong},
|
| 220 |
year={2024},
|
| 221 |
publisher={Hugging Face},
|
|
@@ -223,6 +234,24 @@ If you use this model, please cite:
|
|
| 223 |
}
|
| 224 |
```
|
| 225 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 226 |
## License
|
| 227 |
|
| 228 |
MIT License - Free for commercial and academic use.
|
|
@@ -230,8 +259,8 @@ MIT License - Free for commercial and academic use.
|
|
| 230 |
## Acknowledgments
|
| 231 |
|
| 232 |
- Built with [Ultralytics YOLOv11](https://github.com/ultralytics/ultralytics)
|
| 233 |
-
-
|
| 234 |
-
- Part of the
|
| 235 |
|
| 236 |
## Contact & Support
|
| 237 |
|
|
@@ -241,20 +270,24 @@ For questions, issues, or collaboration:
|
|
| 241 |
|
| 242 |
## Related Models
|
| 243 |
|
| 244 |
-
|
|
|
|
|
|
|
|
|
|
| 245 |
|
| 246 |
## Model Changelog
|
| 247 |
|
| 248 |
-
###
|
| 249 |
- Initial release
|
| 250 |
- YOLOv11n architecture
|
| 251 |
- mAP@50: 67.87%
|
| 252 |
-
- 520 training images
|
|
|
|
| 253 |
|
| 254 |
---
|
| 255 |
|
| 256 |
-
**Model Size**: 5.4 MB
|
| 257 |
-
**Inference Speed**: 10-65ms (device dependent)
|
| 258 |
**Supported Formats**: PyTorch (.pt), ONNX, TensorRT, CoreML
|
| 259 |
|
| 260 |
๐พ Ready for production use in tennis analysis applications!
|
|
|
|
| 10 |
- computer-vision
|
| 11 |
- pytorch
|
| 12 |
- ultralytics
|
| 13 |
+
- courtside
|
| 14 |
datasets:
|
| 15 |
+
- tennis-ball-detection
|
| 16 |
metrics:
|
| 17 |
- precision
|
| 18 |
- recall
|
|
|
|
| 21 |
pipeline_tag: object-detection
|
| 22 |
---
|
| 23 |
|
| 24 |
+
# CourtSide Computer Vision v0.1 ๐พ
|
| 25 |
|
| 26 |
+
Fine-tuned YOLOv11n model for detecting tennis balls in images and videos. Part of the CourtSide Computer Vision suite for comprehensive tennis match analysis.
|
| 27 |
|
| 28 |
## Model Details
|
| 29 |
|
| 30 |
+
- **Model Name**: CourtSide Computer Vision v0.1
|
| 31 |
- **Model Type**: Object Detection
|
| 32 |
- **Architecture**: YOLOv11 Nano (n)
|
| 33 |
- **Framework**: Ultralytics YOLOv11
|
|
|
|
| 50 |
## Training Details
|
| 51 |
|
| 52 |
### Dataset
|
| 53 |
+
|
| 54 |
+
This model was trained on the **Tennis Ball Detection Dataset** by Viren Dhanwani, available on Roboflow Universe.
|
| 55 |
+
|
| 56 |
- **Training images**: 408
|
| 57 |
- **Validation images**: 62
|
| 58 |
- **Test images**: 50
|
| 59 |
- **Total**: 520 annotated images
|
| 60 |
- **Annotation format**: YOLO format (bounding boxes)
|
| 61 |
+
- **Source**: [Roboflow Universe - Tennis Ball Detection](https://universe.roboflow.com/viren-dhanwani/tennis-ball-detection)
|
| 62 |
|
| 63 |
### Training Configuration
|
| 64 |
```yaml
|
|
|
|
| 87 |
## Usage
|
| 88 |
|
| 89 |
### Installation
|
|
|
|
| 90 |
```bash
|
| 91 |
pip install ultralytics
|
| 92 |
```
|
| 93 |
|
| 94 |
### Python API
|
|
|
|
| 95 |
```python
|
| 96 |
from ultralytics import YOLO
|
| 97 |
from PIL import Image
|
| 98 |
|
| 99 |
+
# Load CourtSide Computer Vision model
|
| 100 |
+
model = YOLO('courtsidecv_v0.1.pt')
|
| 101 |
|
| 102 |
# Predict on image
|
| 103 |
results = model.predict('tennis_match.jpg', conf=0.3)
|
|
|
|
| 113 |
```
|
| 114 |
|
| 115 |
### Video Processing
|
|
|
|
| 116 |
```python
|
| 117 |
from ultralytics import YOLO
|
| 118 |
|
| 119 |
+
model = YOLO('courtsidecv_v0.1.pt')
|
| 120 |
|
| 121 |
# Process video
|
| 122 |
results = model.predict(
|
|
|
|
| 128 |
```
|
| 129 |
|
| 130 |
### Command Line
|
|
|
|
| 131 |
```bash
|
| 132 |
# Predict on image
|
| 133 |
+
yolo detect predict model=courtsidecv_v0.1.pt source=image.jpg conf=0.3
|
| 134 |
|
| 135 |
# Predict on video
|
| 136 |
+
yolo detect predict model=courtsidecv_v0.1.pt source=video.mp4 conf=0.3 save=True
|
| 137 |
|
| 138 |
# Validate model
|
| 139 |
+
yolo detect val model=courtsidecv_v0.1.pt data=dataset.yaml
|
| 140 |
```
|
| 141 |
|
| 142 |
## Recommended Hyperparameters
|
| 143 |
|
| 144 |
### Inference Settings
|
|
|
|
| 145 |
```python
|
| 146 |
# Balanced (recommended)
|
| 147 |
conf_threshold = 0.30 # Confidence threshold
|
|
|
|
| 176 |
## Use Cases
|
| 177 |
|
| 178 |
โ
**Recommended:**
|
| 179 |
+
- Tennis match analysis and statistics
|
| 180 |
- Automated highlight generation
|
| 181 |
+
- Player training and coaching tools
|
| 182 |
+
- Ball trajectory tracking
|
| 183 |
+
- Sports analytics dashboards
|
| 184 |
+
- Action recognition pipelines
|
| 185 |
|
| 186 |
โ ๏ธ **Not Recommended:**
|
| 187 |
- Real-time umpiring decisions (use as assistance only)
|
|
|
|
| 204 |
| 0.3 - 0.5 | Low confidence - possible tennis ball |
|
| 205 |
| < 0.3 | Very low confidence - likely false positive |
|
| 206 |
|
| 207 |
+
## CourtSide Computer Vision Suite
|
| 208 |
+
|
| 209 |
+
This model is part of the **CourtSide Computer Vision** project, a comprehensive tennis analysis system featuring:
|
| 210 |
+
- ๐พ Ball detection (this model)
|
| 211 |
+
- ๐ค Player detection and tracking
|
| 212 |
+
- ๐ฏ Action recognition (forehand, backhand, serve, etc.)
|
| 213 |
+
- ๐ Match statistics generation
|
| 214 |
+
|
| 215 |
## Model Card Authors
|
| 216 |
|
| 217 |
- **Developed by**: Vuong
|
| 218 |
- **Model date**: November 2024
|
| 219 |
+
- **Model version**: v0.1
|
| 220 |
- **Model type**: Object Detection (YOLOv11)
|
| 221 |
|
| 222 |
+
## Citations
|
| 223 |
|
| 224 |
+
### This Model
|
| 225 |
|
| 226 |
+
If you use this model, please cite:
|
| 227 |
```bibtex
|
| 228 |
+
@misc{courtsidecv_v0.1_2024,
|
| 229 |
+
title={CourtSide Computer Vision v0.1: Tennis Ball Detection with YOLOv11},
|
| 230 |
author={Vuong},
|
| 231 |
year={2024},
|
| 232 |
publisher={Hugging Face},
|
|
|
|
| 234 |
}
|
| 235 |
```
|
| 236 |
|
| 237 |
+
### Dataset
|
| 238 |
+
|
| 239 |
+
This model was trained using the Tennis Ball Detection dataset. Please cite:
|
| 240 |
+
```bibtex
|
| 241 |
+
@misc{tennis-ball-detection_dataset,
|
| 242 |
+
title = {tennis ball detection Dataset},
|
| 243 |
+
type = {Open Source Dataset},
|
| 244 |
+
author = {Viren Dhanwani},
|
| 245 |
+
howpublished = {\url{https://universe.roboflow.com/viren-dhanwani/tennis-ball-detection}},
|
| 246 |
+
url = {https://universe.roboflow.com/viren-dhanwani/tennis-ball-detection},
|
| 247 |
+
journal = {Roboflow Universe},
|
| 248 |
+
publisher = {Roboflow},
|
| 249 |
+
year = {2023},
|
| 250 |
+
month = {feb},
|
| 251 |
+
note = {visited on 2024-11-20}
|
| 252 |
+
}
|
| 253 |
+
```
|
| 254 |
+
|
| 255 |
## License
|
| 256 |
|
| 257 |
MIT License - Free for commercial and academic use.
|
|
|
|
| 259 |
## Acknowledgments
|
| 260 |
|
| 261 |
- Built with [Ultralytics YOLOv11](https://github.com/ultralytics/ultralytics)
|
| 262 |
+
- Dataset by Viren Dhanwani via [Roboflow Universe](https://universe.roboflow.com/viren-dhanwani/tennis-ball-detection)
|
| 263 |
+
- Part of the CourtSide Computer Vision project for tennis analysis
|
| 264 |
|
| 265 |
## Contact & Support
|
| 266 |
|
|
|
|
| 270 |
|
| 271 |
## Related Models
|
| 272 |
|
| 273 |
+
Coming soon in the CourtSide Computer Vision suite:
|
| 274 |
+
- CourtSide CV - Player Detection
|
| 275 |
+
- CourtSide CV - Racket Detection
|
| 276 |
+
- CourtSide CV - Court Segmentation
|
| 277 |
|
| 278 |
## Model Changelog
|
| 279 |
|
| 280 |
+
### v0.1 (2024-11-20)
|
| 281 |
- Initial release
|
| 282 |
- YOLOv11n architecture
|
| 283 |
- mAP@50: 67.87%
|
| 284 |
+
- 520 training images from Roboflow dataset
|
| 285 |
+
- Optimized for tennis ball detection in match footage
|
| 286 |
|
| 287 |
---
|
| 288 |
|
| 289 |
+
**Model Size**: 5.4 MB
|
| 290 |
+
**Inference Speed**: 10-65ms (device dependent)
|
| 291 |
**Supported Formats**: PyTorch (.pt), ONNX, TensorRT, CoreML
|
| 292 |
|
| 293 |
๐พ Ready for production use in tennis analysis applications!
|