NOTE: The Jupyter Notebook below is included in the Chimera SDK and can be run interactively by running the following CLI command:
$ quadric sdk notebook
From the Jupyter Notebook window in your browser, select the notebook named /quadric/sdk-cli/examples/models/yolo/yolov8/yolov8.ipynb.
YOLOv8 Object Detection on Chimera GPNPU
YOLOv8 is Ultralytics' 2023 anchor-free, single-stage detector. It drops the anchor-box machinery of YOLOv5/v7 in favour of a direct box regression, which shortens the head and simplifies the post-processing compared with earlier YOLO iterations. This notebook takes the pretrained yolov8n (nano) variant end-to-end: export to ONNX, split at the head boundary, quantize to INT8, compile the backbone with the Chimera Graph Compiler (CGC), and run ISS + ORT INT8 inferences side-by-side.
Why split the graph?
YOLOv8's head mixes operators that compile well to the Chimera GPNPU (the convolutional backbone) with operators that are cheaper to keep on the host (the classical NMS + box-decode postprocess). Splitting lets CGC spend its time on the backbone and lets ONNX Runtime handle the tail — each operator runs where it belongs.
Model: YOLOv8n (COCO, 640×640, 3.2M params, 8.7 GFLOPs)
Note — split pipeline.
- On the Chimera GPNPU: the backbone
- On the host CPU: the detection head ONNX, NMS, and bounding-box visualization
The full pipeline can run end-to-end on the GPNPU — see
yolox_e2e_chipy.ipynborretina_net_e2e_chipy.ipynbfor examples that compose CCL custom ops with ChiPy to keep everything on-chip.
1. Setup
Imports and per-run configuration. Most glue — transforms, calibration subset selection, ONNX export/split, and bounding-box visualization — lives in yolov8_helpers.py so this notebook can stay focused on the compile and inference story.
import gc
import numpy as np
import onnx
from onnxruntime import InferenceSession
from PIL import Image
from sdk_cli.lib.inference import InferenceEngine, batch_inference
from sdk_cli.lib.quantize import QuantizedONNXModel, quantize_onnx_model
from sdk_cli.node_builtins.classical.yolo_postprocessing import (
boxes_detections,
get_postprocess_handle,
)
from sdk_cli.utils.models.yolo import YOLOModelVariant
from tvm.contrib.epu.chimera_job.chimera_job import ChimeraJob
from yolov8_helpers import (
DEFAULT_IMAGE_PATHS,
INPUT_SIZE,
MODEL_NAME,
build_calibration_subset,
build_transforms,
display_detections,
export_onnx,
load_images,
split_backbone_and_head,
)
%matplotlib inline
2. Model Selection
Ultralytics ships several YOLOv8 sizes. We use yolov8n (nano) below for a fast round-trip through the SDK. The larger variants compile and run on the GPNPU with the same code — contact Quadric sales for access.
| Model | Size (px) | mAPval 50-95 | CPU ONNX (ms) | Params (M) | FLOPs (B) |
|---|---|---|---|---|---|
| YOLOv8n | 640 | 37.3 | 80.4 | 3.2 | 8.7 |
| YOLOv8s | 640 | 44.9 | 128.4 | 11.2 | 28.6 |
| YOLOv8m | 640 | 50.2 | 234.7 | 25.9 | 78.9 |
| YOLOv8l | 640 | 52.9 | 375.2 | 43.7 | 165.2 |
| YOLOv8x | 640 | 53.9 | 479.1 | 68.2 | 257.8 |
3. Model Generation and ONNX Export
export_onnx() loads the pretrained Ultralytics weights and writes yolov8n.onnx at the SDK's default ONNX opset, ready for the split step.
onnx_file = export_onnx(MODEL_NAME)
print(f"Exported: {onnx_file.name}")
Downloading https://github.com/ultralytics/assets/releases/download/v8.3.0/yolov8n.pt to 'yolov8n.pt'...
100%|█████████████████████████████████████| 6.25M/6.25M [00:00<00:00, 87.4MB/s]
Ultralytics 8.3.166 🚀 Python-3.10.12 torch-2.6.0+cpu CPU (AMD Ryzen 9 9950X 16-Core Processor)
YOLOv8n summary (fused): 72 layers, 3,151,904 parameters, 0 gradients, 8.7 GFLOPs
PyTorch: starting from 'yolov8n.pt' with input shape (1, 3, 640, 640) BCHW and output shape(s) (1, 84, 8400) (6.2 MB)
requirements: Ultralytics requirement ['onnxslim>=0.1.59'] not found, attempting AutoUpdate...
WARNING ⚠️ Retry 1/2 failed: Command 'pip install --no-cache-dir "onnxslim>=0.1.59" ' returned non-zero exit status 127.
WARNING ⚠️ Retry 2/2 failed: Command 'pip install --no-cache-dir "onnxslim>=0.1.59" ' returned non-zero exit status 127.
WARNING ⚠️ requirements: ❌ Command 'pip install --no-cache-dir "onnxslim>=0.1.59" ' returned non-zero exit status 127.
ONNX: starting export with onnx 1.16.2 opset 16...
WARNING ⚠️ ONNX: simplifier failure: No module named 'onnxslim'
ONNX: export success ✅ 5.1s, saved as 'yolov8n.onnx' (12.2 MB)
Export complete (10.6s)
Results saved to /quadric/sdk-cli/examples/models/yolo/yolov8
Predict: yolo predict task=detect model=yolov8n.onnx imgsz=640
Validate: yolo val task=detect model=yolov8n.onnx imgsz=640 data=coco.yaml
Visualize: https://netron.app
Exported: yolov8n.onnx
4. Split ONNX
The exported ONNX contains both the convolutional backbone and the detection head. We cut the graph at the six head-boundary edges and keep the backbone for CGC compilation; the head piece runs separately on the host as an ONNX-Runtime reference.
backbone_onnx_file, head_onnx_file = split_backbone_and_head(onnx_file, MODEL_NAME)
print(f"Backbone: {backbone_onnx_file.name}")
print(f"Head: {head_onnx_file.name}")
Backbone: yolov8n-backbone.onnx
Head: yolov8n-head.onnx
5. Quantization
The backbone is quantized to INT8 with asymmetric activations using the COCO-like subset of QuadricCalibration for tensor-range statistics. The QuantizedONNXModel return value carries both the quantized ONNX and its companion .tranges file.
calibration = build_calibration_subset()
quantized_onnx_model: QuantizedONNXModel = quantize_onnx_model(
str(backbone_onnx_file),
calibration.dataset,
asymmetric_activation=True,
)
print(f"Quantized ONNX: {quantized_onnx_model.model_path.name}")
print(f"Tensor ranges: {quantized_onnx_model.tensor_ranges_path.name}")
gc.collect()
2026-07-18 12:15 - INFO - sdk - quantize - ONNX model shapes inferred.
2026-07-18 12:15 - DEBUG - sdk - quantize - Forcing node types: []
2026-07-18 12:15 - DEBUG - sdk - quantize - ONNX Node types excluded from quantization: ['Softmax', 'Sigmoid', 'QuadricCustomOp']
2026-07-18 12:15 - DEBUG - sdk - quantize - ONNX Node names excluded from quantization: ['/model.4/m.1/cv2/act/Sigmoid', '/model.3/act/Sigmoid', '/model.15/cv2/act/Mul', '/model.4/m.0/cv1/act/Sigmoid', '/model.4/m.0/cv2/act/Sigmoid', '/model.4/m.1/cv1/act/Sigmoid', '/model.0/act/Sigmoid', '/model.1/act/Sigmoid', '/model.18/m.0/cv2/act/Sigmoid', '/model.6/m.0/cv1/act/Sigmoid', '/model.4/m.0/cv1/act/Mul', '/model.6/m.0/cv2/act/Mul', '/model.9/cv1/act/Mul', '/model.4/m.1/cv2/act/Mul', '/model.21/m.0/cv1/act/Mul', '/model.6/m.1/cv2/act/Sigmoid', '/model.2/m.0/cv2/act/Sigmoid', '/model.22/cv3.1/cv3.1.0/act/Sigmoid', '/model.4/cv2/act/Sigmoid', '/model.22/cv2.2/cv2.2.0/act/Sigmoid', '/model.12/m.0/cv2/act/Mul', '/model.18/m.0/cv1/act/Mul', '/model.21/cv2/act/Sigmoid', '/model.9/cv2/act/Sigmoid', '/model.21/cv1/act/Mul', '/model.2/cv2/act/Sigmoid', '/model.9/cv1/act/Sigmoid', '/model.8/m.0/cv1/act/Mul', '/model.22/cv3.2/cv3.2.1/act/Sigmoid', '/model.8/cv1/act/Mul', '/model.8/cv2/act/Sigmoid', '/model.21/cv2/act/Mul', '/model.1/act/Mul', '/model.12/cv2/act/Mul', '/model.22/cv3.0/cv3.0.1/act/Sigmoid', '/model.7/act/Sigmoid', '/model.22/cv2.2/cv2.2.1/act/Mul', '/model.18/cv1/act/Mul', '/model.6/cv1/act/Sigmoid', '/model.2/m.0/cv2/act/Mul', '/model.12/m.0/cv2/act/Sigmoid', '/model.12/cv1/act/Sigmoid', '/model.18/m.0/cv1/act/Sigmoid', '/model.21/m.0/cv1/act/Sigmoid', '/model.22/cv3.2/cv3.2.0/act/Sigmoid', '/model.19/act/Mul', '/model.6/m.1/cv1/act/Mul', '/model.3/act/Mul', '/model.22/cv2.2/cv2.2.1/act/Sigmoid', '/model.18/m.0/cv2/act/Mul', '/model.6/cv2/act/Sigmoid', '/model.6/m.1/cv1/act/Sigmoid', '/model.22/cv3.1/cv3.1.1/act/Sigmoid', '/model.15/m.0/cv2/act/Sigmoid', '/model.4/m.0/cv2/act/Mul', '/model.22/cv3.0/cv3.0.0/act/Mul', '/model.2/m.0/cv1/act/Sigmoid', '/model.2/m.0/cv1/act/Mul', '/model.22/cv2.1/cv2.1.1/act/Mul', '/model.15/cv1/act/Sigmoid', '/model.12/cv1/act/Mul', '/model.8/cv1/act/Sigmoid', '/model.8/m.0/cv2/act/Mul', '/model.8/cv2/act/Mul', '/model.9/cv2/act/Mul', '/model.15/cv1/act/Mul', '/model.6/m.1/cv2/act/Mul', '/model.22/cv3.2/cv3.2.1/act/Mul', '/model.16/act/Mul', '/model.22/cv2.0/cv2.0.1/act/Sigmoid', '/model.5/act/Sigmoid', '/model.6/cv1/act/Mul', '/model.4/cv1/act/Sigmoid', '/model.18/cv2/act/Mul', '/model.12/m.0/cv1/act/Sigmoid', '/model.22/cv2.1/cv2.1.0/act/Mul', '/model.22/cv2.0/cv2.0.0/act/Mul', '/model.12/m.0/cv1/act/Mul', '/model.15/m.0/cv2/act/Mul', '/model.6/cv2/act/Mul', '/model.7/act/Mul', '/model.4/cv1/act/Mul', '/model.6/m.0/cv1/act/Mul', '/model.6/m.0/cv2/act/Sigmoid', '/model.4/m.1/cv1/act/Mul', '/model.22/cv2.1/cv2.1.0/act/Sigmoid', '/model.0/act/Mul', '/model.2/cv2/act/Mul', '/model.22/cv3.0/cv3.0.1/act/Mul', '/model.21/cv1/act/Sigmoid', '/model.16/act/Sigmoid', '/model.22/cv2.0/cv2.0.1/act/Mul', '/model.15/m.0/cv1/act/Sigmoid', '/model.5/act/Mul', '/model.21/m.0/cv2/act/Sigmoid', '/model.22/cv3.0/cv3.0.0/act/Sigmoid', '/model.12/cv2/act/Sigmoid', '/model.22/cv2.1/cv2.1.1/act/Sigmoid', '/model.8/m.0/cv1/act/Sigmoid', '/model.22/cv2.2/cv2.2.0/act/Mul', '/model.21/m.0/cv2/act/Mul', '/model.15/m.0/cv1/act/Mul', '/model.22/cv2.0/cv2.0.0/act/Sigmoid', '/model.19/act/Sigmoid', '/model.22/cv3.1/cv3.1.1/act/Mul', '/model.22/cv3.2/cv3.2.0/act/Mul', '/model.2/cv1/act/Sigmoid', '/model.8/m.0/cv2/act/Sigmoid', '/model.22/cv3.1/cv3.1.0/act/Mul', '/model.2/cv1/act/Mul', '/model.4/cv2/act/Mul', '/model.18/cv2/act/Sigmoid', '/model.18/cv1/act/Sigmoid', '/model.15/cv2/act/Sigmoid']
2026-07-18 12:15 - INFO - sdk - quantize - Starting quantization...
WARNING:root:Please use QuantFormat.QDQ for activation type QInt8 and weight type QInt8. Or it will lead to bad performance on x64.
2026-07-18 12:15 - INFO - sdk - quantize - Quantization completed! Quantized model saved to /quadric/sdk-cli/examples/models/yolo/yolov8/yolov8n-backbone_OpSet16_optimized_asym_int8_q.onnx
2026-07-18 12:15 - INFO - sdk - quantize - ONNX full precision model size: 11.95MB
2026-07-18 12:15 - INFO - sdk - quantize - ONNX quantized model size: 3.11MB
2026-07-18 12:15 - INFO - sdk - quantize - ONNX model shapes inferred.
2026-07-18 12:15 - INFO - sdk - quantize - ONNX Model with well-defined shapes has been saved at `/quadric/sdk-cli/examples/models/yolo/yolov8/yolov8n-backbone_OpSet16_optimized_asym_int8_q_shaped.onnx`.
2026-07-18 12:15 - DEBUG - sdk - quantize - Checking for FLOAT/FLOAT16 types...
2026-07-18 12:15 - INFO - sdk - quantize - Checking for remaining FLOAT/FLOAT16 types.
2026-07-18 12:15 - INFO - sdk - quantize - Model still has FLOAT/FLOAT16 types after quantization. Creating ranges for floating point tensors using calibration data...
2026-07-18 12:16 - INFO - sdk - quantize - Saved computed tensor ranges to /quadric/sdk-cli/examples/models/yolo/yolov8/yolov8n-backbone_OpSet16_optimized_asym_int8_q_shaped.tranges.
2026-07-18 12:16 - INFO - sdk - quantize -
╒═════════════════════════════════════════════════════════════════════════════════════════════════════════╤════════════════════════════════════════════════════════════════════════════════════════════════════════════╕
│ Quantized ONNX Model │ Tensor Ranges File │
╞═════════════════════════════════════════════════════════════════════════════════════════════════════════╪════════════════════════════════════════════════════════════════════════════════════════════════════════════╡
│ /quadric/sdk-cli/examples/models/yolo/yolov8/yolov8n-backbone_OpSet16_optimized_asym_int8_q_shaped.onnx │ /quadric/sdk-cli/examples/models/yolo/yolov8/yolov8n-backbone_OpSet16_optimized_asym_int8_q_shaped.tranges │
╘═════════════════════════════════════════════════════════════════════════════════════════════════════════╧════════════════════════════════════════════════════════════════════════════════════════════════════════════╛
Quantized ONNX: yolov8n-backbone_OpSet16_optimized_asym_int8_q_shaped.onnx
Tensor ranges: yolov8n-backbone_OpSet16_optimized_asym_int8_q_shaped.tranges
6740
6. Compilation
ChimeraJob wraps the full compile pipeline: graph analyze, kernel selection, memory planning, and code generation. Printing the job renders a summary table that includes the target configuration and the top-level operator counts.
cgc_job = ChimeraJob(model_p=str(quantized_onnx_model.model_path))
cgc_job.compile(quiet=True)
print(cgc_job)
╒═════════════════════╤═════════════════════════════════════════════════════════════════════════════════════════════════════════╕
│ Module Name │ yolov8n_backbone_OpSet16_optimized_asym_int8_q_shaped_QC_U_1d7_16MB_4kB_128GBps_128GBps_16_OFF_x1_x1 │
├─────────────────────┼─────────────────────────────────────────────────────────────────────────────────────────────────────────┤
│ ONNX File │ /quadric/sdk-cli/examples/models/yolo/yolov8/yolov8n-backbone_OpSet16_optimized_asym_int8_q_shaped.onnx │
├─────────────────────┼─────────────────────────────────────────────────────────────────────────────────────────────────────────┤
│ Product Target │ QC-U │
├─────────────────────┼─────────────────────────────────────────────────────────────────────────────────────────────────────────┤
│ Number of Cores │ 1 │
├─────────────────────┼─────────────────────────────────────────────────────────────────────────────────────────────────────────┤
│ ISS Clock Frequency │ 1.700 │
├─────────────────────┼─────────────────────────────────────────────────────────────────────────────────────────────────────────┤
│ L2M Size │ 16MB │
├─────────────────────┼─────────────────────────────────────────────────────────────────────────────────────────────────────────┤
│ LRM Size │ 4kB │
├─────────────────────┼─────────────────────────────────────────────────────────────────────────────────────────────────────────┤
│ External Read BW │ 128GBps │
├─────────────────────┼─────────────────────────────────────────────────────────────────────────────────────────────────────────┤
│ External Write BW │ 128GBps │
├─────────────────────┼─────────────────────────────────────────────────────────────────────────────────────────────────────────┤
│ MACS per PE │ 16 │
├─────────────────────┼─────────────────────────────────────────────────────────────────────────────────────────────────────────┤
│ Max L2M │ 5.892MB │
├─────────────────────┼─────────────────────────────────────────────────────────────────────────────────────────────────────────┤
│ Max LRM │ 1.625kB │
├─────────────────────┼─────────────────────────────────────────────────────────────────────────────────────────────────────────┤
│ Max Temp Ext Bytes │ 0.000MB │
├─────────────────────┼─────────────────────────────────────────────────────────────────────────────────────────────────────────┤
│ Network GMACs │ 4.283 │
╘═════════════════════╧═════════════════════════════════════════════════════════════════════════════════════════════════════════╛
╒════╤════════╤══════════════════════════════════════════╤══════════════════╤══════════════════════════╤═══════╕
│ │ Type │ Name │ shape │ type │ mse │
╞════╪════════╪══════════════════════════════════════════╪══════════════════╪══════════════════════════╪═══════╡
│ 0 │ Input │ images │ [1, 3, 640, 640] │ tensor[FixedPoint32<27>] │ n/a │
├────┼────────┼──────────────────────────────────────────┼──────────────────┼──────────────────────────┼───────┤
│ 1 │ Output │ /model.22/cv2.0/cv2.0.1/act/Mul_output_0 │ [1, 64, 80, 80] │ tensor[FixedPoint32<25>] │ n/a │
├────┼────────┼──────────────────────────────────────────┼──────────────────┼──────────────────────────┼───────┤
│ 2 │ Output │ /model.22/cv3.0/cv3.0.1/act/Mul_output_0 │ [1, 80, 80, 80] │ tensor[FixedPoint32<24>] │ n/a │
├────┼────────┼──────────────────────────────────────────┼──────────────────┼──────────────────────────┼───────┤
│ 3 │ Output │ /model.22/cv2.1/cv2.1.1/act/Mul_output_0 │ [1, 64, 40, 40] │ tensor[FixedPoint32<25>] │ n/a │
├────┼────────┼──────────────────────────────────────────┼──────────────────┼──────────────────────────┼───────┤
│ 4 │ Output │ /model.22/cv3.1/cv3.1.1/act/Mul_output_0 │ [1, 80, 40, 40] │ tensor[FixedPoint32<23>] │ n/a │
├────┼────────┼──────────────────────────────────────────┼──────────────────┼──────────────────────────┼───────┤
│ 5 │ Output │ /model.22/cv2.2/cv2.2.1/act/Mul_output_0 │ [1, 64, 20, 20] │ tensor[FixedPoint32<25>] │ n/a │
├────┼────────┼──────────────────────────────────────────┼──────────────────┼──────────────────────────┼───────┤
│ 6 │ Output │ /model.22/cv3.2/cv3.2.1/act/Mul_output_0 │ [1, 80, 20, 20] │ tensor[FixedPoint32<24>] │ n/a │
╘════╧════════╧══════════════════════════════════════════╧══════════════════╧══════════════════════════╧═══════╛
7. Inference
batch_inference runs the compiled backbone against multiple images in parallel — once through ORT INT8 (reference) and once through ISS INT8 (the Chimera GPNPU's cycle-accurate simulator). Both use the same head ONNX on the host for the detection tail.
all_image_paths, all_images = load_images(DEFAULT_IMAGE_PATHS)
num_images = len(all_images)
engines = {
InferenceEngine.CHIMERA_ORT_INT8: cgc_job,
InferenceEngine.CHIMERA_ISS_INT8: cgc_job,
}
head_session = InferenceSession(onnx.load(str(head_onnx_file)).SerializeToString())
outputs_per_engine = {}
threads = min(num_images, 6)
for engine, job in engines.items():
outputs_per_engine[engine] = batch_inference(
engine, job, all_images, head_session=head_session, threads=threads
)
2026-07-18 12:20 - WARNING - epu - chimera_job - ORT is not threadsafe -- forcing single threaded batch execution
100%|████████████████████████████████████████████| 3/3 [00:00<00:00, 4.21it/s]
Processing: 100%|████████████████████████████████| 3/3 [00:47<00:00, 15.83s/it]
8. Run Statistics
plot_run_statistics() renders the per-kernel cycle breakdown for the compiled backbone — useful for spotting hot kernels when tuning the target configuration.
print(cgc_job)
cgc_job.plot_run_statistics()
╒═════════════════════╤═════════════════════════════════════════════════════════════════════════════════════════════════════════╕
│ Module Name │ yolov8n_backbone_OpSet16_optimized_asym_int8_q_shaped_QC_U_1d7_16MB_4kB_128GBps_128GBps_16_OFF_x1_x1 │
├─────────────────────┼─────────────────────────────────────────────────────────────────────────────────────────────────────────┤
│ ONNX File │ /quadric/sdk-cli/examples/models/yolo/yolov8/yolov8n-backbone_OpSet16_optimized_asym_int8_q_shaped.onnx │
├─────────────────────┼─────────────────────────────────────────────────────────────────────────────────────────────────────────┤
│ Product Target │ QC-U │
├─────────────────────┼─────────────────────────────────────────────────────────────────────────────────────────────────────────┤
│ Number of Cores │ 1 │
├─────────────────────┼─────────────────────────────────────────────────────────────────────────────────────────────────────────┤
│ ISS Clock Frequency │ 1.700 │
├─────────────────────┼─────────────────────────────────────────────────────────────────────────────────────────────────────────┤
│ L2M Size │ 16MB │
├─────────────────────┼─────────────────────────────────────────────────────────────────────────────────────────────────────────┤
│ LRM Size │ 4kB │
├─────────────────────┼─────────────────────────────────────────────────────────────────────────────────────────────────────────┤
│ External Read BW │ 128GBps │
├─────────────────────┼─────────────────────────────────────────────────────────────────────────────────────────────────────────┤
│ External Write BW │ 128GBps │
├─────────────────────┼─────────────────────────────────────────────────────────────────────────────────────────────────────────┤
│ MACS per PE │ 16 │
├─────────────────────┼─────────────────────────────────────────────────────────────────────────────────────────────────────────┤
│ Max L2M │ 5.892MB │
├─────────────────────┼─────────────────────────────────────────────────────────────────────────────────────────────────────────┤
│ Max LRM │ 1.625kB │
├─────────────────────┼─────────────────────────────────────────────────────────────────────────────────────────────────────────┤
│ Max Temp Ext Bytes │ 0.000MB │
├─────────────────────┼─────────────────────────────────────────────────────────────────────────────────────────────────────────┤
│ Network GMACs │ 4.283 │
╘═════════════════════╧═════════════════════════════════════════════════════════════════════════════════════════════════════════╛
╒════╤════════╤══════════════════════════════════════════╤══════════════════╤══════════════════════════╤═══════╕
│ │ Type │ Name │ shape │ type │ mse │
╞════╪════════╪══════════════════════════════════════════╪══════════════════╪══════════════════════════╪═══════╡
│ 0 │ Input │ images │ [1, 3, 640, 640] │ tensor[FixedPoint32<27>] │ n/a │
├────┼────────┼──────────────────────────────────────────┼──────────────────┼──────────────────────────┼───────┤
│ 1 │ Output │ /model.22/cv2.0/cv2.0.1/act/Mul_output_0 │ [1, 64, 80, 80] │ tensor[FixedPoint32<25>] │ 0.081 │
├────┼────────┼──────────────────────────────────────────┼──────────────────┼──────────────────────────┼───────┤
│ 2 │ Output │ /model.22/cv3.0/cv3.0.1/act/Mul_output_0 │ [1, 80, 80, 80] │ tensor[FixedPoint32<24>] │ 0.117 │
├────┼────────┼──────────────────────────────────────────┼──────────────────┼──────────────────────────┼───────┤
│ 3 │ Output │ /model.22/cv2.1/cv2.1.1/act/Mul_output_0 │ [1, 64, 40, 40] │ tensor[FixedPoint32<25>] │ 0.080 │
├────┼────────┼──────────────────────────────────────────┼──────────────────┼──────────────────────────┼───────┤
│ 4 │ Output │ /model.22/cv3.1/cv3.1.1/act/Mul_output_0 │ [1, 80, 40, 40] │ tensor[FixedPoint32<23>] │ 0.143 │
├────┼────────┼──────────────────────────────────────────┼──────────────────┼──────────────────────────┼───────┤
│ 5 │ Output │ /model.22/cv2.2/cv2.2.1/act/Mul_output_0 │ [1, 64, 20, 20] │ tensor[FixedPoint32<25>] │ 0.055 │
├────┼────────┼──────────────────────────────────────────┼──────────────────┼──────────────────────────┼───────┤
│ 6 │ Output │ /model.22/cv3.2/cv3.2.1/act/Mul_output_0 │ [1, 80, 20, 20] │ tensor[FixedPoint32<24>] │ 0.144 │
╘════╧════════╧══════════════════════════════════════════╧══════════════════╧══════════════════════════╧═══════╛
Post-ISS Report 1.7 GHz ***
Fully placed-and-routed gate simulation:
╒══════════════════════════════════╤═════════╕
│ Latency (ms) │ 1.04 │
├──────────────────────────────────┼─────────┤
│ FPS │ 961.43 │
├──────────────────────────────────┼─────────┤
│ Average Power @ 3nm SSGNP (mW) │ 2004.88 │
├──────────────────────────────────┼─────────┤
│ FPS per Watt @ 3nm SSGNP (FPS/W) │ 479.54 │
├──────────────────────────────────┼─────────┤
│ Ext Rd Bytes (MB) │ 7.74 │
├──────────────────────────────────┼─────────┤
│ Ext Wr Bytes (MB) │ 4.61 │
├──────────────────────────────────┼─────────┤
│ Avg Ext Rd BW (GBps) │ 7.27 │
├──────────────────────────────────┼─────────┤
│ Avg Ext Wr BW (GBps) │ 4.33 │
├──────────────────────────────────┼─────────┤
│ MAC Utilization │ 14.79% │
╘══════════════════════════════════╧═════════╛
*** Data generated using 7nm SSGNP gatesim and scaled to 3nm
[SDK-CLI] : TotalCycles: 1,768,207
[SDK-CLI] : Executions/second: 961.43
compute : ▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇ 568.451K
data_array : ▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇ 207.014K
mac : ▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇ 598.175K
data_external: ▇▇▇▇▇▇▇▇▇ 115.548K
data_ocm : ▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇ 277.013K
for more information check run directory: /quadric/sdk-cli/examples/models/yolo/yolov8/ccl_build/yolov8n_backbone_OpSet16_optimized_asym_int8_q_shaped_QC_U_1d7_16MB_4kB_128GBps_128GBps_16_OFF_x1_x1/run/20260718_122024_257f11
2026-07-18 12:21 - INFO - epu - chimera_job - Combined plots generated and saved to:
/quadric/sdk-cli/examples/models/yolo/yolov8/ccl_build/yolov8n_backbone_OpSet16_optimized_asym_int8_q_shaped_QC_U_1d7_16MB_4kB_128GBps_128GBps_16_OFF_x1_x1/run/20260718_122024_257f11/data/yolov8n_backbone_OpSet16_optimized_asym_int8_q_shaped_QC_U_1d7_16MB_4kB_128GBps_128GBps_16_OFF_x1_x1.combined.png
'/quadric/sdk-cli/examples/models/yolo/yolov8/ccl_build/yolov8n_backbone_OpSet16_optimized_asym_int8_q_shaped_QC_U_1d7_16MB_4kB_128GBps_128GBps_16_OFF_x1_x1/run/20260718_122024_257f11/data'

Decode the network outputs and overlay the detections on the input image.
postprocess_handle = get_postprocess_handle(YOLOModelVariant.YOLOv8)
postprocess_handle.score_threshold = 0.45
detections_per_engine = {}
for engine, all_outputs in outputs_per_engine.items():
detections_per_engine[engine] = [
boxes_detections(
postprocess_handle,
np.array(Image.open(path)),
outputs,
INPUT_SIZE,
)[0]
for outputs, path in zip(all_outputs, all_image_paths)
]
display_detections(
all_image_paths,
detections_per_engine,
class_names=postprocess_handle.datasetclasses,
)



Summary
| Model | YOLOv8n (COCO, 640×640, 3.2M params, 8.7 GFLOPs) |
| Pipeline | ONNX export → split → quantize (INT8 asymmetric) → CGC compile → ISS + ORT inference → YOLOv8 NMS → bbox overlay |
| Compiled on GPNPU | Convolutional backbone |
| On host CPU | YOLOv8 head ONNX, classical NMS, bounding-box visualization |
| Calibration | QuadricCalibration COCO-like subset |
Key takeaways
- Splitting the ONNX at the head boundary keeps CGC focused on GPNPU-friendly convolutional ops while the classical NMS / box-decode tail runs on the host.
- The SDK exposes the same
ChimeraJobhandle to bothCHIMERA_ORT_INT8(ONNX Runtime reference) andCHIMERA_ISS_INT8(ISS), making side-by-side validation a one-dict change. - Asymmetric INT8 quantization on a COCO-like calibration subset preserves YOLOv8n detection quality at the
score_threshold = 0.45used here.
Citation
@software{yolov8_ultralytics,
author = {Glenn Jocher and Ayush Chaurasia and Jing Qiu},
title = {Ultralytics YOLOv8},
version = {8.0.0},
year = {2023},
url = {https://github.com/ultralytics/ultralytics},
license = {AGPL-3.0}
}