Add YOLOv26n RDK X5 model and quantized artifacts

This commit is contained in:
cyy_mac
2026-08-07 11:15:41 +08:00
commit 7931375c8e
92 changed files with 24515 additions and 0 deletions

20
x5_quantization/README.md Normal file
View File

@@ -0,0 +1,20 @@
# RDK X5 YOLOv26n 量化
输入模型为 `../best.onnx`,固定输入 `images [1,3,640,640]`opset 11。流程参考
`D-Robotics/rdk_model_zoo``rdk_x5` 分支中 `ultralytics_yolo26` 示例:
- `extract_yolo26_bpu.py` 移除 TopK、Gather 和最终检测结果组装,只输出三尺度
`(cls, box)` 原始特征,输出布局为 NHWC。
- 校准数据从 `../../dataset` 均匀抽取 50 张图片,直接 resize 到 640x640保存
RGB/CHW/float32`data_scale=1/255` 由量化配置完成。
- 板端输入为 NV12量化默认 int8并使用官方 Softmax int8 优化项。
执行 `./quantize_x5.sh` 会在 Docker 镜像
`openexplorer/ai_toolchain_ubuntu_20_x5_cpu:v1.2.8` 中依次运行 `hb_mapper checker`
`hb_mapper makertbin`,产物为
`mapper_output_bpu/best_bpu_bayese_640x640_nv12.bin`。部署端需要按三尺度输出完成
sigmoid、LTRB 解码、阈值筛选和 NMS可直接复用 `postprocess_yolo26.py`
板端输入是 NV12模型输出顺序为 `cls_s8, box_s8, cls_s16, box_s16,
cls_s32, box_s32`,输出张量布局是 NHWC。`.bin``model_info` 应以板端
`hrt_model_exec` 实际显示的名称和量化参数为准。

Binary file not shown.

View File

@@ -0,0 +1,26 @@
model_parameters:
onnx_model: "./best_bpu.onnx"
march: "bayes-e"
layer_out_dump: false
working_dir: "mapper_output_bpu"
output_model_file_prefix: "best_bpu_bayese_640x640_nv12"
input_parameters:
input_name: "images"
input_type_rt: "nv12"
input_type_train: "rgb"
input_layout_train: "NCHW"
norm_type: "data_scale"
scale_value: 0.003921568627451
calibration_parameters:
cal_data_dir: "./calibration_data"
cal_data_type: "float32"
calibration_type: "default"
optimization: "set_Softmax_input_int8,set_Softmax_output_int8"
compiler_parameters:
jobs: 8
compile_mode: "latency"
debug: true
optimize_level: "O3"

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@@ -0,0 +1,50 @@
images/train/00246cf2-46a7-4a4e-8bc8-8e7f2317ad09.png
images/train/084113da-5f61-45b5-ad3f-ba8554be0c0f_aug1.jpg
images/train/13418823-8a5e-48bc-915f-08f6b3cafc02.png
images/train/1876b5d2-8c8f-42f7-adf6-b1947f3dd50c.jpg
images/train/23b67116-7810-46c9-a5fd-70133b0f05a3_aug2.jpg
images/train/29949023-6872-41a2-8661-a27d3643842b.png
images/train/351d7271-aede-4b44-831f-df8eb37015f3_aug1.jpg
images/train/39d4539f-022c-471a-bee7-c01d1747628e.png
images/train/44926b9a-1aa6-43b1-ac5b-a4930ab630a0.png
images/train/49795500-4f4b-437f-ade7-0a17841bf309_aug2.jpg
images/train/5584b78d-87bd-4326-aa33-0cf9299bb99e_aug1.jpg
images/train/5e5854dc-9716-4579-ab99-5f78383de59d_aug1.jpg
images/train/64330e99-c7f1-4437-a5c0-8d46c8bdb80e.png
images/train/69049243-6fa9-48d2-b7fa-8a2dd749aade_aug1.jpg
images/train/6dffe65d-b770-4163-a242-8191a87c2f3e_aug2.jpg
images/train/7358fcd2-1eb5-4b14-aa0d-95bb3a70f456_aug1.jpg
images/train/77d8e632-c826-4608-ae0d-40c3dc35dae2.png
images/train/7dd1d683-bbbb-4783-8700-94634f64a1fa_aug1.jpg
images/train/82c41b72-ee4d-4d78-985f-1eb82f50b2f4_aug3.jpg
images/train/87fb24a0-849b-47b9-8ae6-ca4e89abb52c.png
images/train/8cf0b48c-52f0-4b02-88fe-fd26c0063565.png
images/train/921171d2-9791-481a-a3b8-9c93fcb0f479_aug1.jpg
images/train/964a3741-0a41-4a04-82f3-f74cc558a223_aug2.jpg
images/train/9bd59151-88c0-4f4f-bcd8-a6c823248424_aug2.jpg
images/train/a0bc336e-84ed-41ee-8516-4dce806dcd64.png
images/train/a56563df-3e99-45fb-9f29-5f3ec2062da4_aug2.jpg
images/train/aaefdc2e-28cd-4769-96bd-4f7d43d58032.png
images/train/b0473ba5-63d0-4ca1-a1b3-cd3a0d85cbce.png
images/train/b62abb00-d665-4053-8639-97cf3243cf0d_aug1.jpg
images/train/bb6936bc-cc3a-4bb1-9a2c-61ef054a8866_aug4.jpg
images/train/c0c8f3c3-fa59-430a-819f-8da63d470d83.jpg
images/train/c6a9a9fd-242d-420f-91bc-79419f83604a_aug2.jpg
images/train/cc7d55cb-6fb7-4ed8-a524-b022c671454e_aug1.jpg
images/train/d1b89258-c545-4d4a-bd32-60e6f5d7131a_aug1.jpg
images/train/d6601c84-b38a-46df-94c9-3e67ae4c0b7b_aug2.jpg
images/train/dbf7ba4e-24fc-45dd-b655-144bd4ccbe71_aug1.jpg
images/train/e0f3883b-2301-4b95-b975-9fd4a1cfa0be.png
images/train/e605a9e1-5ae1-4da4-8326-9050c21966c6_aug2.jpg
images/train/eb08a24f-7ead-4fae-9f4c-717cd54e4b8f_aug3.jpg
images/train/f040251a-9a78-4536-9439-3803759952e5.png
images/train/f5c6161c-9ea7-432a-9b44-82678c19ee0e_aug2.jpg
images/train/fb30aaaf-3009-4089-98b4-088e020ae1bb_aug2.jpg
images/vel/02f61ef1-3c40-446e-ac2d-fbc7e4ccf605_aug1.jpg
images/vel/0dc056fb-8373-4834-8630-bc0057a1d24c_aug1.jpg
images/vel/1cb927cc-6af4-4c87-a3fa-f5a6f1fc1ebd_aug2.jpg
images/vel/2bdc0ba0-bac7-41d2-80ce-f0301e3e2d5c.png
images/vel/3b347f91-60b4-4d1a-b187-50a9f106f072_aug2.jpg
images/vel/4a674364-26ba-43c8-9448-bcd2bdd68275_aug2.jpg
images/vel/4fc2dc2f-85db-4df0-a4a6-e18f15a856dd.png
images/vel/fb5adb2c-e598-4ae4-bbf1-8e46a10158c3_aug4.jpg

343
x5_quantization/checker.log Normal file
View File

@@ -0,0 +1,343 @@
2026-08-07 10:39:43,366 file: tool_utils.py func: tool_utils line No: 77 log will be stored in /workspace/smart_car_2026/model/hb_mapper_checker.log
2026-08-07 10:39:43,367 file: hb_mapper.py func: hb_mapper line No: 72 Start hb_mapper....
2026-08-07 10:39:43,367 file: hb_mapper.py func: hb_mapper line No: 73 hbdk version 3.49.15
2026-08-07 10:39:43,368 file: hb_mapper.py func: hb_mapper line No: 74 horizon_nn version 1.1.0
2026-08-07 10:39:43,368 file: hb_mapper.py func: hb_mapper line No: 75 hb_mapper version 1.24.3
2026-08-07 10:39:43,386 file: onnx_parser.py func: onnx_parser line No: 39 Model input names: ['images']
2026-08-07 10:39:43,388 file: hb_mapper_checker.py func: hb_mapper_checker line No: 106 Model type: onnx
2026-08-07 10:39:43,388 file: hb_mapper_checker.py func: hb_mapper_checker line No: 107 march: bayes-e
2026-08-07 10:39:43,388 file: hb_mapper_checker.py func: hb_mapper_checker line No: 112 input names ['images']
2026-08-07 10:39:43,389 file: hb_mapper_checker.py func: hb_mapper_checker line No: 113 input shapes {'images': [1, 3, 640, 640]}
2026-08-07 10:39:43,396 file: onnx_parser.py func: onnx_parser line No: 39 Model input names: ['images']
2026-08-07 10:39:43,397 file: hb_mapper_checker.py func: hb_mapper_checker line No: 119 Begin model checking....
2026-08-07 10:39:43,409 file: model_builder.py func: model_builder line No: 35 Start to Horizon NN Model Convert.
2026-08-07 10:39:43,430 file: model_debugger.py func: model_debugger line No: 67 Loading horizon_nn debug methods:set()
2026-08-07 10:39:43,431 file: quantization_config.py func: quantization_config line No: 305 The activation calibration parameters:
calibration_type: fixed
2026-08-07 10:39:43,431 file: model_builder.py func: model_builder line No: 197 The specified model compilation architecture: bayes-e.
2026-08-07 10:39:43,431 file: model_builder.py func: model_builder line No: 207 The specified model compilation optimization parameters: [].
2026-08-07 10:39:43,432 file: model_builder.py func: model_builder line No: 35 Start to prepare the onnx model.
2026-08-07 10:39:43,468 file: prepare.py func: prepare line No: 106 Input ONNX Model Information:
ONNX IR version: 6
Opset version: ['ai.onnx v11', 'horizon v1']
Producer: onnx.utils.extract_model
Domain: None
Version: None
Graph input:
images: shape=[1, 3, 640, 640], dtype=FLOAT32
Graph output:
cls_s8: shape=[1, 80, 80, 4], dtype=FLOAT32
box_s8: shape=[1, 80, 80, 4], dtype=FLOAT32
cls_s16: shape=[1, 40, 40, 4], dtype=FLOAT32
box_s16: shape=[1, 40, 40, 4], dtype=FLOAT32
cls_s32: shape=[1, 20, 20, 4], dtype=FLOAT32
box_s32: shape=[1, 20, 20, 4], dtype=FLOAT32
2026-08-07 10:39:43,655 file: model_builder.py func: model_builder line No: 38 End to prepare the onnx model.
2026-08-07 10:39:43,689 file: model_builder.py func: model_builder line No: 265 Saving model to: ./.hb_check/original_float_model.onnx.
2026-08-07 10:39:43,689 file: model_builder.py func: model_builder line No: 35 Start to optimize the onnx model.
2026-08-07 10:39:43,863 file: constant_folding.py func: constant_folding line No: 66 Summary info for constant_folding:
2026-08-07 10:39:43,863 file: constant_folding.py func: constant_folding line No: 67 After constant_folding, the number of nodes has changed from 355 to 355.
2026-08-07 10:39:43,864 file: constant_folding.py func: constant_folding line No: 71 After constant_folding, the number of parameters has changed from 2375629 to 2375629.
2026-08-07 10:39:43,864 file: constant_folding.py func: constant_folding line No: 76 Detailed info for constant_folding:
2026-08-07 10:39:43,864 file: constant_folding.py func: constant_folding line No: 88
2026-08-07 10:39:44,358 file: model_builder.py func: model_builder line No: 38 End to optimize the onnx model.
2026-08-07 10:39:44,389 file: model_builder.py func: model_builder line No: 265 Saving model to: ./.hb_check/optimized_float_model.onnx.
2026-08-07 10:39:44,389 file: model_builder.py func: model_builder line No: 35 Start to calibrate the model.
2026-08-07 10:39:44,681 file: calibration_data_set.py func: calibration_data_set line No: 111 input name: images, number_of_samples: 1
2026-08-07 10:39:44,681 file: calibration_data_set.py func: calibration_data_set line No: 123 There are 1 samples in the data set.
2026-08-07 10:39:44,682 file: fixed_calibrater.py func: fixed_calibrater line No: 31 Run calibration model with fixed thresholds method.
2026-08-07 10:39:45,210 file: model_builder.py func: model_builder line No: 38 End to calibrate the model.
2026-08-07 10:39:45,332 file: model_builder.py func: model_builder line No: 265 Saving model to: ./.hb_check/calibrated_model.onnx.
2026-08-07 10:39:45,333 file: model_builder.py func: model_builder line No: 35 Start to quantize the model.
2026-08-07 10:39:47,542 file: constant_folding.py func: constant_folding line No: 66 Summary info for constant_folding:
2026-08-07 10:39:47,542 file: constant_folding.py func: constant_folding line No: 67 After constant_folding, the number of nodes has changed from 280 to 280.
2026-08-07 10:39:47,543 file: constant_folding.py func: constant_folding line No: 71 After constant_folding, the number of parameters has changed from 2406337 to 2406337.
2026-08-07 10:39:47,543 file: constant_folding.py func: constant_folding line No: 76 Detailed info for constant_folding:
2026-08-07 10:39:47,543 file: constant_folding.py func: constant_folding line No: 88
2026-08-07 10:39:47,634 file: model_builder.py func: model_builder line No: 38 End to quantize the model.
2026-08-07 10:39:47,729 file: model_builder.py func: model_builder line No: 265 Saving model to: ./.hb_check/quantized_model.onnx.
2026-08-07 10:39:47,729 file: model_builder.py func: model_builder line No: 35 Start to compile the model with march bayes-e.
2026-08-07 10:39:48,338 file: hybrid_build.py func: hybrid_build line No: 111 Compile submodel: Extracted from {main_graph}_subgraph_0
2026-08-07 10:39:48,363 file: hbdk_cc.py func: hbdk_cc line No: 126 hbdk-cc parameters:['--input-layout', 'NHWC', '--output-layout', 'NHWC']
2026-08-07 10:39:48,363 file: hbdk_cc.py func: hbdk_cc line No: 127 hbdk-cc command used:hbdk-cc -f hbir -m /tmp/tmpo3cnuwll/Extracted from {main_graph}_subgraph_0.hbir -o /tmp/tmpo3cnuwll/Extracted from {main_graph}_subgraph_0.hbm --march bayes-e --progressbar --input-layout NHWC --output-layout NHWC
2026-08-07 10:39:49,198 file: tool_utils.py func: tool_utils line No: 326 consumed time 0.65736
2026-08-07 10:39:49,411 file: tool_utils.py func: tool_utils line No: 326 FPS=52.45, latency = 19064.1 us, DDR = 122035200 bytes (see ./.hb_check/Extracted from {main_graph}_subgraph_0.html)
2026-08-07 10:39:49,414 file: hybrid_build.py func: hybrid_build line No: 111 Compile submodel: Extracted from {main_graph}_subgraph_1
2026-08-07 10:39:49,431 file: hbdk_cc.py func: hbdk_cc line No: 126 hbdk-cc parameters:['--input-layout', 'NHWC', '--output-layout', 'NHWC']
2026-08-07 10:39:49,431 file: hbdk_cc.py func: hbdk_cc line No: 127 hbdk-cc command used:hbdk-cc -f hbir -m /tmp/tmpo3cnuwll/Extracted from {main_graph}_subgraph_1.hbir -o /tmp/tmpo3cnuwll/Extracted from {main_graph}_subgraph_1.hbm --march bayes-e --progressbar --input-layout NHWC --output-layout NHWC
2026-08-07 10:39:50,353 file: tool_utils.py func: tool_utils line No: 326 consumed time 0.755009
2026-08-07 10:39:50,544 file: tool_utils.py func: tool_utils line No: 326 FPS=45.81, latency = 21827.8 us, DDR = 138583616 bytes (see ./.hb_check/Extracted from {main_graph}_subgraph_1.html)
2026-08-07 10:39:50,549 file: hybrid_build.py func: hybrid_build line No: 111 Compile submodel: Extracted from {main_graph}_subgraph_2
2026-08-07 10:39:50,556 file: hbdk_cc.py func: hbdk_cc line No: 126 hbdk-cc parameters:['--input-layout', 'NHWC', '--output-layout', 'NHWC']
2026-08-07 10:39:50,557 file: hbdk_cc.py func: hbdk_cc line No: 127 hbdk-cc command used:hbdk-cc -f hbir -m /tmp/tmpo3cnuwll/Extracted from {main_graph}_subgraph_2.hbir -o /tmp/tmpo3cnuwll/Extracted from {main_graph}_subgraph_2.hbm --march bayes-e --progressbar --input-layout NHWC --output-layout NHWC
2026-08-07 10:39:51,107 file: tool_utils.py func: tool_utils line No: 326 consumed time 0.387866
2026-08-07 10:39:51,284 file: tool_utils.py func: tool_utils line No: 326 FPS=142.7, latency = 7007.7 us, DDR = 44277504 bytes (see ./.hb_check/Extracted from {main_graph}_subgraph_2.html)
2026-08-07 10:39:51,550 file: model_builder.py func: model_builder line No: 38 End to compile the model with march bayes-e.
2026-08-07 10:39:51,564 file: print_info_dict.py func: print_info_dict line No: 72 The main quantized node information:
======================================================================================================================================
Node ON Subgraph Type Cosine Similarity Threshold DataType
--------------------------------------------------------------------------------------------------------------------------------------
/model.0/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.0/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.1/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.1/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.2/cv1/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.2/cv1/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.2/Split BPU id(0) Split -- 1.0 int8
/model.2/m.0/cv1/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.2/m.0/cv1/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.2/m.0/cv2/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.2/m.0/cv2/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.2/m.0/Add BPU id(0) HzSElementwiseAdd -- 1.0 int8
/model.2/Concat BPU id(0) Concat -- 1.0 int8
/model.2/cv2/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.2/cv2/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.3/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.3/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.4/cv1/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.4/cv1/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.4/Split BPU id(0) Split -- 1.0 int8
/model.4/m.0/cv1/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.4/m.0/cv1/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.4/m.0/cv2/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.4/m.0/cv2/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.4/m.0/Add BPU id(0) HzSElementwiseAdd -- 1.0 int8
/model.4/Concat BPU id(0) Concat -- 1.0 int8
/model.4/cv2/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.4/cv2/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.5/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.5/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.6/cv1/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.6/cv1/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.6/Split BPU id(0) Split -- 1.0 int8
/model.6/m.0/cv1/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.6/m.0/cv2/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.6/m.0/cv1/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.6/m.0/cv2/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.6/m.0/m/m.0/cv1/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.6/m.0/m/m.0/cv1/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.6/m.0/m/m.0/cv2/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.6/m.0/m/m.0/cv2/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.6/m.0/m/m.0/Add BPU id(0) HzSElementwiseAdd -- 1.0 int8
/model.6/m.0/m/m.1/cv1/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.6/m.0/m/m.1/cv1/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.6/m.0/m/m.1/cv2/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.6/m.0/m/m.1/cv2/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.6/m.0/m/m.1/Add BPU id(0) HzSElementwiseAdd -- 1.0 int8
/model.6/m.0/Concat BPU id(0) Concat -- 1.0 int8
/model.6/m.0/cv3/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.6/m.0/cv3/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.6/Concat BPU id(0) Concat -- 1.0 int8
/model.6/cv2/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.6/cv2/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.7/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.7/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.8/cv1/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.8/cv1/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.8/Split BPU id(0) Split -- 1.0 int8
/model.8/m.0/cv1/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.8/m.0/cv2/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.8/m.0/cv1/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.8/m.0/cv2/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.8/m.0/m/m.0/cv1/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.8/m.0/m/m.0/cv1/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.8/m.0/m/m.0/cv2/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.8/m.0/m/m.0/cv2/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.8/m.0/m/m.0/Add BPU id(0) HzSElementwiseAdd -- 1.0 int8
/model.8/m.0/m/m.1/cv1/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.8/m.0/m/m.1/cv1/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.8/m.0/m/m.1/cv2/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.8/m.0/m/m.1/cv2/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.8/m.0/m/m.1/Add BPU id(0) HzSElementwiseAdd -- 1.0 int8
/model.8/m.0/Concat BPU id(0) Concat -- 1.0 int8
/model.8/m.0/cv3/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.8/m.0/cv3/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.8/Concat BPU id(0) Concat -- 1.0 int8
/model.8/cv2/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.8/cv2/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.9/cv1/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.9/m/MaxPool BPU id(0) HzQuantizedMaxPool -- 1.0 int8
/model.9/m_1/MaxPool BPU id(0) HzQuantizedMaxPool -- 1.0 int8
/model.9/m_2/MaxPool BPU id(0) HzQuantizedMaxPool -- 1.0 int8
/model.9/Concat BPU id(0) Concat -- 1.0 int8
/model.9/cv2/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.9/cv2/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.9/Add BPU id(0) HzSElementwiseAdd -- 1.0 int8
/model.10/cv1/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.10/cv1/act/Mul BPU id(0) HzLut -- 1.0 int8
/model.10/Split BPU id(0) Split -- 1.0 int8
/model.10/m/m.0/attn/qkv/conv/Conv BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.10/m/m.0/attn/Reshape BPU id(0) Reshape -- 1.0 int8
/model.10/m/m.0/attn/Split BPU id(0) Split -- 1.0 int8
/model.10/m/m.0/attn/Mul BPU id(0) HzSQuantizedConv -- 1.0 int8
/model.10/m/m.0/attn/Reshape_2 BPU id(0) Reshape -- 1.0 int8
/model.10/m/m.0/attn/Transpose BPU id(0) Transpose -- 1.0 int8
/model.10/m/m.0/attn/MatMul BPU id(0) HzSQuantizedMatmul -- 1.0 int8
/model.10/m/m.0/attn/Softmax CPU -- Softmax -- -- float
/model.10/m/m.0/attn/Transpose_1 BPU id(1) Transpose -- -- int8
/model.10/m/m.0/attn/MatMul_1 BPU id(1) HzSQuantizedMatmul -- 1.0 int8
/model.10/m/m.0/attn/Reshape_1 BPU id(1) Reshape -- 1.0 int8
/model.10/m/m.0/attn/pe/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.10/m/m.0/attn/proj/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.10/m/m.0/ffn/ffn.0/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.10/m/m.0/ffn/ffn.0/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.10/m/m.0/ffn/ffn.1/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.10/Concat BPU id(1) Concat -- 1.0 int8
/model.10/cv2/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.10/cv2/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.11/Resize BPU id(1) HzQuantizedResizeUpsample -- 1.0 int8
/model.12/Concat BPU id(1) Concat -- 1.0 int8
/model.13/cv1/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.13/cv1/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.13/Split BPU id(1) Split -- 1.0 int8
/model.13/m.0/cv1/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.13/m.0/cv2/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.13/m.0/cv1/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.13/m.0/cv2/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.13/m.0/m/m.0/cv1/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.13/m.0/m/m.0/cv1/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.13/m.0/m/m.0/cv2/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.13/m.0/m/m.0/cv2/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.13/m.0/m/m.0/Add BPU id(1) HzSElementwiseAdd -- 1.0 int8
/model.13/m.0/m/m.1/cv1/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.13/m.0/m/m.1/cv1/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.13/m.0/m/m.1/cv2/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.13/m.0/m/m.1/cv2/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.13/m.0/m/m.1/Add BPU id(1) HzSElementwiseAdd -- 1.0 int8
/model.13/m.0/Concat BPU id(1) Concat -- 1.0 int8
/model.13/m.0/cv3/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.13/m.0/cv3/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.13/Concat BPU id(1) Concat -- 1.0 int8
/model.13/cv2/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.13/cv2/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.14/Resize BPU id(1) HzQuantizedResizeUpsample -- 1.0 int8
/model.15/Concat BPU id(1) Concat -- 1.0 int8
/model.16/cv1/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.16/cv1/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.16/Split BPU id(1) Split -- 1.0 int8
/model.16/m.0/cv1/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.16/m.0/cv2/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.16/m.0/cv1/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.16/m.0/cv2/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.16/m.0/m/m.0/cv1/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.16/m.0/m/m.0/cv1/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.16/m.0/m/m.0/cv2/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.16/m.0/m/m.0/cv2/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.16/m.0/m/m.0/Add BPU id(1) HzSElementwiseAdd -- 1.0 int8
/model.16/m.0/m/m.1/cv1/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.16/m.0/m/m.1/cv1/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.16/m.0/m/m.1/cv2/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.16/m.0/m/m.1/cv2/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.16/m.0/m/m.1/Add BPU id(1) HzSElementwiseAdd -- 1.0 int8
/model.16/m.0/Concat BPU id(1) Concat -- 1.0 int8
/model.16/m.0/cv3/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.16/m.0/cv3/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.16/Concat BPU id(1) Concat -- 1.0 int8
/model.16/cv2/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.16/cv2/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.17/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.23/one2one_cv2.0/one2one_cv2.0.0/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
...3.0/one2one_cv3.0.0/one2one_cv3.0.0.0/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.17/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.23/one2one_cv2.0/one2one_cv2.0.0/act/Mul BPU id(1) HzLut -- 1.0 int8
...cv3.0/one2one_cv3.0.0/one2one_cv3.0.0.0/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.18/Concat BPU id(1) Concat -- 1.0 int8
/model.23/one2one_cv2.0/one2one_cv2.0.1/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
...3.0/one2one_cv3.0.0/one2one_cv3.0.0.1/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.19/cv1/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.23/one2one_cv2.0/one2one_cv2.0.1/act/Mul BPU id(1) HzLut -- 1.0 int8
...cv3.0/one2one_cv3.0.0/one2one_cv3.0.0.1/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.19/cv1/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.23/one2one_cv2.0/one2one_cv2.0.2/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
...3.0/one2one_cv3.0.1/one2one_cv3.0.1.0/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.19/Split BPU id(1) Split -- 1.0 int8
/model.19/m.0/cv1/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.19/m.0/cv2/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
...cv3.0/one2one_cv3.0.1/one2one_cv3.0.1.0/act/Mul BPU id(1) HzLut -- 1.0 int8
...3.0/one2one_cv3.0.1/one2one_cv3.0.1.1/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.19/m.0/cv1/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.19/m.0/cv2/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.19/m.0/m/m.0/cv1/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
...cv3.0/one2one_cv3.0.1/one2one_cv3.0.1.1/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.23/one2one_cv3.0/one2one_cv3.0.2/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.19/m.0/m/m.0/cv1/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.19/m.0/m/m.0/cv2/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.19/m.0/m/m.0/cv2/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.19/m.0/m/m.0/Add BPU id(1) HzSElementwiseAdd -- 1.0 int8
/model.19/m.0/m/m.1/cv1/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.19/m.0/m/m.1/cv1/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.19/m.0/m/m.1/cv2/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.19/m.0/m/m.1/cv2/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.19/m.0/m/m.1/Add BPU id(1) HzSElementwiseAdd -- 1.0 int8
/model.19/m.0/Concat BPU id(1) Concat -- 1.0 int8
/model.19/m.0/cv3/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.19/m.0/cv3/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.19/Concat BPU id(1) Concat -- 1.0 int8
/model.19/cv2/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.19/cv2/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.20/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.23/one2one_cv2.1/one2one_cv2.1.0/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
...3.1/one2one_cv3.1.0/one2one_cv3.1.0.0/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.20/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.23/one2one_cv2.1/one2one_cv2.1.0/act/Mul BPU id(1) HzLut -- 1.0 int8
...cv3.1/one2one_cv3.1.0/one2one_cv3.1.0.0/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.21/Concat BPU id(1) Concat -- 1.0 int8
/model.23/one2one_cv2.1/one2one_cv2.1.1/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
...3.1/one2one_cv3.1.0/one2one_cv3.1.0.1/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.22/cv1/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.23/one2one_cv2.1/one2one_cv2.1.1/act/Mul BPU id(1) HzLut -- 1.0 int8
...cv3.1/one2one_cv3.1.0/one2one_cv3.1.0.1/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.22/cv1/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.23/one2one_cv2.1/one2one_cv2.1.2/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
...3.1/one2one_cv3.1.1/one2one_cv3.1.1.0/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.22/Split BPU id(1) Split -- 1.0 int8
/model.22/m.0/m.0.0/cv1/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
...cv3.1/one2one_cv3.1.1/one2one_cv3.1.1.0/act/Mul BPU id(1) HzLut -- 1.0 int8
...3.1/one2one_cv3.1.1/one2one_cv3.1.1.1/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.22/m.0/m.0.0/cv1/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.22/m.0/m.0.0/cv2/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
...cv3.1/one2one_cv3.1.1/one2one_cv3.1.1.1/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.23/one2one_cv3.1/one2one_cv3.1.2/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.22/m.0/m.0.0/cv2/act/Mul BPU id(1) HzLut -- 1.0 int8
/model.22/m.0/m.0.0/Add BPU id(1) HzSElementwiseAdd -- 1.0 int8
/model.22/m.0/m.0.1/attn/qkv/conv/Conv BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.22/m.0/m.0.1/attn/Reshape BPU id(1) Reshape -- 1.0 int8
/model.22/m.0/m.0.1/attn/Split BPU id(1) Split -- 1.0 int8
/model.22/m.0/m.0.1/attn/Mul BPU id(1) HzSQuantizedConv -- 1.0 int8
/model.22/m.0/m.0.1/attn/Reshape_2 BPU id(1) Reshape -- 1.0 int8
/model.22/m.0/m.0.1/attn/Transpose BPU id(1) Transpose -- 1.0 int8
/model.22/m.0/m.0.1/attn/MatMul BPU id(1) HzSQuantizedMatmul -- 1.0 int8
/model.22/m.0/m.0.1/attn/Softmax CPU -- Softmax -- -- float
/model.22/m.0/m.0.1/attn/Transpose_1 BPU id(2) Transpose -- -- int8
/model.22/m.0/m.0.1/attn/MatMul_1 BPU id(2) HzSQuantizedMatmul -- 1.0 int8
/model.22/m.0/m.0.1/attn/Reshape_1 BPU id(2) Reshape -- 1.0 int8
/model.22/m.0/m.0.1/attn/pe/conv/Conv BPU id(2) HzSQuantizedConv -- 1.0 int8
/model.22/m.0/m.0.1/attn/proj/conv/Conv BPU id(2) HzSQuantizedConv -- 1.0 int8
/model.22/m.0/m.0.1/ffn/ffn.0/conv/Conv BPU id(2) HzSQuantizedConv -- 1.0 int8
/model.22/m.0/m.0.1/ffn/ffn.0/act/Mul BPU id(2) HzLut -- 1.0 int8
/model.22/m.0/m.0.1/ffn/ffn.1/conv/Conv BPU id(2) HzSQuantizedConv -- 1.0 int8
/model.22/Concat BPU id(2) Concat -- 1.0 int8
/model.22/cv2/conv/Conv BPU id(2) HzSQuantizedConv -- 1.0 int8
/model.22/cv2/act/Mul BPU id(2) HzLut -- 1.0 int8
/model.23/one2one_cv2.2/one2one_cv2.2.0/conv/Conv BPU id(2) HzSQuantizedConv -- 1.0 int8
...3.2/one2one_cv3.2.0/one2one_cv3.2.0.0/conv/Conv BPU id(2) HzSQuantizedConv -- 1.0 int8
/model.23/one2one_cv2.2/one2one_cv2.2.0/act/Mul BPU id(2) HzLut -- 1.0 int8
...cv3.2/one2one_cv3.2.0/one2one_cv3.2.0.0/act/Mul BPU id(2) HzLut -- 1.0 int8
/model.23/one2one_cv2.2/one2one_cv2.2.1/conv/Conv BPU id(2) HzSQuantizedConv -- 1.0 int8
...3.2/one2one_cv3.2.0/one2one_cv3.2.0.1/conv/Conv BPU id(2) HzSQuantizedConv -- 1.0 int8
/model.23/one2one_cv2.2/one2one_cv2.2.1/act/Mul BPU id(2) HzLut -- 1.0 int8
...cv3.2/one2one_cv3.2.0/one2one_cv3.2.0.1/act/Mul BPU id(2) HzLut -- 1.0 int8
/model.23/one2one_cv2.2/one2one_cv2.2.2/Conv BPU id(2) HzSQuantizedConv -- 1.0 int8
...3.2/one2one_cv3.2.1/one2one_cv3.2.1.0/conv/Conv BPU id(2) HzSQuantizedConv -- 1.0 int8
...cv3.2/one2one_cv3.2.1/one2one_cv3.2.1.0/act/Mul BPU id(2) HzLut -- 1.0 int8
...3.2/one2one_cv3.2.1/one2one_cv3.2.1.1/conv/Conv BPU id(2) HzSQuantizedConv -- 1.0 int8
...cv3.2/one2one_cv3.2.1/one2one_cv3.2.1.1/act/Mul BPU id(2) HzLut -- 1.0 int8
/model.23/one2one_cv3.2/one2one_cv3.2.2/Conv BPU id(2) HzSQuantizedConv -- 1.0 int8
2026-08-07 10:39:51,565 file: print_info_dict.py func: print_info_dict line No: 72 The quantized model output:
============
Output
------------
2026-08-07 10:39:51,573 file: model_builder.py func: model_builder line No: 38 End to Horizon NN Model Convert.
2026-08-07 10:39:51,574 file: onnx2horizonrt.py func: onnx2horizonrt line No: 4326 ONNX model output num : 6
2026-08-07 10:39:51,577 file: onnx2horizonrt.py func: onnx2horizonrt line No: 4060 model_deps_info: {'hb_mapper_version': '1.24.3'}
2026-08-07 10:39:51,580 file: hb_mapper_checker.py func: hb_mapper_checker line No: 170 End model checking....

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1,213 @@
{
"summary": {
"BPU OPs per frame (effective)": 2940160000,
"BPU OPs per run (effective)": 2940160000,
"BPU PE number": 1,
"BPU core number": 1,
"BPU march": "B25E",
"DDR bytes per frame": 122035200,
"DDR bytes per run": 122035200,
"DDR bytes per second": 6401297850,
"DDR megabytes per frame": 116.382,
"DDR megabytes per run": 116.382,
"DDR megabytes per second": 6104.8,
"FPS": 52.45,
"HBDK version": "3.49.15",
"compiling options": "-f hbir -m /tmp/tmpo3cnuwll/Extracted from {main_graph}_subgraph_0.hbir -o /tmp/tmpo3cnuwll/Extracted from {main_graph}_subgraph_0.hbm --march bayes-e --progressbar --input-layout NHWC --output-layout NHWC",
"frame per run": 1,
"frame per second": 52.45,
"input features": [
[
"input name",
"input size"
],
[
"images_calibrated_quantized",
"1x3x640x640"
]
],
"interval computing unit utilization": [
0.206,
0.136,
0.068,
0.095,
0.104,
0.052,
0.167,
0.104,
0.082,
0.094,
0.052,
0.116,
0.091,
0.078,
0.139,
0.247,
0.104,
0.142,
0.077,
0.194,
0.256,
0.115,
0.256,
0.164,
0.162,
0.161,
0.072,
0.12,
0.106,
0.147,
0.098,
0.086,
0.109,
0.27,
0.17,
0.084,
0.031,
0.084,
0.021
],
"interval computing units utilization": [
0.206,
0.136,
0.068,
0.095,
0.104,
0.052,
0.167,
0.104,
0.082,
0.094,
0.052,
0.116,
0.091,
0.078,
0.139,
0.247,
0.104,
0.142,
0.077,
0.194,
0.256,
0.115,
0.256,
0.164,
0.162,
0.161,
0.072,
0.12,
0.106,
0.147,
0.098,
0.086,
0.109,
0.27,
0.17,
0.084,
0.031,
0.084,
0.021
],
"interval loading bandwidth (megabytes/s)": [
1567,
2772,
3728,
3375,
3253,
3419,
3569,
3332,
3128,
3129,
3537,
3324,
3110,
3711,
3551,
2800,
2935,
3320,
3151,
3267,
2933,
2795,
3095,
3004,
3036,
3189,
3001,
3210,
3715,
2631,
1875,
2797,
3808,
4172,
3242,
2191,
2842,
3508,
1912
],
"interval number": 39,
"interval storing bandwidth (megabytes/s)": [
4079,
3124,
2647,
3125,
3125,
3125,
2729,
2767,
3276,
3279,
2977,
3140,
3215,
2768,
2770,
2887,
2803,
2794,
3141,
2869,
2425,
2636,
2421,
2226,
2437,
2483,
3134,
3174,
2502,
3435,
4276,
3652,
2602,
1582,
2150,
3870,
3841,
3115,
1647
],
"interval time (ms)": 0.5,
"latency (ms)": 19.06,
"latency (ms) by segments": [
19.064
],
"latency (us)": 19064.1,
"loaded bytes per frame": 63139840,
"loaded bytes per run": 63139840,
"model json CRC": "4bd1303b",
"model json file": "/tmp/tmpo3cnuwll/Extracted from {main_graph}_subgraph_0.hbir",
"model name": "Extracted from {main_graph}_subgraph_0",
"model param CRC": "00000000",
"multicore sync time (ms)": 0.0,
"run per second": 52.45,
"runtime version": "3.15.55.0",
"stored bytes per frame": 58895360,
"stored bytes per run": 58895360,
"worst FPS": 52.45
}
}

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1,257 @@
{
"summary": {
"BPU OPs per frame (effective)": 2136627200,
"BPU OPs per run (effective)": 2136627200,
"BPU PE number": 1,
"BPU core number": 1,
"BPU march": "B25E",
"DDR bytes per frame": 138583616,
"DDR bytes per run": 138583616,
"DDR bytes per second": 6348938021,
"DDR megabytes per frame": 132.164,
"DDR megabytes per run": 132.164,
"DDR megabytes per second": 6054.8,
"FPS": 45.81,
"HBDK version": "3.49.15",
"compiling options": "-f hbir -m /tmp/tmpo3cnuwll/Extracted from {main_graph}_subgraph_1.hbir -o /tmp/tmpo3cnuwll/Extracted from {main_graph}_subgraph_1.hbm --march bayes-e --progressbar --input-layout NHWC --output-layout NHWC",
"frame per run": 1,
"frame per second": 45.81,
"input features": [
[
"input name",
"input size"
],
[
"/model.10/m/m.0/attn/Transpose_1_output_0_calibrated_quantized",
"1x2x400x400"
],
[
"/model.10/m/m.0/attn/Split_nhwc2nchw_transposed_output2",
"1x2x64x400"
],
[
"/model.10/m/m.0/attn/pe/conv/Conv_nchw2nhwc_transposed_input0",
"1x20x20x128"
],
[
"/model.10/Split_output_1_quantized",
"1x20x20x128"
],
[
"/model.10/Split_output_0_quantized",
"1x20x20x128"
],
[
"/model.6/cv2/act/Mul_output_0_quantized",
"1x40x40x128"
],
[
"/model.4/cv2/act/Mul_output_0_quantized",
"1x80x80x128"
]
],
"interval computing unit utilization": [
0.101,
0.101,
0.199,
0.154,
0.112,
0.108,
0.101,
0.079,
0.106,
0.185,
0.096,
0.355,
0.093,
0.139,
0.152,
0.124,
0.185,
0.039,
0.128,
0.103,
0.117,
0.112,
0.085,
0.148,
0.134,
0.137,
0.16,
0.172,
0.132,
0.178,
0.172,
0.155,
0.041,
0.159,
0.132,
0.102,
0.108,
0.106,
0.092,
0.258,
0.211,
0.005,
0.068,
0.063
],
"interval computing units utilization": [
0.101,
0.101,
0.199,
0.154,
0.112,
0.108,
0.101,
0.079,
0.106,
0.185,
0.096,
0.355,
0.093,
0.139,
0.152,
0.124,
0.185,
0.039,
0.128,
0.103,
0.117,
0.112,
0.085,
0.148,
0.134,
0.137,
0.16,
0.172,
0.132,
0.178,
0.172,
0.155,
0.041,
0.159,
0.132,
0.102,
0.108,
0.106,
0.092,
0.258,
0.211,
0.005,
0.068,
0.063
],
"interval loading bandwidth (megabytes/s)": [
3201,
2992,
2422,
1226,
830,
2343,
3369,
3361,
3314,
4400,
5767,
4176,
2968,
3160,
3091,
3270,
2892,
2888,
3125,
3881,
3804,
3113,
3257,
3351,
3364,
3170,
3187,
3041,
2923,
3186,
3201,
3079,
3135,
3143,
3389,
1956,
1806,
3369,
4712,
4296,
1800,
2998,
3677,
2265
],
"interval number": 44,
"interval storing bandwidth (megabytes/s)": [
3021,
3283,
3521,
4563,
5338,
3978,
2983,
3096,
3125,
1674,
351,
1289,
2402,
2939,
2861,
2539,
2782,
3369,
3389,
2392,
2421,
2929,
2929,
2832,
2636,
2832,
2645,
2539,
2726,
2529,
2333,
2513,
3134,
3191,
2505,
4209,
4556,
2963,
1693,
1549,
3476,
3214,
3125,
3059
],
"interval time (ms)": 0.5,
"latency (ms)": 21.83,
"latency (ms) by segments": [
21.828
],
"latency (us)": 21827.8,
"loaded bytes per frame": 72009792,
"loaded bytes per run": 72009792,
"model json CRC": "f7a1faaa",
"model json file": "/tmp/tmpo3cnuwll/Extracted from {main_graph}_subgraph_1.hbir",
"model name": "Extracted from {main_graph}_subgraph_1",
"model param CRC": "00000000",
"multicore sync time (ms)": 0.0,
"run per second": 45.81,
"runtime version": "3.15.55.0",
"stored bytes per frame": 66573824,
"stored bytes per run": 66573824,
"worst FPS": 45.81
}
}

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1,221 @@
{
"summary": {
"BPU OPs per frame (effective)": 236339200,
"BPU OPs per run (effective)": 236339200,
"BPU PE number": 1,
"BPU core number": 1,
"BPU march": "B25E",
"DDR bytes per frame": 44277504,
"DDR bytes per run": 44277504,
"DDR bytes per second": 6318416482,
"DDR megabytes per frame": 42.226,
"DDR megabytes per run": 42.226,
"DDR megabytes per second": 6025.7,
"FPS": 142.7,
"HBDK version": "3.49.15",
"compiling options": "-f hbir -m /tmp/tmpo3cnuwll/Extracted from {main_graph}_subgraph_2.hbir -o /tmp/tmpo3cnuwll/Extracted from {main_graph}_subgraph_2.hbm --march bayes-e --progressbar --input-layout NHWC --output-layout NHWC",
"frame per run": 1,
"frame per second": 142.7,
"input features": [
[
"input name",
"input size"
],
[
"/model.22/m.0/m.0.1/attn/Transpose_1_output_0_calibrated_quantized",
"1x2x400x400"
],
[
"/model.22/m.0/m.0.1/attn/Split_nhwc2nchw_transposed_output2",
"1x2x64x400"
],
[
"/model.22/m.0/m.0.1/attn/pe/conv/Conv_nchw2nhwc_transposed_input0",
"1x20x20x128"
],
[
"/model.22/m.0/m.0.0/Add_output_0_quantized",
"1x20x20x128"
],
[
"/model.22/Split_output_0_quantized",
"1x20x20x128"
],
[
"/model.22/Split_output_1_quantized",
"1x20x20x128"
]
],
"interval computing unit utilization": [
0.062,
0.124,
0.098,
0.168,
0.05,
0.267,
0.229,
0.072,
0.12,
0.192,
0.192,
0.0,
0.088,
0.092,
0.179,
0.092,
0.087,
0.088,
0.092,
0.092,
0.179,
0.087,
0.0,
0.231,
0.231,
0.0,
0.231,
0.231,
0.615,
0.053,
0.08,
0.094,
0.137,
0.202,
0.122,
0.015
],
"interval computing units utilization": [
0.062,
0.124,
0.098,
0.168,
0.05,
0.267,
0.229,
0.072,
0.12,
0.192,
0.192,
0.0,
0.088,
0.092,
0.179,
0.092,
0.087,
0.088,
0.092,
0.092,
0.179,
0.087,
0.0,
0.231,
0.231,
0.0,
0.231,
0.231,
0.615,
0.053,
0.08,
0.094,
0.137,
0.202,
0.122,
0.015
],
"interval loading bandwidth (megabytes/s)": [
3916,
3024,
3019,
2929,
2502,
3547,
2578,
800,
244,
244,
488,
479,
2166,
3848,
3448,
2996,
2807,
3103,
3678,
3833,
3401,
2827,
4333,
5733,
5182,
5985,
6007,
4590,
2693,
2304,
3413,
3548,
3477,
3290,
3187,
1519
],
"interval number": 36,
"interval storing bandwidth (megabytes/s)": [
2539,
3234,
3166,
3147,
3772,
2322,
2589,
5149,
6193,
5762,
5251,
5956,
4636,
2612,
2683,
3135,
3654,
3371,
2780,
2612,
2730,
3320,
2469,
573,
292,
313,
292,
858,
1367,
2343,
3125,
2783,
2490,
2294,
2157,
1165
],
"interval time (ms)": 0.2,
"latency (ms)": 7.01,
"latency (ms) by segments": [
7.008
],
"latency (us)": 7007.7,
"loaded bytes per frame": 22904576,
"loaded bytes per run": 22904576,
"model json CRC": "29e36293",
"model json file": "/tmp/tmpo3cnuwll/Extracted from {main_graph}_subgraph_2.hbir",
"model name": "Extracted from {main_graph}_subgraph_2",
"model param CRC": "00000000",
"multicore sync time (ms)": 0.0,
"run per second": 142.7,
"runtime version": "3.15.55.0",
"stored bytes per frame": 21372928,
"stored bytes per run": 21372928,
"worst FPS": 142.7
}
}

Binary file not shown.

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1,213 @@
{
"summary": {
"BPU OPs per frame (effective)": 2940160000,
"BPU OPs per run (effective)": 2940160000,
"BPU PE number": 1,
"BPU core number": 1,
"BPU march": "B25E",
"DDR bytes per frame": 122035200,
"DDR bytes per run": 122035200,
"DDR bytes per second": 6401297850,
"DDR megabytes per frame": 116.382,
"DDR megabytes per run": 116.382,
"DDR megabytes per second": 6104.8,
"FPS": 52.45,
"HBDK version": "3.49.15",
"compiling options": "-f hbir -m /tmp/tmp0plq7oph/main_graph_subgraph_0.hbir -o /tmp/tmp0plq7oph/main_graph_subgraph_0.hbm --march bayes-e --progressbar --input-layout NHWC --output-layout NHWC",
"frame per run": 1,
"frame per second": 52.45,
"input features": [
[
"input name",
"input size"
],
[
"images_calibrated_quantized",
"1x3x640x640"
]
],
"interval computing unit utilization": [
0.206,
0.136,
0.068,
0.095,
0.104,
0.052,
0.167,
0.104,
0.082,
0.094,
0.052,
0.116,
0.091,
0.078,
0.139,
0.247,
0.104,
0.142,
0.077,
0.194,
0.256,
0.115,
0.256,
0.164,
0.162,
0.161,
0.072,
0.12,
0.106,
0.147,
0.098,
0.086,
0.109,
0.27,
0.17,
0.084,
0.031,
0.084,
0.021
],
"interval computing units utilization": [
0.206,
0.136,
0.068,
0.095,
0.104,
0.052,
0.167,
0.104,
0.082,
0.094,
0.052,
0.116,
0.091,
0.078,
0.139,
0.247,
0.104,
0.142,
0.077,
0.194,
0.256,
0.115,
0.256,
0.164,
0.162,
0.161,
0.072,
0.12,
0.106,
0.147,
0.098,
0.086,
0.109,
0.27,
0.17,
0.084,
0.031,
0.084,
0.021
],
"interval loading bandwidth (megabytes/s)": [
1567,
2772,
3728,
3375,
3253,
3419,
3569,
3332,
3128,
3129,
3537,
3324,
3110,
3711,
3551,
2800,
2935,
3320,
3151,
3267,
2933,
2795,
3095,
3004,
3036,
3189,
3001,
3210,
3715,
2631,
1875,
2797,
3808,
4172,
3242,
2191,
2842,
3508,
1912
],
"interval number": 39,
"interval storing bandwidth (megabytes/s)": [
4079,
3124,
2647,
3125,
3125,
3125,
2729,
2767,
3276,
3279,
2977,
3140,
3215,
2768,
2770,
2887,
2803,
2794,
3141,
2869,
2425,
2636,
2421,
2226,
2437,
2483,
3134,
3174,
2502,
3435,
4276,
3652,
2602,
1582,
2150,
3870,
3841,
3115,
1647
],
"interval time (ms)": 0.5,
"latency (ms)": 19.06,
"latency (ms) by segments": [
19.064
],
"latency (us)": 19064.1,
"loaded bytes per frame": 63139840,
"loaded bytes per run": 63139840,
"model json CRC": "4bd1303b",
"model json file": "/tmp/tmp0plq7oph/main_graph_subgraph_0.hbir",
"model name": "main_graph_subgraph_0",
"model param CRC": "00000000",
"multicore sync time (ms)": 0.0,
"run per second": 52.45,
"runtime version": "3.15.55.0",
"stored bytes per frame": 58895360,
"stored bytes per run": 58895360,
"worst FPS": 52.45
}
}

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1,273 @@
{
"summary": {
"BPU OPs per frame (effective)": 2136627200,
"BPU OPs per run (effective)": 2136627200,
"BPU PE number": 1,
"BPU core number": 1,
"BPU march": "B25E",
"DDR bytes per frame": 149824064,
"DDR bytes per run": 149824064,
"DDR bytes per second": 6365457415,
"DDR megabytes per frame": 142.883,
"DDR megabytes per run": 142.883,
"DDR megabytes per second": 6070.6,
"FPS": 42.49,
"HBDK version": "3.49.15",
"compiling options": "-f hbir -m /tmp/tmp0plq7oph/main_graph_subgraph_1.hbir -o /tmp/tmp0plq7oph/main_graph_subgraph_1.hbm --march bayes-e --progressbar --input-layout NHWC --output-layout NHWC",
"frame per run": 1,
"frame per second": 42.49,
"input features": [
[
"input name",
"input size"
],
[
"/model.10/m/m.0/attn/Transpose_1_output_0_calibrated_quantized",
"1x2x400x400"
],
[
"/model.10/m/m.0/attn/Split_nhwc2nchw_transposed_output2",
"1x2x64x400"
],
[
"/model.10/m/m.0/attn/pe/conv/Conv_nchw2nhwc_transposed_input0",
"1x20x20x128"
],
[
"/model.10/Split_output_1_quantized",
"1x20x20x128"
],
[
"/model.10/Split_output_0_quantized",
"1x20x20x128"
],
[
"/model.6/cv2/act/Mul_output_0_quantized",
"1x40x40x128"
],
[
"/model.4/cv2/act/Mul_output_0_quantized",
"1x80x80x128"
]
],
"interval computing unit utilization": [
0.101,
0.101,
0.199,
0.154,
0.112,
0.108,
0.101,
0.079,
0.106,
0.185,
0.096,
0.355,
0.093,
0.139,
0.152,
0.124,
0.185,
0.039,
0.128,
0.103,
0.117,
0.112,
0.085,
0.148,
0.134,
0.137,
0.093,
0.163,
0.118,
0.124,
0.173,
0.106,
0.219,
0.144,
0.157,
0.064,
0.128,
0.1,
0.186,
0.072,
0.108,
0.126,
0.226,
0.159,
0.084,
0.031,
0.084,
0.021
],
"interval computing units utilization": [
0.101,
0.101,
0.199,
0.154,
0.112,
0.108,
0.101,
0.079,
0.106,
0.185,
0.096,
0.355,
0.093,
0.139,
0.152,
0.124,
0.185,
0.039,
0.128,
0.103,
0.117,
0.112,
0.085,
0.148,
0.134,
0.137,
0.093,
0.163,
0.118,
0.124,
0.173,
0.106,
0.219,
0.144,
0.157,
0.064,
0.128,
0.1,
0.186,
0.072,
0.108,
0.126,
0.226,
0.159,
0.084,
0.031,
0.084,
0.021
],
"interval loading bandwidth (megabytes/s)": [
3201,
2992,
2422,
1226,
830,
2343,
3369,
3361,
3314,
4400,
5767,
4176,
2968,
3160,
3091,
3270,
2892,
2888,
3125,
3881,
3804,
3113,
3257,
3351,
3364,
3207,
2952,
3133,
3392,
2887,
2981,
3392,
3286,
3127,
3018,
2975,
3132,
3628,
2591,
1769,
2832,
3808,
4208,
3242,
2314,
3034,
3506,
1721
],
"interval number": 48,
"interval storing bandwidth (megabytes/s)": [
3021,
3283,
3521,
4563,
5338,
3978,
2983,
3096,
3125,
1674,
351,
1289,
2402,
2939,
2861,
2539,
2782,
3369,
3389,
2392,
2421,
2929,
2929,
2832,
2636,
2788,
3193,
2944,
2573,
3218,
2852,
2454,
2415,
2336,
2602,
3137,
3250,
2570,
3364,
4348,
3632,
2462,
1638,
2343,
3786,
3648,
3115,
1647
],
"interval time (ms)": 0.5,
"latency (ms)": 23.54,
"latency (ms) by segments": [
23.537
],
"latency (us)": 23537.0,
"loaded bytes per frame": 77695040,
"loaded bytes per run": 77695040,
"model json CRC": "d4eae3d3",
"model json file": "/tmp/tmp0plq7oph/main_graph_subgraph_1.hbir",
"model name": "main_graph_subgraph_1",
"model param CRC": "00000000",
"multicore sync time (ms)": 0.0,
"run per second": 42.49,
"runtime version": "3.15.55.0",
"stored bytes per frame": 72129024,
"stored bytes per run": 72129024,
"worst FPS": 42.49
}
}

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1,191 @@
{
"summary": {
"BPU OPs per frame (effective)": 236339200,
"BPU OPs per run (effective)": 236339200,
"BPU PE number": 1,
"BPU core number": 1,
"BPU march": "B25E",
"DDR bytes per frame": 69526848,
"DDR bytes per run": 69526848,
"DDR bytes per second": 6007224548,
"DDR megabytes per frame": 66.306,
"DDR megabytes per run": 66.306,
"DDR megabytes per second": 5728.9,
"FPS": 86.4,
"HBDK version": "3.49.15",
"compiling options": "-f hbir -m /tmp/tmp0plq7oph/main_graph_subgraph_2.hbir -o /tmp/tmp0plq7oph/main_graph_subgraph_2.hbm --march bayes-e --progressbar --input-layout NHWC --output-layout NHWC",
"frame per run": 1,
"frame per second": 86.4,
"input features": [
[
"input name",
"input size"
],
[
"/model.22/m.0/m.0.1/attn/Transpose_1_output_0_calibrated_quantized",
"1x2x400x400"
],
[
"/model.22/m.0/m.0.1/attn/Split_nhwc2nchw_transposed_output2",
"1x2x64x400"
],
[
"/model.22/m.0/m.0.1/attn/pe/conv/Conv_nchw2nhwc_transposed_input0",
"1x20x20x128"
],
[
"/model.22/m.0/m.0.0/Add_output_0_quantized",
"1x20x20x128"
],
[
"/model.22/Split_output_0_quantized",
"1x20x20x128"
],
[
"/model.22/Split_output_1_quantized",
"1x20x20x128"
],
[
"/model.23/Reshape_output_0_quantized",
"1x1x4x6400"
],
[
"/model.23/Reshape_1_output_0_quantized",
"1x1x4x1600"
],
[
"/model.23/Reshape_3_output_0_quantized",
"1x1x4x6400"
],
[
"/model.23/Reshape_4_output_0_quantized",
"1x1x4x1600"
]
],
"interval computing unit utilization": [
0.101,
0.101,
0.199,
0.154,
0.112,
0.108,
0.101,
0.079,
0.106,
0.185,
0.096,
0.355,
0.093,
0.157,
0.081,
0.075,
0.081,
0.088,
0.306,
0.215,
0.665,
0.293,
0.186,
0.04
],
"interval computing units utilization": [
0.101,
0.101,
0.199,
0.154,
0.112,
0.108,
0.101,
0.079,
0.106,
0.185,
0.096,
0.355,
0.093,
0.157,
0.081,
0.075,
0.081,
0.088,
0.306,
0.215,
0.665,
0.293,
0.186,
0.04
],
"interval loading bandwidth (megabytes/s)": [
3201,
2992,
2422,
1226,
830,
2343,
3369,
3361,
3314,
4400,
5767,
4176,
2968,
3307,
3182,
3782,
3875,
3431,
2435,
2139,
2077,
1788,
2890,
1952
],
"interval number": 24,
"interval storing bandwidth (megabytes/s)": [
3021,
3283,
3521,
4563,
5338,
3978,
2983,
3096,
3125,
1674,
351,
1289,
2402,
2529,
2602,
2379,
2306,
2694,
2816,
2836,
1861,
1879,
2413,
1197
],
"interval time (ms)": 0.5,
"latency (ms)": 11.57,
"latency (ms) by segments": [
11.479,
0.0,
0.095
],
"latency (us)": 11573.9,
"loaded bytes per frame": 36598144,
"loaded bytes per run": 36598144,
"model json CRC": "7202325c",
"model json file": "/tmp/tmp0plq7oph/main_graph_subgraph_2.hbir",
"model name": "main_graph_subgraph_2",
"model param CRC": "00000000",
"multicore sync time (ms)": 0.0,
"run per second": 86.4,
"runtime version": "3.15.55.0",
"stored bytes per frame": 32928704,
"stored bytes per run": 32928704,
"worst FPS": 86.4
}
}

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1,86 @@
{
"summary": {
"BPU PE number": 1,
"BPU core number": 1,
"BPU march": "B25E",
"DDR bytes per frame": 1396800,
"DDR bytes per run": 1396800,
"DDR bytes per second": 5072300619,
"DDR megabytes per frame": 1.332,
"DDR megabytes per run": 1.332,
"DDR megabytes per second": 4837.3,
"FPS": 3631.37,
"HBDK version": "3.49.15",
"compiling options": "-f hbir -m /tmp/tmp0plq7oph/main_graph_subgraph_3.hbir -o /tmp/tmp0plq7oph/main_graph_subgraph_3.hbm --march bayes-e --progressbar --input-layout NHWC --output-layout NHWC",
"frame per run": 1,
"frame per second": 3631.37,
"input features": [
[
"input name",
"input size"
],
[
"/model.23/Split_output_1_quantized",
"1x1x8400x4"
],
[
"/model.23/Expand_output_0_/model.23/GatherElements_cast_input",
"1x1x300x4"
]
],
"interval computing unit utilization": [
0.403,
0.101,
0.194,
0.187,
0.317,
0.11
],
"interval computing units utilization": [
0.403,
0.101,
0.194,
0.187,
0.317,
0.11
],
"interval loading bandwidth (megabytes/s)": [
1831,
2380,
3024,
2792,
2317,
1639
],
"interval number": 6,
"interval storing bandwidth (megabytes/s)": [
1975,
2642,
2857,
2262,
2158,
1603
],
"interval time (ms)": 0.05,
"latency (ms)": 0.28,
"latency (ms) by segments": [
0.0,
0.157,
0.0,
0.118
],
"latency (us)": 275.4,
"loaded bytes per frame": 714368,
"loaded bytes per run": 714368,
"model json CRC": "d2eeed26",
"model json file": "/tmp/tmp0plq7oph/main_graph_subgraph_3.hbir",
"model name": "main_graph_subgraph_3",
"model param CRC": "00000000",
"multicore sync time (ms)": 0.0,
"run per second": 3631.37,
"runtime version": "3.15.55.0",
"stored bytes per frame": 682432,
"stored bytes per run": 682432,
"worst FPS": 3631.37
}
}

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1,100 @@
{
"summary": {
"BPU PE number": 1,
"BPU core number": 1,
"BPU march": "B25E",
"DDR bytes per frame": 120960,
"DDR bytes per run": 120960,
"DDR bytes per second": 3114475513,
"DDR megabytes per frame": 0.115,
"DDR megabytes per run": 0.115,
"DDR megabytes per second": 2970.2,
"FPS": 25747.98,
"HBDK version": "3.49.15",
"compiling options": "-f hbir -m /tmp/tmp0plq7oph/main_graph_subgraph_4.hbir -o /tmp/tmp0plq7oph/main_graph_subgraph_4.hbm --march bayes-e --progressbar --input-layout NHWC --output-layout NHWC",
"frame per run": 1,
"frame per second": 25747.98,
"input features": [
[
"input name",
"input size"
],
[
"/model.23/Split_output_0_quantized",
"1x1x8400x4"
],
[
"/model.23/Expand_1_output_0_/model.23/GatherElements_2_cast_input",
"1x1x300x4"
],
[
"/model.23/Unsqueeze_2_output_0_calibrated_Requantize_requantized_output",
"1x1x300x1"
],
[
"/model.23/Cast_2_output_0_calibrated_quantized",
"1x1x300x1"
]
],
"interval computing unit utilization": [
0.103,
0.072,
0.154,
0.262,
0.074,
0.09,
0.088,
0.38
],
"interval computing units utilization": [
0.103,
0.072,
0.154,
0.262,
0.074,
0.09,
0.088,
0.38
],
"interval loading bandwidth (megabytes/s)": [
1159,
1988,
4125,
3204,
1013,
952,
1382,
1293
],
"interval number": 8,
"interval storing bandwidth (megabytes/s)": [
1049,
1049,
524,
463,
1220,
1066,
1366,
1515
],
"interval time (ms)": 0.005,
"latency (ms)": 0.04,
"latency (ms) by segments": [
0.0,
0.039
],
"latency (us)": 38.8,
"loaded bytes per frame": 78016,
"loaded bytes per run": 78016,
"model json CRC": "6234711c",
"model json file": "/tmp/tmp0plq7oph/main_graph_subgraph_4.hbir",
"model name": "main_graph_subgraph_4",
"model param CRC": "00000000",
"multicore sync time (ms)": 0.0,
"run per second": 25747.98,
"runtime version": "3.15.55.0",
"stored bytes per frame": 42944,
"stored bytes per run": 42944,
"worst FPS": 25747.98
}
}

File diff suppressed because it is too large Load Diff

Binary file not shown.

View File

@@ -0,0 +1,83 @@
#!/usr/bin/env python3
"""Extract YOLO26 raw detection heads from a standard Ultralytics ONNX export."""
from __future__ import annotations
import argparse
import re
from pathlib import Path
import onnx
from onnx import TensorProto, helper, shape_inference
TERMINAL_HEAD = re.compile(
r"one2one_cv([23])\.(\d+)/one2one_cv\1\.\2\.2/Conv$"
)
def main() -> None:
parser = argparse.ArgumentParser()
parser.add_argument("--input", type=Path, required=True)
parser.add_argument("--output", type=Path, required=True)
args = parser.parse_args()
model = shape_inference.infer_shapes(onnx.load(args.input))
shapes = {
value.name: [dim.dim_value for dim in value.type.tensor_type.shape.dim]
for value in list(model.graph.value_info) + list(model.graph.output)
}
heads: dict[tuple[int, int], str] = {}
for node in model.graph.node:
match = TERMINAL_HEAD.search(node.name)
if match and node.op_type == "Conv":
branch, scale = int(match.group(1)), int(match.group(2))
heads[(branch, scale)] = node.output[0]
expected = {(branch, scale) for branch in (2, 3) for scale in range(3)}
if set(heads) != expected:
missing = sorted(expected - set(heads))
raise SystemExit(f"could not locate all YOLO26 one-to-one heads; missing {missing}")
del model.graph.output[:]
output_names = []
for scale, stride in enumerate((8, 16, 32)):
for branch, kind in ((3, "cls"), (2, "box")):
source = heads[(branch, scale)]
source_shape = shapes[source]
if len(source_shape) != 4:
raise SystemExit(f"unexpected head shape for {source}: {source_shape}")
output_name = f"{kind}_s{stride}"
model.graph.node.append(
helper.make_node(
"Transpose",
[source],
[output_name],
name=f"bpu_output_{kind}_s{stride}",
perm=[0, 2, 3, 1],
)
)
model.graph.output.append(
helper.make_tensor_value_info(
output_name,
TensorProto.FLOAT,
[source_shape[0], source_shape[2], source_shape[3], source_shape[1]],
)
)
output_names.append(output_name)
args.output.parent.mkdir(parents=True, exist_ok=True)
temporary = args.output.with_suffix(".unpruned.onnx")
onnx.save(model, temporary)
onnx.utils.extract_model(str(temporary), str(args.output), [model.graph.input[0].name], output_names)
temporary.unlink()
extracted = onnx.load(args.output)
onnx.checker.check_model(extracted)
print(f"wrote {args.output} with outputs:")
for output in extracted.graph.output:
dims = [dim.dim_value for dim in output.type.tensor_type.shape.dim]
print(f" {output.name}: {dims}")
if __name__ == "__main__":
main()

1631
x5_quantization/mapper.log Normal file

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,78 @@
#!/usr/bin/env python3
"""CPU post-processing for the six raw outputs of best_bpu.onnx."""
from __future__ import annotations
import numpy as np
def _nms(boxes: np.ndarray, scores: np.ndarray, iou_threshold: float) -> np.ndarray:
order = scores.argsort()[::-1]
kept: list[int] = []
while order.size:
current = int(order[0])
kept.append(current)
if order.size == 1:
break
rest = order[1:]
xx1 = np.maximum(boxes[current, 0], boxes[rest, 0])
yy1 = np.maximum(boxes[current, 1], boxes[rest, 1])
xx2 = np.minimum(boxes[current, 2], boxes[rest, 2])
yy2 = np.minimum(boxes[current, 3], boxes[rest, 3])
inter = np.maximum(0.0, xx2 - xx1) * np.maximum(0.0, yy2 - yy1)
area = (boxes[:, 2] - boxes[:, 0]) * (boxes[:, 3] - boxes[:, 1])
union = area[current] + area[rest] - inter
order = rest[(inter / np.maximum(union, 1e-9)) <= iou_threshold]
return np.asarray(kept, dtype=np.int64)
def postprocess(
outputs: list[np.ndarray] | tuple[np.ndarray, ...],
classes: int = 4,
score_threshold: float = 0.25,
iou_threshold: float = 0.7,
) -> tuple[np.ndarray, np.ndarray, np.ndarray]:
"""Decode `(cls_s8, box_s8, cls_s16, box_s16, cls_s32, box_s32)` outputs.
Returns `(boxes_xyxy, scores, class_ids)` in the 640x640 model coordinate
system. Scale boxes back to the camera image after this function when using
letterbox preprocessing.
"""
if len(outputs) != 6:
raise ValueError(f"expected six outputs, got {len(outputs)}")
conf_raw = -np.log(1.0 / score_threshold - 1.0)
detections: list[np.ndarray] = []
for index, stride in enumerate((8, 16, 32)):
cls = np.asarray(outputs[index * 2]).reshape(-1, classes).astype(np.float32)
box = np.asarray(outputs[index * 2 + 1]).reshape(-1, 4).astype(np.float32)
max_logits = cls.max(axis=1)
valid = np.flatnonzero(max_logits >= conf_raw)
if valid.size == 0:
continue
height = width = 640 // stride
grid_y, grid_x = np.indices((height, width))
grid = np.stack((grid_x, grid_y), axis=-1).reshape(-1, 2).astype(np.float32) + 0.5
anchor = grid[valid]
distances = box[valid]
xyxy = np.column_stack(
((anchor[:, 0] - distances[:, 0]) * stride,
(anchor[:, 1] - distances[:, 1]) * stride,
(anchor[:, 0] + distances[:, 2]) * stride,
(anchor[:, 1] + distances[:, 3]) * stride)
)
scores = 1.0 / (1.0 + np.exp(-max_logits[valid]))
ids = cls[valid].argmax(axis=1).astype(np.float32)
detections.append(np.column_stack((xyxy, scores, ids)))
if not detections:
return np.empty((0, 4), np.float32), np.empty((0,), np.float32), np.empty((0,), np.int32)
dets = np.concatenate(detections, axis=0)
kept: list[np.ndarray] = []
for class_id in np.unique(dets[:, 5]).astype(np.int32):
class_dets = dets[dets[:, 5] == class_id]
indices = _nms(class_dets[:, :4], class_dets[:, 4], iou_threshold)
kept.append(class_dets[indices])
if not kept:
return np.empty((0, 4), np.float32), np.empty((0,), np.float32), np.empty((0,), np.int32)
result = np.concatenate(kept, axis=0)
return result[:, :4], result[:, 4], result[:, 5].astype(np.int32)

View File

@@ -0,0 +1,58 @@
#!/usr/bin/env python3
"""Create Horizon hb_mapper calibration feature maps from the YOLO dataset."""
from __future__ import annotations
import argparse
from pathlib import Path
import numpy as np
from PIL import Image
IMAGE_EXTS = {".jpg", ".jpeg", ".png", ".bmp", ".webp"}
def resize_rgb(image: Image.Image, size: int) -> np.ndarray:
image = image.convert("RGB")
resized = image.resize((size, size), Image.Resampling.BILINEAR)
array = np.asarray(resized, dtype=np.float32)
return np.transpose(array, (2, 0, 1))[None, ...]
def main() -> None:
parser = argparse.ArgumentParser()
parser.add_argument("--dataset", type=Path, required=True)
parser.add_argument("--output", type=Path, required=True)
parser.add_argument("--samples", type=int, default=128)
parser.add_argument("--size", type=int, default=640)
args = parser.parse_args()
roots = [args.dataset / "images" / "train", args.dataset / "images" / "vel"]
images = sorted(
p for root in roots if root.is_dir() for p in root.iterdir() if p.suffix.lower() in IMAGE_EXTS
)
if not images:
raise SystemExit(f"no images found below {args.dataset}")
count = min(args.samples, len(images))
# Evenly spread samples over the sorted set so calibration is not dominated by one split.
indices = np.linspace(0, len(images) - 1, count, dtype=np.int64)
selected = [images[int(i)] for i in indices]
args.output.mkdir(parents=True, exist_ok=True)
for old in args.output.iterdir():
if old.is_file() and old.suffix in {".bin", ".rgbchw", ".txt"}:
old.unlink()
manifest = []
for index, path in enumerate(selected):
data = resize_rgb(Image.open(path), args.size)
data.tofile(args.output / f"{index:05d}.rgbchw")
manifest.append(str(path.relative_to(args.dataset)))
(args.output.parent / "calibration_manifest.txt").write_text(
"\n".join(manifest) + "\n", encoding="utf-8"
)
print(f"wrote {count} samples ({args.size}x{args.size}) to {args.output}")
if __name__ == "__main__":
main()

58
x5_quantization/quantize_x5.sh Executable file
View File

@@ -0,0 +1,58 @@
#!/usr/bin/env bash
set -euo pipefail
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
MODEL_DIR="$(cd "${SCRIPT_DIR}/.." && pwd)"
REPO_DIR="$(cd "${MODEL_DIR}/.." && pwd)"
IMAGE="openexplorer/ai_toolchain_ubuntu_20_x5_cpu:v1.2.8"
docker run --rm --platform linux/amd64 \
-v "${REPO_DIR}:/workspace/smart_car_2026" \
"${IMAGE}" bash -lc '
set -euo pipefail
cd /workspace/smart_car_2026/model/x5_quantization
python3 extract_yolo26_bpu.py \
--input ../best.onnx \
--output best_bpu.onnx
python3 prepare_calibration.py \
--dataset /workspace/smart_car_2026/dataset \
--output calibration_data \
--samples 50
cat > best_bpu_int8.yaml <<"YAML"
model_parameters:
onnx_model: "./best_bpu.onnx"
march: "bayes-e"
layer_out_dump: false
working_dir: "mapper_output_bpu"
output_model_file_prefix: "best_bpu_bayese_640x640_nv12"
input_parameters:
input_name: "images"
input_type_rt: "nv12"
input_type_train: "rgb"
input_layout_train: "NCHW"
norm_type: "data_scale"
scale_value: 0.003921568627451
calibration_parameters:
cal_data_dir: "./calibration_data"
cal_data_type: "float32"
calibration_type: "default"
optimization: "set_Softmax_input_int8,set_Softmax_output_int8"
compiler_parameters:
jobs: 8
compile_mode: "latency"
debug: true
optimize_level: "O3"
YAML
hb_mapper checker \
--model best_bpu.onnx \
--model-type onnx \
--march bayes-e \
--input-shape images 1x3x640x640
hb_mapper makertbin \
--config best_bpu_int8.yaml \
--model-type onnx
ls -lh mapper_output_bpu/best_bpu_bayese_640x640_nv12.bin
'