YAML Metadata Warning:empty or missing yaml metadata in repo card
Check out the documentation for more information.
- Crowd Tracking YOLO26s Detector
- Set this to your repository directory.
- If running inside the repository, Path.cwd() is sufficient.
license: apache-2.0 tags: - object-detection - yolo - yolo26 - crowd-detection - pedestrian-detection - mot17 - mot20 - crowdhuman datasets: - CrowdHuman - MOT17 - MOT20 metrics: - mAP - recall - precision library_name: ultralytics pipeline_tag: object-detection
Crowd Tracking YOLO26s Detector
This repository contains a fine-tuned YOLO26s model for high-density pedestrian and crowd detection. The model is intended for challenging scenes with heavy occlusion, including crowded public spaces and pedestrian environments.
The training setup combines three benchmark datasets: CrowdHuman, MOT17, and MOT20.
π How to Download and Run Inference
Method 1: Python and Ultralytics (Recommended)
1. Install Dependencies
pip install ultralytics huggingface_hub
2. Download the Model and Run Inference
from huggingface_hub import hf_hub_download
from ultralytics import YOLO
# Download the trained model weights from Hugging Face
model_path = hf_hub_download(
repo_id="Rokayya/Crowd_Tracking_yolo26s_detector",
filename="best.pt"
)
# Load the model
model = YOLO(model_path)
# Run inference on an image
results = model.predict(
source="path/to/crowd_image.jpg",
conf=0.25,
imgsz=640,
save=True
)
# Display the first result
results[0].show()
Replace path/to/crowd_image.jpg with the path to your own image.
To process a video, replace the image path with a video path:
results = model.predict(
source="path/to/video.mp4",
conf=0.30,
imgsz=640,
save=True
)
Method 2: Manual Download Using Hugging Face
1. Install the Hugging Face Hub
pip install -U huggingface_hub ultralytics
2. Download the Repository
hf download Rokayya/Crowd_Tracking_yolo26s_detector \
--local-dir ./yolo26s_crowd
3. Load the Local Weights
from ultralytics import YOLO
model = YOLO("./yolo26s_crowd/best.pt")
results = model.predict(
source="path/to/video.mp4",
conf=0.30,
imgsz=640,
save=True
)
π Model Performance and Specifications
| Specification | Value |
|---|---|
| Base architecture | YOLO26s (Small) |
| Task | Pedestrian and crowd object detection |
| Input resolution | 640 Γ 640 |
| Target class | Person / Pedestrian |
| Framework | Ultralytics |
| Model weights | best.pt |
| Intended application | Dense crowd and pedestrian detection |
Actual performance depends on the hardware, input resolution, confidence threshold, and evaluation dataset. Refer to the reported experimental results for measured accuracy, inference speed, and GPU memory usage.
π Training and Evaluation Datasets
The project uses three pedestrian-related benchmarks:
1. CrowdHuman
CrowdHuman is a pedestrian detection benchmark containing crowded scenes and substantial person-to-person occlusion. It is useful for evaluating detection in dense crowds.
2. MOT17
MOT17 is a multi-object tracking benchmark containing pedestrian sequences captured in diverse real-world environments. Its annotations can support pedestrian detection and tracking research.
3. MOT20
MOT20 focuses on extremely crowded scenes and presents challenging conditions for pedestrian detection and multi-object tracking.
Dataset note: Using MOT17 and MOT20 for detector training does not, by itself, mean that the model performs multi-object tracking. Tracking requires an additional tracking algorithm and appropriate evaluation.
π§ Training Overview
- Model: YOLO26s
- Training data: CrowdHuman, MOT17, and MOT20
- Detection target: Pedestrians
- Image size: 640 Γ 640
- Checkpoint:
best.pt
The exact training configuration, number of epochs, random seed, validation results, and hardware should be documented using the actual experiment logs.
π Evaluation Metrics
The following metrics are useful for evaluating the detector:
- Precision: The proportion of predicted detections that are correct.
- Recall: The proportion of ground-truth people successfully detected.
- mAP@0.5: Mean average precision at an IoU threshold of 0.50.
- mAP@0.5:0.95: Mean average precision averaged across IoU thresholds from 0.50 to 0.95.
- Inference latency: Time required to process an image.
- FPS: Number of images processed per second under a specified benchmark setup.
- Peak GPU memory: Maximum GPU memory used during inference.
Add your actual measured results to this README when they are available. Do not interpret dataset descriptions or training metrics as measured performance on every benchmark.
π Citations and References
If you use this model or the underlying datasets and methods, please cite the relevant original publications.
1. YOLO26
Ultralytics YOLO26 documentation and official implementation:
Verify the exact publication metadata before citing a specific YOLO26 paper.
2. CrowdHuman Dataset
@article{shao2018crowdhuman,
title={CrowdHuman: A Benchmark for Detecting Human in a Crowd},
author={Shao, Shuai and Zhao, Zijian and Li, Boxun and Xiao, Tianshu and Yu, Gang and Zhang, Xiang and Sun, Jian},
journal={arXiv preprint arXiv:1805.00123},
year={2018}
}
3. MOT17 Benchmark
@article{milan2016mot16,
title={MOT16: A Benchmark for Multi-Object Tracking},
author={Milan, Anton and Leal-Taixe, Laura and Reid, Ian and Roth, Stefan and Schindler, Konrad},
journal={arXiv preprint arXiv:1603.00831},
year={2016}
}
4. MOT20 Benchmark
@article{dendorfer2020mot20,
title={MOT20: A benchmark for multi object tracking in crowded scenes},
author={Dendorfer, Patrick and Rezatofighi, Hamid and Milan, Anton and Shi, Javen and Zhang, Shan and Kiang, Qiang and Roth, Stefan and Schindler, Konrad and Leal-Taixe, Laura},
journal={arXiv preprint arXiv:2003.09003},
year={2020}
}
5. Original YOLO Paper
@inproceedings{redmon2016you,
title={You Only Look Once: Unified, Real-Time Object Detection},
author={Redmon, Joseph and Divvala, Santosh and Girshick, Ross and Farhadi, Ali},
booktitle={Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition},
pages={779--788},
year={2016}
}
π License
This repository declares the Apache-2.0 license in its metadata. Ensure that the repository includes a compatible LICENSE file and that the model weights and datasets are distributed in accordance with their respective licenses and terms.
π©βπ» Author
Rokayya Aly Hosny Ahmed
Hugging Face model repository:
https://huggingface.co/Rokayya/Crowd_Tracking_yolo26s_detector '''
Set this to your repository directory.
If running inside the repository, Path.cwd() is sufficient.
REPOSITORY_DIR = Path.cwd()
readme_path = REPOSITORY_DIR / "README.md" readme_path.write_text(readme_content, encoding="utf-8")
print(f"README.md created successfully at:\n{readme_path.resolve()}") print(f"File size: {readme_path.stat().st_size:,} bytes")