QuickStart Onnx

onnx-systemds is a tool for importing/exporting onnx graphs into/from SystemDS DML scripts.

Prerequisites

to run onnx-systemds you need to:

Usage

An example call from the src/main/python directory of systemds:

python -m systemds.onnx_systemds.convert tests/onnx/test_models/simple_mat_add.onnx

This will generate the dml script simple_mat_add.dml in the current directory.

Run Tests

Form the src/main/python directory of systemds:

At first generate the test models:

python tests/onnx/test_models/model_generate.py

Then you can run the tests:

python -m unittest tests/onnx/test_simple.py

Converter

It is also possible to invoke the converter from within python.

systemds.onnx_systemds.convert.onnx2systemds(input_onnx_file: str, output_dml_file: str = None) → None

Loads the model from the input file and generates a dml file.

Parameters
  • input_onnx_file – the onnx input file

  • output_dml_file – (optional) the dml output file, if this parameter is not given the output file will have the same name as the input file