Documentation
See the YOLOv5 Docs for full documentation on training, testing and deployment.
Quick Start Examples
InstallPython>=3.6.0 is required with all requirements.txt installed including PyTorch>=1.7:
$ git clone https://github.com/ultralytics/yolov5 $ cd yolov5 $ pip install -r requirements.txt Inference
Inference with YOLOv5 and PyTorch Hub. Models automatically download from the latest YOLOv5 release.
import torch # Model model = torch.hub.load('ultralytics/yolov5', 'yolov5s') # or yolov5m, yolov5l, yolov5x, custom # Images img = 'https://ultralytics.com/images/zidane.jpg' # or file, Path, PIL, OpenCV, numpy, list # Inference results = model(img) # Results results.print() # or .show(), .save(), .crop(), .pandas(), etc. Inference with detect.py
detect.py runs inference on a variety of sources, downloading models automatically from the latest YOLOv5 release and saving results to runs/detect.
$ python detect.py --source 0 # webcam img.jpg # image vid.mp4 # video path/ # directory path/*.jpg # glob 'https://youtu.be/Zgi9g1ksQHc' # YouTube 'rtsp://example.com/media.mp4' # RTSP, RTMP, HTTP stream Training
Run commands below to reproduce results on COCO dataset (dataset auto-downloads on first use). Training times for YOLOv5s/m/l/x are 2/4/6/8 days on a single V100 (multi-GPU times faster). Use the largest --batch-size your GPU allows (batch sizes shown for 16 GB devices).
$ python train.py --data coco.yaml --cfg yolov5s.yaml --weights '' --batch-size 64 yolov5m 40 yolov5l 24 yolov5x 16 Tutorials Train Custom Data ð RECOMMENDED Tips for Best Training Results âï¸ RECOMMENDED Weights & Biases Logging ð NEW Roboflow for Datasets, Labeling, and Active Learning ð NEW Multi-GPU Training PyTorch Hub â NEW TFLite, ONNX, CoreML, TensorRT Export ð Test-Time Augmentation (TTA) Model Ensembling Model Pruning/Sparsity Hyperparameter Evolution Transfer Learning with Frozen Layers â NEW TensorRT Deployment
Environments
Get started in seconds with our verified environments. Click each icon below for details.
相关知识
深度学习花朵识别系统:yolov5源码与海棠花数据集解析
探索自然之美:基于Yolov5的海棠花花朵检测识别项目
Python基于改进YOLOv5的烟叶病害检测系统(附带源码)
基于yolov5的海棠花花朵检测识别
基于改进YOLOv5的猕猴桃叶病害检测系统(完整源码&数据集&视频教程)
基于YOLOv5深度学习的植物病害检测系统:YOLOv5 + 数据集 + UI界面
基于深度学习YOLOv8\YOLOv5的花卉识别鲜花识别检测分类系统设计
复古花卉背景的温馨妇女节PPT模板.zip资源
鲜花销售管理系统.zip
[智慧农业]Python基于改进YOLOv5的猕猴桃叶病害检测系统(完整源码&数据集&视频教程)
网址: 基于yolov5的海棠花花朵识别检测系统源码+数据集+实验报告.zip https://m.huajiangbk.com/newsview737357.html
上一篇: 牡丹花开惹人“醉” |
下一篇: 使用CNN或resnet,分别在 |