| Model Type | File Name | Size (MB) | Use Case | | :--------- | :----------- | :-------- | :-------------------------------- | | Nano | yolov8n.pt | 6.2 | Mobile/Edge devices, speed first | | Small | yolov8s.pt | 21.4 | Balanced speed/accuracy | | Medium | yolov8m.pt | 49.6 | General purpose | | Large | yolov8l.pt | 83.7 | High accuracy, slower | | Extra-Large| yolov8x.pt | 130.5 | Maximum accuracy |
from ultralytics import YOLO import cv2 model = YOLO('yolov8n.pt') Run inference on a sample image results = model('https://ultralytics.com/images/bus.jpg') Display results for r in results: r.show() # Opens image window yolo v8 download
Execute the following Python code. The system will automatically fetch the default Nano model ( yolov8n.pt ): | Model Type | File Name | Size