Add model card for yolo26_classify
Browse files
README.md
ADDED
|
@@ -0,0 +1,86 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
library_name: onnx
|
| 3 |
+
license: agpl-3.0
|
| 4 |
+
tags:
|
| 5 |
+
- foundation
|
| 6 |
+
- amd
|
| 7 |
+
- rocm
|
| 8 |
+
- image-classification
|
| 9 |
+
pipeline_tag: image-classification
|
| 10 |
+
---
|
| 11 |
+
|
| 12 |
+

|
| 13 |
+
|
| 14 |
+
# YOLO26-cls: Optimized for AMD ROCm
|
| 15 |
+
|
| 16 |
+
YOLO26-cls is a real-time image classification model that predicts a class over the 1000 ImageNet categories in a single forward pass. This repository packages inference for image classification using **ONNX Runtime**, exported and validated for **AMD ROCm** so it runs efficiently on AMD GPUs, CPUs, and NPUs.
|
| 17 |
+
|
| 18 |
+
This is based on the implementation of YOLO26 found [here](https://github.com/ultralytics/ultralytics).
|
| 19 |
+
This repository contains configurations and scripts optimized for **AMD® ROCm™** platforms. You can use the [yolo26_classify AMD scripts](https://github.com/AMD-PAVS/physical_ai_sdk/blob/main/models/yolo26_classify) to reproduce results or export with custom configurations. More details on model performance can be found [here](#accuracy-pipeline).
|
| 20 |
+
|
| 21 |
+
---
|
| 22 |
+
|
| 23 |
+
## Task Overview
|
| 24 |
+
|
| 25 |
+
**Task:** Image classification
|
| 26 |
+
|
| 27 |
+
**Dataset:** ImageNet-1000 label space (a sample set — the imagenette subset — is staged under `datasets/samples/` for visual evaluation)
|
| 28 |
+
|
| 29 |
+
**Output metrics:** Throughput (inferences/sec), latency (mean/P95/P99 ms), per-operator profiling breakdown
|
| 30 |
+
|
| 31 |
+
> **Model variants:** Default is **n** (nano). Override with `MODEL_SIZE=n/s/m/l/x` — note the classify download list ships `n/s/m/l` weights only, so `MODEL_SIZE=x` may not resolve to a hosted weight.
|
| 32 |
+
|
| 33 |
+
---
|
| 34 |
+
|
| 35 |
+
## AMD ROCm Optimization
|
| 36 |
+
|
| 37 |
+
This model export has been adapted and validated for **AMD Instinct™ / Radeon™ GPUs** running **ROCm**, as well as AMD CPUs and AMD Ryzen AI NPUs. Key points:
|
| 38 |
+
|
| 39 |
+
- Validated backends: **ONNX Runtime** across CPU (FP32), GPU (MIGraphX Execution Provider — FP32/FP16/BF16/INT8), and NPU (VitisAI Execution Provider — BF16).
|
| 40 |
+
- No code changes required versus the upstream Ultralytics YOLO26-cls implementation — only environment/runtime configuration differs.
|
| 41 |
+
|
| 42 |
+
| Runtime | Precision | Backend | Hardware | Notes |
|
| 43 |
+
|---|---|---|---|---|
|
| 44 |
+
| ONNX Runtime | FP32 | CPU Execution Provider | AMD CPU | — |
|
| 45 |
+
| ONNX Runtime | FP32 / FP16 / BF16 / INT8 | MIGraphX Execution Provider | AMD Instinct™ / Radeon™ GPU (ROCm) | — |
|
| 46 |
+
| ONNX Runtime | BF16 | VitisAI Execution Provider | AMD Ryzen AI NPU | — |
|
| 47 |
+
|
| 48 |
+
---
|
| 49 |
+
|
| 50 |
+
## Getting Started
|
| 51 |
+
|
| 52 |
+
For setup instructions, evaluation scripts, and custom configuration options, see the [yolo26_classify on GitHub](https://github.com/AMD-PAVS/physical_ai_sdk/blob/main/models/yolo26_classify).
|
| 53 |
+
|
| 54 |
+
---
|
| 55 |
+
|
| 56 |
+
## Model Details
|
| 57 |
+
|
| 58 |
+
**Model Type:** Image classification (single-pass CNN classifier)
|
| 59 |
+
|
| 60 |
+
**Base Model:** YOLO26-cls (Ultralytics), size `n` (nano) default
|
| 61 |
+
|
| 62 |
+
**Model Stats:**
|
| 63 |
+
- Input (`images`): `(1, 3, 224, 224)` float32
|
| 64 |
+
- Output (`output0`): `(1, 1000)` float32
|
| 65 |
+
- Model sizes: `n/s/m/l` ship pretrained classify weights (`x` may not resolve to a hosted weight)
|
| 66 |
+
- Precision tested: FP32 (CPU); FP32, FP16, BF16, INT8 (GPU); BF16 (NPU)
|
| 67 |
+
|
| 68 |
+
---
|
| 69 |
+
|
| 70 |
+
## Accuracy Pipeline
|
| 71 |
+
|
| 72 |
+
Accuracy evaluation is not yet implemented for this model. The bundled imagenette subset (10 ImageNet classes, staged under `datasets/samples/`) is used only for visual top-5 sanity checks via annotated overlays, not full ImageNet-1000 accuracy scoring.
|
| 73 |
+
|
| 74 |
+
---
|
| 75 |
+
|
| 76 |
+
## Dig Deeper
|
| 77 |
+
|
| 78 |
+
Want to explore the full evaluation scripts, config options, and other AMD-optimized model examples?
|
| 79 |
+
|
| 80 |
+
📂 **[View the full project on GitHub](https://github.com/AMD-PAVS/physical_ai_sdk/blob/main/models/yolo26_classify)**
|
| 81 |
+
|
| 82 |
+
The GitHub repository includes:
|
| 83 |
+
- Setup and prerequisites for ROCm environments
|
| 84 |
+
- Per-operator latency profiling scripts (including NPU AI Analyzer integration)
|
| 85 |
+
- Sample-image evaluation with annotated top-5 class overlays
|
| 86 |
+
- Benchmarking and reproduction instructions across CPU, GPU, and NPU
|