dlpy.model.Model.from_onnx_model

classmethod Model.from_onnx_model(conn, onnx_model, output_model_table=None, offsets=None, scale=None, std=None, norm_stds=None, output_layer=None)

Generate a Model object from ONNX model.

Parameters:
conn : CAS

Specifies the CAS connection object.

onnx_model : ModelProto

Specifies the ONNX model.

output_model_table : string or dict or CAS table, optional

Specifies the CAS table to store the deep learning model.
Default: None

offsets : int-list, optional

Specifies the values to be subtracted from the pixel values of the input data, used if the data is an image.

scale : float, optional

Specifies the scaling factor to apply to each image.

std : string, optional

Specifies how to standardize the variables in the input layer.
Valid Values: MIDRANGE, NONE, STD

norm_stds : float-list, optional

Specifies a standard deviation for each channel in the input data. The final input data is normalized with specified means and standard deviations.

output_layer : Layer object, optional

Specifies the output layer of the model. If no output layer is specified, the last layer is automatically set as OutputLayer with SOFTMAX activation.

Returns:
Model