Ultralytics YOLOv5
æŠèŠ
YOLOv5uã¯ãç©äœæ€åºææ³ã®é²æ©ã象城ããŠãããYOLOv5uã¯ãã YOLOv5YOLOv5uã¯ãUltralytics ã«ãã£ãŠéçºãããã¢ãã«ã®åºæ¬çãªã¢ãŒããã¯ãã£ãŒããçãŸãããã®ã§ãã¢ã³ã«ãŒããªãŒãç©äœãããããªãŒã®ã¹ããªããããããçµ±åããŠããã YOLOv8ã¢ãã«ã«å°å ¥ãããŠããæ©èœã§ããããã®é©å¿ã«ããã¢ãã«ã®ã¢ãŒããã¯ãã£ãæ¹è¯ãããç©äœæ€åºã¿ã¹ã¯ã«ããã粟床ãšé床ã®ãã¬ãŒããªããæ¹åããããYOLOv5uã¯ãçµéšçãªçµæãšãã®å°åºãããç¹åŸŽãããç 究ãšå®çšçãªå¿çšã®äž¡æ¹ã«ãããŠãé å¥ãªè§£æ±ºçãæ±ãã人ã ã«å¹ççãªä»£æ¿æ¡ãæäŸããã
äž»ãªç¹åŸŽ
-
ã¢ã³ã«ãŒããªãŒã®ã¹ããªããUltralytics ãããïŒåŸæ¥ã®ãªããžã§ã¯ãæ€åºã¢ãã«ã¯ããªããžã§ã¯ãã®äœçœ®ãäºæž¬ããããã«ããããããå®çŸ©ãããã¢ã³ã«ãŒããã¯ã¹ã«äŸåããŠãããããããYOLOv5uã¯ãã®ã¢ãããŒããè¿ä»£åãããã¢ã³ã«ãŒããªãŒã®ã¹ããªããUltralytics ããããæ¡çšããããšã§ãããæè»ã§é©å¿çãªæ€åºã¡ã«ããºã ãä¿èšŒãããã®çµæãå€æ§ãªã·ããªãªã«ãããæ§èœãåäžãããã
-
æé©åããã粟床ãšã¹ããŒãã®ãã¬ãŒããªãïŒã¹ããŒããšç²ŸåºŠã¯ããã°ãã°çžåããæ¹åã«åŒã£åŒµããããããããYOLOv5uã¯ãã®ãã¬ãŒããªãã«ææŠããŸããYOLOv5uã¯èª¿æŽããããã©ã³ã¹ãæäŸãã粟床ã«åŠ¥åããããšãªããªã¢ã«ã¿ã€ã ã®æ€åºãä¿èšŒããŸãããã®æ©èœã¯ãèªåŸèµ°è¡è»ãããããå·¥åŠããªã¢ã«ã¿ã€ã ãããªè§£æãªã©ãè¿ éãªå¿çãæ±ããããã¢ããªã±ãŒã·ã§ã³ã§ã¯ç¹ã«è²Žéã§ãã
-
å€æ§ãªäºååŠç¿æžã¿ã¢ãã«ã¿ã¹ã¯ã«ãã£ãŠå¿ èŠãšãããããŒã«ã»ãããç°ãªãããšãç解ããYOLOv5uã¯å€ãã®ãã¬ãŒãã³ã°æžã¿ã¢ãã«ãæäŸããŠããŸããæšè«ãæ€èšŒããã¬ãŒãã³ã°ã®ãããã«éç¹ã眮ããŠããŠãããªãŒããŒã¡ã€ãã®ã¢ãã«ãããªããåŸ ã£ãŠããŸãããã®å€æ§æ§ã«ãããäžèœãªãœãªã¥ãŒã·ã§ã³ã§ã¯ãªããããªãã®ãŠããŒã¯ãªèª²é¡ã«å¯ŸããŠç¹å¥ã«åŸ®èª¿æŽãããã¢ãã«ã䜿çšããããšãã§ããŸãã
ãµããŒããããã¿ã¹ã¯ãšã¢ãŒã
YOLOv5uã¢ãã«ã¯ãæ§ã ãªäºååŠç¿æžã¿ã®éã¿ãæã¡ãç©äœæ€åºã¿ã¹ã¯ã«åªããŠããŸããå¹ åºãã¢ãŒãããµããŒãããŠãããããéçºããé åãŸã§ãããŸããŸãªçšéã«é©ããŠããŸãã
ã¢ãã«ã¿ã€ã | äºåã«èšç·ŽããããŠã§ã€ã | ã¿ã¹ã¯ | æšè« | ããªããŒã·ã§ã³ | ãã¬ãŒãã³ã° | èŒžåº |
---|---|---|---|---|---|---|
YOLOv5u | yolov5nu , yolov5su , yolov5mu , yolov5lu , yolov5xu , yolov5n6u , yolov5s6u , yolov5m6u , yolov5l6u , yolov5x6u |
ç©äœæ€åº | â | â | â | â |
ãã®è¡šã¯ãYOLOv5uã¢ãã«ããªã¢ã³ãã®è©³çŽ°ãªæŠèŠã瀺ããŠãããç©äœæ€åºã¿ã¹ã¯ã«ãããé©çšå¯èœæ§ãšãæšè«ãæ€èšŒããã¬ãŒãã³ã°ããšã¯ã¹ããŒããšãã£ãæ§ã ãªæäœã¢ãŒãã®ãµããŒãã匷調ããŠããŸãããã®å æ¬çãªãµããŒãã«ããããŠãŒã¶ãŒã¯å¹ åºãç©äœæ€åºã·ããªãªã§YOLOv5uã¢ãã«ã®æ©èœããã«ã«æŽ»çšããããšãã§ããŸãã
ããã©ãŒãã³ã¹ææš
ããã©ãŒãã³ã¹
80ã®èšç·Žæžã¿ã¯ã©ã¹ãå«ãCOCOäžã§èšç·Žããããããã®ã¢ãã«ã®äœ¿çšäŸã«ã€ããŠã¯ãDetection Docsãåç §ããŠãã ããã
ã¢ãã« | ã€ã ã« | ãµã€ãº (ãã¯ã»ã«) |
mAPval 50-95 |
é床 CPU ONNX (ms) |
é床 A100 TensorRT (ms) |
params (M) |
FLOPs (B) |
---|---|---|---|---|---|---|---|
yolov5nu.pt | yolov5n.yaml | 640 | 34.3 | 73.6 | 1.06 | 2.6 | 7.7 |
yolov5su.pt | yolov5s.yaml | 640 | 43.0 | 120.7 | 1.27 | 9.1 | 24.0 |
yolov5mu.pt | yolov5m.yaml | 640 | 49.0 | 233.9 | 1.86 | 25.1 | 64.2 |
yolov5lu.pt | yolov5l.yaml | 640 | 52.2 | 408.4 | 2.50 | 53.2 | 135.0 |
yolov5xu.pt | yolov5x.yaml | 640 | 53.2 | 763.2 | 3.81 | 97.2 | 246.4 |
yolov5n6u.pt | yolov5n6.yaml | 1280 | 42.1 | 211.0 | 1.83 | 4.3 | 7.8 |
yolov5s6u.pt | yolov5s6.yaml | 1280 | 48.6 | 422.6 | 2.34 | 15.3 | 24.6 |
yolov5m6u.pt | yolov5m6.yaml | 1280 | 53.6 | 810.9 | 4.36 | 41.2 | 65.7 |
yolov5l6u.pt | yolov5l6.yaml | 1280 | 55.7 | 1470.9 | 5.47 | 86.1 | 137.4 |
yolov5x6u.pt | yolov5x6.yaml | 1280 | 56.8 | 2436.5 | 8.98 | 155.4 | 250.7 |
䜿çšäŸ
ãã®äŸã§ã¯ãåçŽãªYOLOv5 ãã¬ãŒãã³ã°ãšæšè«ã®äŸãæäŸããŸãããããã®ã¢ãŒããä»ã®ã¢ãŒãã«é¢ããå®å šãªããã¥ã¡ã³ãã¯Predict,Train,ValandExportdocs ããŒãžãåç §ããŠãã ããã
äŸ
PyTorch ãã
ããããã *.pt
ã¢ãã«ããã³æ§æ *.yaml
ãã¡ã€ã«ã«æž¡ãããšãã§ããã YOLO()
ã¯ã©ã¹ã䜿çšããŠãpython ã«ã¢ãã«ã®ã€ã³ã¹ã¿ã³ã¹ãäœæããŸãïŒ
from ultralytics import YOLO
# Load a COCO-pretrained YOLOv5n model
model = YOLO("yolov5n.pt")
# Display model information (optional)
model.info()
# Train the model on the COCO8 example dataset for 100 epochs
results = model.train(data="coco8.yaml", epochs=100, imgsz=640)
# Run inference with the YOLOv5n model on the 'bus.jpg' image
results = model("path/to/bus.jpg")
CLI ã³ãã³ãã§ã¢ãã«ãçŽæ¥å®è¡ã§ããïŒ
åŒçšãšè¬èŸ
Ultralytics YOLOv5 åºç
Ultralytics ã¯ãæ¥éã«é²åããã¢ãã«ã®æ§è³ªäžãYOLOv5 ã®æ£åŒãªç 究è«æãçºè¡šããŠããªããç§ãã¡ã¯ãéçãªããã¥ã¡ã³ããäœæããããããæè¡ãé²æ©ããã䜿ããããããããšã«éç¹ã眮ããŠããŸããYOLO ã®ã¢ãŒããã¯ãã£ãæ©èœã䜿çšæ¹æ³ã«é¢ããææ°æ å ±ã«ã€ããŠã¯ãGitHub ãªããžããªãš ããã¥ã¡ã³ããåç §ããŠãã ããã
ããªãã®ç 究ã§YOLOv5 ãŸã㯠YOLOv5u ã䜿çšããå Žåã¯ãUltralytics YOLOv5 ãªããžããªã以äžã®ããã«åŒçšããŠãã ããïŒ
YOLOv5 ã¢ãã«ã¯ AGPL-3.0ããã³Enterpriseã©ã€ã»ã³ã¹ã§æäŸãããŸãã
ããããã質å
Ultralytics YOLOv5uãšã¯äœã§ããïŒãŸããYOLOv5 ãšã®éãã¯äœã§ããïŒ
Ultralytics YOLOv5uã¯ãYOLOv5 ã®é²åçã§ãããã¢ã³ã«ãŒããªãŒããªããžã§ã¯ããã¹ããªãŒã®ã¹ããªããããããçµ±åãããªã¢ã«ã¿ã€ã ã®ãªããžã§ã¯ãæ€åºã¿ã¹ã¯ã®ç²ŸåºŠãšé床ã®ãã¬ãŒããªãã匷åãããåŸæ¥ã®YOLOv5 ãšç°ãªããYOLOv5uã¯ã¢ã³ã«ãŒããªãŒã®æ€åºã¡ã«ããºã ãæ¡çšããããæè»ã§å€æ§ãªã·ããªãªã«é©å¿ããŸããYOLOv5uã®ç¹åŸŽã®è©³çŽ°ã«ã€ããŠã¯ãYOLOv5 æŠèŠããåç §ãã ããã
YOLOv5uã«ãããŠãã¢ã³ã«ãŒã䜿ããªãUltralytics ãããã¯ã©ã®ããã«ç©äœæ€åºæ§èœãåäžãããŠããã®ãïŒ
YOLOv5uã®ã¢ã³ã«ãŒããªãŒUltralytics ãããã¯ããããããå®çŸ©ãããã¢ã³ã«ãŒããã¯ã¹ãžã®äŸåãæé€ããããšã§ãç©äœæ€åºæ§èœãåäžãããŸãããã®çµæãããæè»ã§é©å¿æ§ã®é«ãæ€åºã¡ã«ããºã ãå®çŸããããŸããŸãªãµã€ãºã圢ç¶ã®ç©äœãããå¹ççã«æ±ãããšãã§ããããã®åŒ·åã¯ã粟床ãšé床ã®ãã©ã³ã¹ã®åãããã¬ãŒããªãã«çŽæ¥è²¢ç®ããYOLOv5uããªã¢ã«ã¿ã€ã ã»ã¢ããªã±ãŒã·ã§ã³ã«é©ããŠããŸããYOLOv5uã®ã¢ãŒããã¯ãã£ã«ã€ããŠã¯ããäž»ãªç¹é·ããã芧ãã ããã
ãã¬ãŒãã³ã°æžã¿ã®YOLOv5uã¢ãã«ãç°ãªãã¿ã¹ã¯ãã¢ãŒãã«äœ¿çšã§ããŸããïŒ
ã¯ãããªããžã§ã¯ãæ€åºãªã©ã®æ§ã ãªã¿ã¹ã¯ã«ãäºåã«ãã¬ãŒãã³ã°ãããYOLOv5uã¢ãã«ã䜿çšããããšãã§ããŸãããããã®ã¢ãã«ã¯ãæšè«ãæ€èšŒããã¬ãŒãã³ã°ããšã¯ã¹ããŒããªã©ã®è€æ°ã®ã¢ãŒãããµããŒãããŠããŸãããã®æè»æ§ã«ããããŠãŒã¶ãŒã¯ããŸããŸãªéçšèŠä»¶ã§YOLOv5uã¢ãã«ã®æ©èœã掻çšããããšãã§ããŸãã詳现ãªæŠèŠã«ã€ããŠã¯ãããµããŒããããã¿ã¹ã¯ãšã¢ãŒããã®ã»ã¯ã·ã§ã³ãã芧ãã ããã
YOLOv5uã¢ãã«ã®ããã©ãŒãã³ã¹ææšã¯ãç°ãªããã©ãããã©ãŒã ã§ã©ã®ããã«æ¯èŒãããŸããïŒ
YOLOv5uã¢ãã«ã®æ§èœææšã¯ã䜿çšãããã©ãããã©ãŒã ãããŒããŠã§ã¢ã«ãã£ãŠç°ãªããäŸãã°ãYOLOv5nuã¢ãã«ã¯ãCOCOããŒã¿ã»ããã§34.3mAPãéæããCPU (ONNX)ã§ã¯73.6msãA100TensorRT ã§ã¯1.06msã®é床ã§ãããããŸããŸãªYOLOv5uã¢ãã«ã®è©³çŽ°ãªæ§èœææšã¯ãæ§èœææšã®ã»ã¯ã·ã§ã³ã§èŠãããšãã§ããŸãã
Ultralytics Python APIã䜿çšããŠYOLOv5uã¢ãã«ããã¬ãŒãã³ã°ããã«ã¯ã©ãããã°ããã§ããïŒ
YOLOv5uã¢ãã«ããã¬ãŒãã³ã°ããã«ã¯ãäºåã«ãã¬ãŒãã³ã°ãããã¢ãã«ãããŒãããããªãã®ããŒã¿ã»ããã§ãã¬ãŒãã³ã°ã³ãã³ããå®è¡ããŸããç°¡åãªäŸãæãããïŒ
äŸ
ãã詳ãã説æã¯ã䜿çšäŸã®ã»ã¯ã·ã§ã³ãã芧ãã ããã