Previous  Next

ONNX Models in Machine Learning

ONNX (Open Neural Network Exchange) is an open-source format for machine learning models. This project has several major advantages:

MQL5 provides the following functions for working with ONNX:

Function

Action

OnnxCreate

Create an ONNX session, loading a model from an *.onnx file

OnnxCreateFromBuffer

Create an ONNX session, loading a model from a data array

OnnxRelease

Close an ONNX session

OnnxRun

Run an ONNX model

OnnxGetInputCount

Get the number of inputs in an ONNX model

OnnxGetOutputCount

Get the number of outputs in an ONNX model

OnnxGetInputName

Get the name of a model's input by index

OnnxGetOutputName

Get the name of a model's output by index

OnnxGetInputTypeInfo

Get the description of the input type from the model

OnnxGetOutputTypeInfo

Get the description of the output type from the model

OnnxSetInputShape

Set the shape of a model's input data by index

OnnxSetOutputShape

Set the shape of a model's output data by index