yolov5
Packaged version of the Yolov5 object detector
What it is and what it does
YOLOv5 is a packaged wrapper around the Ultralytics YOLOv5 object detector, providing pip-installable access to a production-grade real-time detection model. It detects and localizes objects in images, video streams, and webcam feeds, returning bounding boxes, confidence scores, and class predictions. The package includes training and fine-tuning workflows for custom datasets, model export to multiple formats (ONNX, TorchScript, CoreML, TensorFlow Lite), and a CLI for common tasks.
The package depends on PyTorch, OpenCV, NumPy, and a suite of data-handling and visualization libraries. It integrates with Hugging Face Hub for model sharing, Roboflow for dataset management, and AWS S3 for artifact storage. Training supports COCO-format datasets and Neptune.AI logging. The primary use case is building and deploying object detection pipelines without managing the underlying YOLOv5 repository directly.
Use it for:
- Run inference on images or video to detect and locate objects in real time.
- Fine-tune a pre-trained YOLOv5 model on a custom dataset for domain-specific detection tasks.
- Export a trained model to ONNX, TorchScript, or TensorFlow Lite for deployment on edge devices.
- Stream detections from a webcam or RTSP/RTMP source and save annotated results.
- Integrate object detection into a larger ML pipeline via Python API or CLI commands.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
YOLOv5 is a packaged object detection model that runs inference on images and video to identify and localize objects, with integrated training, validation, export, and CLI support.
Yes, with conditions. YOLOv5 is actively maintained, production-stable, and has no known vulnerabilities. Install friction is low, but the 23 runtime dependencies—especially torch and torchvision—are heavy; ensure your environment can accommodate them and that GPU support is available if you need inference speed. GPL copyleft licensing requires compliance in derivative works. Suitable for research, prototyping, and applications where GPL terms are acceptable.
Install
yolov5 on PyPI
pip
pip install yolov5uv
uv add yolov5poetry
poetry add yolov5Installing yolov5
Before you install
Low install friction with a pure-Python wheel. Active maintenance as of 2026-03-20. However, 23 runtime dependencies including torch, torchvision, and opencv-python are heavy; actual installation time and disk footprint will depend on whether these are already present.
License in practice
Licensed under GPL (copyleft). Derivative works and modifications must be distributed under the same license terms; proprietary applications using this package must comply with GPL obligations or obtain an alternative license.
Quickstart
pip install yolov5
import yolov5
model = yolov5.load('yolov5s.pt')
results = model('https://github.com/ultralytics/yolov5/raw/master/data/images/zidane.jpg')
results.show()
Requires Python >=3.7. torch and torchvision must be installed; GPU support optional but recommended for inference speed.
Verify before relying
- Whether pre-trained model weights are downloaded on first load or must be manually staged.
- Memory and compute requirements for different model sizes (yolov5s, yolov5m, yolov5l, yolov5x).
- Performance on edge devices or CPU-only environments.
Package facts
| License | GPL (copyleft) |
| Python support | supports the current Python release (>=3.7) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 23 — gitpython, matplotlib, numpy, opencv-python, Pillow, psutil, PyYAML, requests, scipy, thop, torch, torchvision, tqdm, ultralytics, tensorboard, pandas, seaborn, setuptools, fire, boto3, sahi, huggingface-hub, roboflow |
| Maintenance | actively maintained — 641 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 241,766/month — #8,870 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: yolov5-7.0.14-py37.py38.py39.py310-none-any.whl
Keywords: machine-learning, deep-learning, ml, pytorch, YOLO, object-detection, vision, YOLOv5, YOLOv7
Tags
More Libraries packages
urllib3 is an HTTP client library that provides…
permissive · top 100 on PyPI
requestsRequests is a Python HTTP library that…
permissive · top 100 on PyPI
pluggyPluggy provides a plugin system that lets you…
permissive · top 100 on PyPI
python-dateutilProvides parsing, arithmetic, and recurrence…
permissive · top 100 on PyPI
sixSix provides utility functions to write Python…
permissive · top 100 on PyPI
pytestpytest is a testing framework that lets you…
permissive · top 100 on PyPI
ultralyticsUltralytics YOLO provides a unified framework…
agpl · top 5,000 on PyPI
roboflowRoboflow is a Python client for the Roboflow…
permissive · top 5,000 on PyPI
inference-cliA command-line tool for running computer vision…
permissive · top 15,000 on PyPI
inference-modelsLoads and runs computer vision models from…
unclear · top 15,000 on PyPI
boxmotBoxMOT provides pluggable multi-object tracking…
agpl · top 15,000 on PyPI
qrdetDetects and segments QR codes in images using a…
permissive · top 15,000 on PyPI
groundingdino-pyGrounding DINO is an open-set object detector…
permissive · top 15,000 on PyPI
norfairNorfair adds real-time multi-object tracking to…
permissive · top 15,000 on PyPI
inference-sdkPython SDK for connecting to and running…
permissive · top 15,000 on PyPI
sahiSAHI performs sliced inference on large images…
permissive · top 15,000 on PyPI