mirror of
https://github.com/luxfi/onnx-source-snapshot.git
synced 2026-10-30 15:23:38 +00:00
2.6 KiB
2.6 KiB
In [1]:
# NBVAL_SKIP
# Protobuf 4 and Protobuf 3 might output different order of protobuf fields
import onnx
import os
# Load the ONNX model
onnx_model = onnx.load(os.path.join("resources", "single_relu.onnx"))
print(onnx_model)ir_version: 3
producer_name: "backend-test"
graph {
node {
input: "x"
output: "y"
name: "test"
op_type: "Relu"
}
name: "SingleRelu"
input {
name: "x"
type {
tensor_type {
elem_type: 1
shape {
dim {
dim_value: 1
}
dim {
dim_value: 2
}
}
}
}
}
output {
name: "y"
type {
tensor_type {
elem_type: 1
shape {
dim {
dim_value: 1
}
dim {
dim_value: 2
}
}
}
}
}
}
opset_import {
version: 6
}
In [ ]: