Ephraimmm commited on
Commit
602aab4
Β·
verified Β·
1 Parent(s): add06c5

Improve model card with professional documentation

Browse files
Files changed (1) hide show
  1. README.md +106 -0
README.md ADDED
@@ -0,0 +1,106 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: agpl-3.0
3
+ tags:
4
+ - object-detection
5
+ - yolo
6
+ - yolo26
7
+ - ultralytics
8
+ - pytorch
9
+ - computer-vision
10
+ - coco
11
+ pipeline_tag: object-detection
12
+ ---
13
+
14
+ # YOLO26n Object Detector (COCO, 80 classes)
15
+
16
+ ## Overview
17
+
18
+ This repository contains a YOLO26n (nano-scale) object detection checkpoint, trained with the [Ultralytics](https://github.com/ultralytics/ultralytics) framework (v8.4.14) to detect the 80 standard COCO object categories β€” everyday items such as people, vehicles, animals, furniture, and food. It is a lightweight, general-purpose detector suitable for fast inference on images or video.
19
+
20
+ All facts below were extracted directly from the checkpoint's embedded metadata (`train_args`, `train_metrics`, `train_results`, and `model.names`) β€” no external logs or claims are assumed beyond what is stored in the file itself.
21
+
22
+ ## Classes
23
+
24
+ The model detects the 80 standard COCO classes (read from the checkpoint's `model.names`):
25
+
26
+ `airplane, apple, backpack, banana, baseball bat, baseball glove, bear, bed, bench, bicycle, bird, boat, book, bottle, bowl, broccoli, bus, cake, car, carrot, cat, cell phone, chair, clock, couch, cow, cup, dining table, dog, donut, elephant, fire hydrant, fork, frisbee, giraffe, hair drier, handbag, horse, hot dog, keyboard, kite, knife, laptop, microwave, motorcycle, mouse, orange, oven, parking meter, person, pizza, potted plant, refrigerator, remote, sandwich, scissors, sheep, sink, skateboard, skis, snowboard, spoon, sports ball, stop sign, suitcase, surfboard, teddy bear, tennis racket, tie, toaster, toilet, toothbrush, traffic light, train, truck, tv, umbrella, vase, wine glass, zebra`
27
+
28
+ ## Training Details
29
+
30
+ All values below are read directly from the checkpoint's saved `train_args`, `train_results`, and `train_metrics`:
31
+
32
+ | Item | Value |
33
+ |---|---|
34
+ | Architecture | YOLO26n ("nano" scale, `yolo26n.yaml`) |
35
+ | Base/pretrained weights | `yolo26n.pt` (Ultralytics COCO-pretrained checkpoint) |
36
+ | Framework | Ultralytics `8.4.14` |
37
+ | Parameters | ~2.57M |
38
+ | Training data | COCO-format dataset (`dataset.yaml`, 80 classes) |
39
+ | Epochs | 10 |
40
+ | Batch size | 16 |
41
+ | Image size | 640 x 640 |
42
+ | Optimizer | auto-selected by Ultralytics (`lr0=0.001`, momentum `0.937`, weight decay `0.0005`) |
43
+ | Mixed precision | enabled (AMP) |
44
+ | Hardware | single GPU (trained on Google Colab, inferred from the dataset path `/content/coco_yolo/...`) |
45
+ | Training date | 2026-02-19 (per checkpoint metadata) |
46
+
47
+ ### Final logged validation metrics (epoch 10)
48
+
49
+ These are the exact values stored in the checkpoint's `train_metrics` after the last training epoch β€” not independently re-verified:
50
+
51
+ | Metric | Value |
52
+ |---|---|
53
+ | Precision (B) | 0.676 |
54
+ | Recall (B) | 0.516 |
55
+ | mAP@0.5 (B) | 0.573 |
56
+ | mAP@0.5:0.95 (B) | 0.412 |
57
+ | Val box loss | 1.346 |
58
+ | Val cls loss | 1.400 |
59
+ | Val dfl loss | 0.011 |
60
+
61
+ ## Intended Use
62
+
63
+ - General-purpose object detection prototyping across common household, outdoor, and everyday-object scenes covered by the 80 COCO categories.
64
+ - A lightweight baseline for benchmarking or comparing against other YOLO variants (nano scale, ~2.57M parameters β€” optimized for speed over accuracy).
65
+ - Educational/demo use for learning the Ultralytics YOLO training and inference workflow.
66
+
67
+ Not intended for safety-critical, medical, or high-stakes decision-making applications.
68
+
69
+ ## How to Use
70
+
71
+ This checkpoint is a native **Ultralytics** `.pt` file (not a `transformers`-format model β€” there is no `config.json` or `preprocessor_config.json` in this repo). Load it with the `ultralytics` package:
72
+
73
+ ```bash
74
+ pip install ultralytics huggingface_hub
75
+ ```
76
+
77
+ ```python
78
+ from huggingface_hub import hf_hub_download
79
+ from ultralytics import YOLO
80
+
81
+ # Download the checkpoint from the Hub
82
+ weights_path = hf_hub_download(
83
+ repo_id="Ephraimmm/object_detection",
84
+ filename="best (1).pt",
85
+ )
86
+
87
+ # Load and run inference
88
+ model = YOLO(weights_path)
89
+ results = model("path/to/image.jpg")
90
+
91
+ results[0].show() # display predictions
92
+ results[0].save() # save annotated image
93
+ print(results[0].boxes) # bounding boxes, classes, confidences
94
+ ```
95
+
96
+ ## Limitations
97
+
98
+ - Trained for only 10 epochs β€” short relative to typical YOLO training recipes (often 100–300 epochs) β€” so accuracy is moderate (mAP@0.5:0.95 = 0.412) and likely below what longer training would achieve.
99
+ - Nano-scale architecture (~2.57M parameters) trades detection accuracy for speed and small model size; larger YOLO26 scales (s/m/l/x) would likely perform better but are slower and heavier.
100
+ - Metrics above come solely from the training run's own logged validation split; no independent third-party benchmark or held-out test set evaluation has been performed.
101
+ - Limited to the 80 COCO categories β€” objects outside this label set will not be detected or will be misclassified into the nearest known category.
102
+ - Licensed under AGPL-3.0 (per Ultralytics YOLO licensing) β€” review license terms before commercial or closed-source use.
103
+
104
+ ## Author
105
+
106
+ Developed by [Ephraimmm](https://huggingface.co/Ephraimmm)