onnx-mlir

Representation and Reference Lowering of ONNX Models in MLIR Compiler Infrastructure

View the Project on GitHub onnx/onnx-mlir

How-tos

Using PyRuntime
Perform Inference Using ONNX-MLIR Runtime API

References

ONNX Dialect
OMTensor C99 Runtime API
OMTensorList C99 Runtime API
Generate ONNX Dialect
About Documentation

Discussions

Testing Guidelines

Tools

debug.py - Debug Numerical Errors
DocCheck - Handling Necessary Code Duplication

This project is maintained by onnx

Hosted on GitHub Pages — Theme by orderedlist

Debugging Numerical Error

Use util/debug.py python script to debug numerical errors, when onnx-mlir-compiled inference executable produces numerical results that are inconsistent with those produced by the training framework. This python script will run the model through onnx-mlir and a reference backend, and compare the intermediate results produced by these two backends layer by layer.

Rrerequisite

Usage

util/debug.py supports the following command-line options:

usage: debug.py [-h] model_path

positional arguments:
  model_path  Path to the model to debug.