MIGraphX Field Guide
Models

YOLO Models

Practical YOLO export and validation notes for MIGraphX.

YOLO models are common in video pipelines. The main integration concern is whether non-max suppression is inside the ONNX graph or handled in application code.

Export Shape

A common serving shape:

input:  [batch, 3, 640, 640]
output: [batch, max_detections, fields]

For an NMS-included export, many pipelines expect:

[batch, 300, 6]

where the fields are usually box coordinates, score, and class.

Ultralytics-Style Export

Example:

yolo export \
  model=yolo11s.pt \
  format=onnx \
  imgsz=640 \
  opset=17 \
  dynamic=True \
  nms=True \
  simplify=True \
  max_det=300 \
  batch=16

Validate immediately:

migraphx-driver compile yolo11s.onnx --gpu
migraphx-driver verify yolo11s.onnx --gpu
migraphx-driver perf yolo11s.onnx --gpu

NMS Choice

NMS locationBenefitCost
In ONNX graphsimpler application outputdepends on operator support and shape behavior
In application codemore portable and controllablemore postprocess code to maintain

For a multi-vendor backend, application-side NMS can be easier to keep identical across TensorRT, MIGraphX, and CPU fallback.

Checklist

1. MIGraphX compile succeeds
2. output shape matches postprocess
3. sample detections match a reference run
4. latency is measured at target batch sizes
5. saved .mxr artifact loads and runs

On this page