reference#
CReferenceEvaluator#
- class onnx_extended.reference.CReferenceEvaluator(proto: Any, opsets: Dict[str, int] | None = None, functions: List[ReferenceEvaluator | FunctionProto] | None = None, verbose: int = 0, new_ops: List[OpRun] | None = None, **kwargs)[source]#
This class replaces the python implementation by C implementation for a short list of operators quite slow in python (such as Conv). The class automatically replaces a python implementation by a C implementation if available. See example Using C implementation of operator Conv.
from onnx.reference import ReferenceEvaluator from from onnx.reference.c_ops import Conv ref = ReferenceEvaluator(..., new_ops=[Conv])
- property input_names#
Returns the input names.
- property opsets#
Returns the opsets.
- property output_names#
Returns the output names.
- run(output_names, feed_inputs: Dict[str, Any], attributes: Dict[str, Any] | None = None)#
Executes the onnx model.
- Parameters:
output_names – requested outputs by names, None for all
feed_inputs – dictionary { input name: input value }
attributes – attributes value if the instance runs a FunctionProto
- Returns:
list of requested outputs
Operators#
ai.onnx#
ai.onnx.ml#
- class onnx_extended.reference.c_ops.c_op_tree_ensemble_classifier.TreeEnsembleClassifier_1(onnx_node: NodeProto, run_params: Dict[str, Any], schema: Any | None = None)[source]#
- class onnx_extended.reference.c_ops.c_op_tree_ensemble_classifier.TreeEnsembleClassifier_3(onnx_node: NodeProto, run_params: Dict[str, Any], schema: Any | None = None)[source]#