onnx.defs#
Opset Version#
- onnx.defs.get_all_schemas_with_history() List[onnx.onnx_cpp2py_export.defs.OpSchema] #
Return the schema of all existing operators and all versions.
Operators and Functions Schemas#
- onnx.defs.get_schema(*args, **kwargs)#
Overloaded function.
get_schema(op_type: str, max_inclusive_version: int, domain: str = ‘’) -> onnx.onnx_cpp2py_export.defs.OpSchema
Return the schema of the operator op_type and for a specific version.
get_schema(op_type: str, domain: str = ‘’) -> onnx.onnx_cpp2py_export.defs.OpSchema
Return the schema of the operator op_type and for a specific version.
class OpSchema#
- class onnx.defs.OpSchema#
Schema of an operator.
- class AttrType#
Members:
FLOAT
INT
STRING
TENSOR
GRAPH
FLOATS
INTS
STRINGS
TENSORS
GRAPHS
SPARSE_TENSOR
SPARSE_TENSORS
TYPE_PROTO
TYPE_PROTOS
- property name#
- get_context_dependent_function(self: onnx.onnx_cpp2py_export.defs.OpSchema, arg0: bytes, arg1: List[bytes]) bytes #
Exception SchemaError#
- class onnx.defs.SchemaError#
Constants#
Domains officially supported in onnx package.
from onnx.defs import (
ONNX_DOMAIN,
ONNX_ML_DOMAIN,
AI_ONNX_PREVIEW_TRAINING_DOMAIN,
)
print(f"ONNX_DOMAIN={ONNX_DOMAIN!r}")
print(f"ONNX_ML_DOMAIN={ONNX_ML_DOMAIN!r}")
print(f"AI_ONNX_PREVIEW_TRAINING_DOMAIN={AI_ONNX_PREVIEW_TRAINING_DOMAIN!r}")
ONNX_DOMAIN=''
ONNX_ML_DOMAIN='ai.onnx.ml'
AI_ONNX_PREVIEW_TRAINING_DOMAIN='ai.onnx.preview.training'