Downloads · 30 days
0
prath0029/Zerodefect-1.0-bucket
Zerodefect-1.0-bucket is a object detection model from prath0029. Use it when you need objects located in an image. The card lists the license as mit.
[](https://python.org) [](https://pytorch.org) [](https://onnx.ai) [](LICENSE)
Downloads · 30 days
0
Access
Public
Updated Jul 18, 2026
Parameters
1.8M
22.9 MB on disk
Likes
0
Public
Click a slice to open those files.
.onnx7.5 MB · 39%
From the Hugging Face model README
A YOLOv5 Nano object detection model trained on a class-balanced merged dataset of aircraft skin and automotive component defects. This is version 2.0 of the ZeroDefect model, trained with:
| ID | Class | Description |
|---|---|---|
| 0 | crack | Structural cracks, fatigue lines, stress fractures |
| 1 | dent | Impact dents, surface deformations |
| 2 | corrosion | Rust, chemical wear, oxidation spots |
| 3 | scratch | Superficial scrapes, paint scratches |
| 4 | paint-peel | Flaking paint, coating degradation |
| 5 | missing-head | Missing rivet heads or fasteners |
| 6 | defect | Generic surface anomalies |
| Run | Epochs | [email protected] | [email protected]:0.95 | Precision | Recall |
|---|---|---|---|---|---|
| Balanced v2.0 (this repo, best epoch=101) | 150 | 0.30994 | 0.22613 | 0.37777 | 0.34799 |
| Nano v1.0 (baseline, epoch 149) | 150 | 0.31962 | 0.23492 | 0.42944 | 0.35807 |
Note: The class-balanced v2.0 run achieves comparable mAP scores to the nano v1.0 baseline while training on a harder, class-balanced dataset. The lower absolute mAP reflects that the dataset had its class distribution enforced (harder to overfit to the dominant "defect" class), resulting in more balanced per-class detection capability.
| File | Description | Size |
|---|---|---|
best.pt | PyTorch model weights (YOLOv5 format) | ~3.8 MB |
best_balanced.onnx | ONNX export (opset 18, simplified) | ~7.5 MB |
best.rknn | RKNN binary for RV1106 NPU (INT8, prior run) | ~2.6 MB |
data.yaml | Dataset configuration | <1 KB |
infer_onnx.py | Python ONNX inference helper | ~8 KB |
evaluation/ | Training curves, confusion matrix, PR/F1 plots | — |
pip install onnxruntime opencv-python numpy
python infer_onnx.py --model best_balanced.onnx --image test.jpg --conf 0.25
The best.rknn model is compiled for the RV1106 NPU (INT8 quantized):
# Push model to the board
adb push best.rknn /userdata/
# Build C++ inference runner from rknn_model_zoo
./build-linux.sh -t rv1106 -a armv7l -d yolov5
# Run inference on board
./rknn_yolov5_demo /userdata/best.rknn test.jpg
Released under the MIT License. See LICENSE for details.