Views
No views yet
| Metric | Value |
|---|---|
| mAP@0.5 | 97.63% |
| mAP@0.5:0.95 | 89.56% |
| Precision | 95.2% |
| Recall | 94.8% |
| Processing Time (CPU) | ~100ms per image |
pip install ultralytics1from ultralytics import YOLO
2import cv2
3
4# Load the model
5model = YOLO('best.pt')
6
7# Run inference
8results = model('path/to/image.jpg')
9
10# Process results
11for result in results:
12 boxes = result.boxes
13 for box in boxes:
14 # Get coordinates and confidence
15 x1, y1, x2, y2 = box.xyxy[0].cpu().numpy()
16 confidence = box.conf[0].cpu().numpy()
17
18 print(f"Beetle detected with confidence: {confidence:.2f}")
19 print(f"Bounding box: ({x1}, {y1}, {x2}, {y2})")yolo predict model=best.pt source='path/to/image.jpg'best.pt: PyTorch model weights (recommended)best.onnx: ONNX format for cross-platform deployment1@model{beetle-detection-yolov8,
2 title={YOLOv8 Beetle Detection Model},
3 author={Insect Detection Training Project},
4 year={2025},
5 url={https://huggingface.co/Murasan/beetle-detection-yolov8}
6}