Implement transpose
for complex inputs | feat(torchlib) (#1134)
#471
49 fail, 2 730 skipped, 8 334 pass in 1h 18m 56s
Annotations
github-actions / Test Results
3 out of 9 runs failed: test_output_match_opinfo__all_dim_cpu_float32 (onnxscript.tests.function_libs.torch_lib.ops_test.TestOutputConsistencyFullGraphCPU)
artifacts/Test Results (py310-torch-nightly-macos-latest)/pytest.xml [took 3s]
artifacts/Test Results (py310-torch-nightly-ubuntu-latest)/pytest.xml [took 2s]
artifacts/Test Results (py310-torch-nightly-windows-latest)/pytest.xml [took 0s]
Raw output
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float[2] input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float[3,5] input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, 1], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float[3,5] input_0) => (bool[1,1] _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float[3,2,1,2] input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, 1, 2, 3], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float[3,2,1,2] input_0) => (bool[1,2,1,1] _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float[3,2,1,2] input_0) => (bool[3,1] _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [1, 3], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (float input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (float[2] input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (float[3,5] input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, 1], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (float[3,5] input_0) => (bool[1,1] _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (float[3,2,1,2] input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, 1, 2, 3], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (float[3,2,1,2] input_0) => (bool[1,2,1,1] _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (float[3,2,1,2] input_0) => (bool[3,1] _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [1, 3], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
github-actions / Test Results
3 out of 9 runs failed: test_output_match_opinfo__any_dim_cpu_float32 (onnxscript.tests.function_libs.torch_lib.ops_test.TestOutputConsistencyFullGraphCPU)
artifacts/Test Results (py310-torch-nightly-macos-latest)/pytest.xml [took 0s]
artifacts/Test Results (py310-torch-nightly-ubuntu-latest)/pytest.xml [took 1s]
artifacts/Test Results (py310-torch-nightly-windows-latest)/pytest.xml [took 0s]
Raw output
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float[2] input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float[3,5] input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, 1], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float[3,5] input_0) => (bool[1,1] _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float[3,2,1,2] input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, 1, 2, 3], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float[3,2,1,2] input_0) => (bool[1,2,1,1] _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float[3,2,1,2] input_0) => (bool[3,1] _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [1, 3], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (float input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (float[2] input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (float[3,5] input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, 1], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (float[3,5] input_0) => (bool[1,1] _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (float[3,2,1,2] input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, 1, 2, 3], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (float[3,2,1,2] input_0) => (bool[1,2,1,1] _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (float[3,2,1,2] input_0) => (bool[3,1] _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [1, 3], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
github-actions / Test Results
3 out of 9 runs failed: test_output_match_opinfo__all_dim_cpu_bool (onnxscript.tests.function_libs.torch_lib.ops_test.TestOutputConsistencyFullGraphCPU)
artifacts/Test Results (py310-torch-nightly-macos-latest)/pytest.xml [took 2s]
artifacts/Test Results (py310-torch-nightly-ubuntu-latest)/pytest.xml [took 1s]
artifacts/Test Results (py310-torch-nightly-windows-latest)/pytest.xml [took 0s]
Raw output
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (bool input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (bool[2] input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (bool[3,5] input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, 1], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (bool[3,5] input_0) => (bool[1,1] _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (bool[3,2,1,2] input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, 1, 2, 3], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (bool[3,2,1,2] input_0) => (bool[1,2,1,1] _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (bool[3,2,1,2] input_0) => (bool[3,1] _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [1, 3], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (bool input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (bool[2] input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (bool[3,5] input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, 1], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (bool[3,5] input_0) => (bool[1,1] _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (bool[3,2,1,2] input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, 1, 2, 3], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (bool[3,2,1,2] input_0) => (bool[1,2,1,1] _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (bool[3,2,1,2] input_0) => (bool[3,1] _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [1, 3], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
github-actions / Test Results
3 out of 9 runs failed: test_output_match_opinfo__all_dim_cpu_int32 (onnxscript.tests.function_libs.torch_lib.ops_test.TestOutputConsistencyFullGraphCPU)
artifacts/Test Results (py310-torch-nightly-macos-latest)/pytest.xml [took 2s]
artifacts/Test Results (py310-torch-nightly-ubuntu-latest)/pytest.xml [took 1s]
artifacts/Test Results (py310-torch-nightly-windows-latest)/pytest.xml [took 1s]
Raw output
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int32 input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int32[2] input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int32[3,5] input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, 1], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int32[3,5] input_0) => (bool[1,1] _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int32[3,2,1,2] input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, 1, 2, 3], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int32[3,2,1,2] input_0) => (bool[1,2,1,1] _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int32[3,2,1,2] input_0) => (bool[3,1] _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [1, 3], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int32 input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int32[2] input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int32[3,5] input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, 1], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int32[3,5] input_0) => (bool[1,1] _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int32[3,2,1,2] input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, 1, 2, 3], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int32[3,2,1,2] input_0) => (bool[1,2,1,1] _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int32[3,2,1,2] input_0) => (bool[3,1] _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [1, 3], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
github-actions / Test Results
3 out of 9 runs failed: test_output_match_opinfo__all_dim_cpu_float16 (onnxscript.tests.function_libs.torch_lib.ops_test.TestOutputConsistencyFullGraphCPU)
artifacts/Test Results (py310-torch-nightly-macos-latest)/pytest.xml [took 3s]
artifacts/Test Results (py310-torch-nightly-ubuntu-latest)/pytest.xml [took 2s]
artifacts/Test Results (py310-torch-nightly-windows-latest)/pytest.xml [took 0s]
Raw output
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float16 input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float16[2] input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float16[3,5] input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, 1], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float16[3,5] input_0) => (bool[1,1] _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float16[3,2,1,2] input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, 1, 2, 3], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float16[3,2,1,2] input_0) => (bool[1,2,1,1] _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float16[3,2,1,2] input_0) => (bool[3,1] _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [1, 3], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (float16 input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (float16[2] input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (float16[3,5] input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, 1], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (float16[3,5] input_0) => (bool[1,1] _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (float16[3,2,1,2] input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, 1, 2, 3], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (float16[3,2,1,2] input_0) => (bool[1,2,1,1] _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (float16[3,2,1,2] input_0) => (bool[3,1] _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [1, 3], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
github-actions / Test Results
3 out of 9 runs failed: test_output_match_opinfo__any_dim_cpu_int64 (onnxscript.tests.function_libs.torch_lib.ops_test.TestOutputConsistencyFullGraphCPU)
artifacts/Test Results (py310-torch-nightly-macos-latest)/pytest.xml [took 1s]
artifacts/Test Results (py310-torch-nightly-ubuntu-latest)/pytest.xml [took 1s]
artifacts/Test Results (py310-torch-nightly-windows-latest)/pytest.xml [took 0s]
Raw output
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int64 input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int64[2] input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int64[3,5] input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, 1], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int64[3,5] input_0) => (bool[1,1] _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int64[3,2,1,2] input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, 1, 2, 3], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int64[3,2,1,2] input_0) => (bool[1,2,1,1] _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int64[3,2,1,2] input_0) => (bool[3,1] _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [1, 3], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int64 input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int64[2] input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int64[3,5] input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, 1], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int64[3,5] input_0) => (bool[1,1] _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int64[3,2,1,2] input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, 1, 2, 3], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int64[3,2,1,2] input_0) => (bool[1,2,1,1] _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int64[3,2,1,2] input_0) => (bool[3,1] _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [1, 3], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
github-actions / Test Results
3 out of 9 runs failed: test_output_match_opinfo__any_dim_cpu_bool (onnxscript.tests.function_libs.torch_lib.ops_test.TestOutputConsistencyFullGraphCPU)
artifacts/Test Results (py310-torch-nightly-macos-latest)/pytest.xml [took 1s]
artifacts/Test Results (py310-torch-nightly-ubuntu-latest)/pytest.xml [took 1s]
artifacts/Test Results (py310-torch-nightly-windows-latest)/pytest.xml [took 0s]
Raw output
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (bool input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (bool[2] input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (bool[3,5] input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, 1], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (bool[3,5] input_0) => (bool[1,1] _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (bool[3,2,1,2] input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, 1, 2, 3], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (bool[3,2,1,2] input_0) => (bool[1,2,1,1] _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (bool[3,2,1,2] input_0) => (bool[3,1] _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [1, 3], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (bool input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (bool[2] input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (bool[3,5] input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, 1], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (bool[3,5] input_0) => (bool[1,1] _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (bool[3,2,1,2] input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, 1, 2, 3], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (bool[3,2,1,2] input_0) => (bool[1,2,1,1] _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (bool[3,2,1,2] input_0) => (bool[3,1] _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [1, 3], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
github-actions / Test Results
3 out of 9 runs failed: test_output_match_opinfo__any_dim_cpu_int32 (onnxscript.tests.function_libs.torch_lib.ops_test.TestOutputConsistencyFullGraphCPU)
artifacts/Test Results (py310-torch-nightly-macos-latest)/pytest.xml [took 0s]
artifacts/Test Results (py310-torch-nightly-ubuntu-latest)/pytest.xml [took 1s]
artifacts/Test Results (py310-torch-nightly-windows-latest)/pytest.xml [took 0s]
Raw output
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int32 input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int32[2] input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int32[3,5] input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, 1], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int32[3,5] input_0) => (bool[1,1] _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int32[3,2,1,2] input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, 1, 2, 3], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int32[3,2,1,2] input_0) => (bool[1,2,1,1] _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int32[3,2,1,2] input_0) => (bool[3,1] _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [1, 3], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int32 input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int32[2] input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int32[3,5] input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, 1], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int32[3,5] input_0) => (bool[1,1] _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int32[3,2,1,2] input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, 1, 2, 3], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int32[3,2,1,2] input_0) => (bool[1,2,1,1] _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int32[3,2,1,2] input_0) => (bool[3,1] _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [1, 3], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
github-actions / Test Results
3 out of 9 runs failed: test_output_match_opinfo__all_dim_cpu_int64 (onnxscript.tests.function_libs.torch_lib.ops_test.TestOutputConsistencyFullGraphCPU)
artifacts/Test Results (py310-torch-nightly-macos-latest)/pytest.xml [took 2s]
artifacts/Test Results (py310-torch-nightly-ubuntu-latest)/pytest.xml [took 1s]
artifacts/Test Results (py310-torch-nightly-windows-latest)/pytest.xml [took 1s]
Raw output
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int64 input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int64[2] input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int64[3,5] input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, 1], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int64[3,5] input_0) => (bool[1,1] _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int64[3,2,1,2] input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, 1, 2, 3], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int64[3,2,1,2] input_0) => (bool[1,2,1,1] _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int64[3,2,1,2] input_0) => (bool[3,1] _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [1, 3], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_all_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (all_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int64 input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int64[2] input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int64[3,5] input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, 1], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int64[3,5] input_0) => (bool[1,1] _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int64[3,2,1,2] input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, 1, 2, 3], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int64[3,2,1,2] input_0) => (bool[1,2,1,1] _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_all_dim, node name: aten_all_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int64[3,2,1,2] input_0) => (bool[3,1] _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_all_dim <dim: ints = [1, 3], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_all_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E all_true = ReduceMin <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (all_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
github-actions / Test Results
3 out of 9 runs failed: test_output_match_opinfo__any_dim_cpu_float16 (onnxscript.tests.function_libs.torch_lib.ops_test.TestOutputConsistencyFullGraphCPU)
artifacts/Test Results (py310-torch-nightly-macos-latest)/pytest.xml [took 2s]
artifacts/Test Results (py310-torch-nightly-ubuntu-latest)/pytest.xml [took 1s]
artifacts/Test Results (py310-torch-nightly-windows-latest)/pytest.xml [took 0s]
Raw output
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float16 input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float16[2] input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float16[3,5] input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, 1], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float16[3,5] input_0) => (bool[1,1] _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float16[3,2,1,2] input_0) => (bool _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, 1, 2, 3], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float16[3,2,1,2] input_0) => (bool[1,2,1,1] _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float16[3,2,1,2] input_0) => (bool[3,1] _val_1) {
_val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [1, 3], keepdim: int = 0> (input_0)
}
<
domain: "pkg.onnxscript.torch_lib",
opset_import: ["" : 18]
>
aten_any_dim <dim>(self) => (result_2)
{
tmp = Shape (self)
self_rank = Size (tmp)
int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
int64_0_cast = CastLike (int64_0, self_rank)
cond = Equal (self_rank, int64_0_cast)
result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
result = Cast <to: int = 9> (self)
}, else_branch: graph = elseGraph_6 () => ( result_1) {
self_bool = Cast <to: int = 9> (self)
self_int = Cast <to: int = 7> (self_bool)
dim = Constant <value_int: int = @dim> ()
tmp_0 = Constant <value_ints: ints = [-1]> ()
dims = Reshape (dim, tmp_0)
any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
result_1 = Cast <to: int = 9> (any_true)
}>
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (float16 input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (float16[2] input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (float16[3,5] input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, 1], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (float16[3,5] input_0) => (bool[1,1] _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (float16[3,2,1,2] input_0) => (bool _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, 1, 2, 3], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (float16[3,2,1,2] input_0) => (bool[1,2,1,1] _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [0, -1], keepdim: int = 1> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:aten_any_dim, node name: aten_any_dim_0): [ShapeInferenceError] Inference error(s): (op_type:If, node name: n5): [ShapeInferenceError] Inference error(s): (op_type:Constant, node name: n2): [ShapeInferenceError] Attribute 'value_int' expect an integer.
E (op_type:Reshape, node name: n4): [TypeInferenceError] Input 0 expected to have type but instead is null
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["pkg.onnxscript.torch_lib" : 1, "" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (float16[3,2,1,2] input_0) => (bool[3,1] _val_1) {
E _val_1 = pkg.onnxscript.torch_lib.aten_any_dim <dim: ints = [1, 3], keepdim: int = 0> (input_0)
E }
E <
E domain: "pkg.onnxscript.torch_lib",
E opset_import: ["" : 18]
E >
E aten_any_dim <dim>(self) => (result_2)
E {
E tmp = Shape (self)
E self_rank = Size (tmp)
E int64_0 = Constant <value: tensor = int64 int64_0 {0}> ()
E int64_0_cast = CastLike (int64_0, self_rank)
E cond = Equal (self_rank, int64_0_cast)
E result_2 = If (cond) <then_branch: graph = thenGraph_6 () => ( result) {
E result = Cast <to: int = 9> (self)
E }, else_branch: graph = elseGraph_6 () => ( result_1) {
E self_bool = Cast <to: int = 9> (self)
E self_int = Cast <to: int = 7> (self_bool)
E dim = Constant <value_int: int = @dim> ()
E tmp_0 = Constant <value_ints: ints = [-1]> ()
E dims = Reshape (dim, tmp_0)
E any_true = ReduceMax <keepdims: int = @keepdim> (self_int, dims)
E result_1 = Cast <to: int = 9> (any_true)
E }>
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
github-actions / Test Results
3 out of 9 runs failed: test_output_match_opinfo__any_dim_cpu_int32 (onnxscript.tests.function_libs.torch_lib.ops_test.TestOutputConsistencyEagerCPU)
artifacts/Test Results (py310-torch-nightly-macos-latest)/pytest.xml [took 5s]
artifacts/Test Results (py310-torch-nightly-ubuntu-latest)/pytest.xml [took 3s]
artifacts/Test Results (py310-torch-nightly-windows-latest)/pytest.xml [took 3s]
Raw output
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:473: in aten_any_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:473: in aten_any_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:473: in aten_any_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:473: in aten_any_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:473: in aten_any_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:473: in aten_any_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
github-actions / Test Results
3 out of 9 runs failed: test_output_match_opinfo__any_dim_cpu_float16 (onnxscript.tests.function_libs.torch_lib.ops_test.TestOutputConsistencyEagerCPU)
artifacts/Test Results (py310-torch-nightly-macos-latest)/pytest.xml [took 4s]
artifacts/Test Results (py310-torch-nightly-ubuntu-latest)/pytest.xml [took 4s]
artifacts/Test Results (py310-torch-nightly-windows-latest)/pytest.xml [took 2s]
Raw output
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:473: in aten_any_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:473: in aten_any_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:473: in aten_any_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:473: in aten_any_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:473: in aten_any_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:473: in aten_any_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
github-actions / Test Results
3 out of 9 runs failed: test_output_match_opinfo__any_dim_cpu_bool (onnxscript.tests.function_libs.torch_lib.ops_test.TestOutputConsistencyEagerCPU)
artifacts/Test Results (py310-torch-nightly-macos-latest)/pytest.xml [took 5s]
artifacts/Test Results (py310-torch-nightly-ubuntu-latest)/pytest.xml [took 3s]
artifacts/Test Results (py310-torch-nightly-windows-latest)/pytest.xml [took 3s]
Raw output
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:473: in aten_any_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:473: in aten_any_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:473: in aten_any_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:473: in aten_any_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:473: in aten_any_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:473: in aten_any_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
github-actions / Test Results
3 out of 9 runs failed: test_output_match_opinfo__ops_aten__softmax_half_cpu_float16 (onnxscript.tests.function_libs.torch_lib.ops_test.TestOutputConsistencyEagerCPU)
artifacts/Test Results (py310-torch-nightly-macos-latest)/pytest.xml [took 0s]
artifacts/Test Results (py310-torch-nightly-ubuntu-latest)/pytest.xml [took 0s]
artifacts/Test Results (py310-torch-nightly-windows-latest)/pytest.xml [took 0s]
Raw output
Failed: Unexpected success
Unexpected success
github-actions / Test Results
3 out of 9 runs failed: test_output_match_opinfo__all_dim_cpu_int32 (onnxscript.tests.function_libs.torch_lib.ops_test.TestOutputConsistencyEagerCPU)
artifacts/Test Results (py310-torch-nightly-macos-latest)/pytest.xml [took 6s]
artifacts/Test Results (py310-torch-nightly-ubuntu-latest)/pytest.xml [took 4s]
artifacts/Test Results (py310-torch-nightly-windows-latest)/pytest.xml [took 3s]
Raw output
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:347: in aten_all_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:347: in aten_all_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:347: in aten_all_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:347: in aten_all_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:347: in aten_all_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:347: in aten_all_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
github-actions / Test Results
3 out of 9 runs failed: test_output_match_opinfo__all_dim_cpu_bool (onnxscript.tests.function_libs.torch_lib.ops_test.TestOutputConsistencyEagerCPU)
artifacts/Test Results (py310-torch-nightly-macos-latest)/pytest.xml [took 4s]
artifacts/Test Results (py310-torch-nightly-ubuntu-latest)/pytest.xml [took 4s]
artifacts/Test Results (py310-torch-nightly-windows-latest)/pytest.xml [took 3s]
Raw output
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:347: in aten_all_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:347: in aten_all_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:347: in aten_all_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:347: in aten_all_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:347: in aten_all_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:347: in aten_all_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
github-actions / Test Results
3 out of 9 runs failed: test_output_match_opinfo__all_dim_cpu_float16 (onnxscript.tests.function_libs.torch_lib.ops_test.TestOutputConsistencyEagerCPU)
artifacts/Test Results (py310-torch-nightly-macos-latest)/pytest.xml [took 6s]
artifacts/Test Results (py310-torch-nightly-ubuntu-latest)/pytest.xml [took 4s]
artifacts/Test Results (py310-torch-nightly-windows-latest)/pytest.xml [took 3s]
Raw output
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:347: in aten_all_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:347: in aten_all_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:347: in aten_all_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:347: in aten_all_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:347: in aten_all_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:347: in aten_all_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
github-actions / Test Results
3 out of 9 runs failed: test_output_match_opinfo__any_dim_cpu_float32 (onnxscript.tests.function_libs.torch_lib.ops_test.TestOutputConsistencyEagerCPU)
artifacts/Test Results (py310-torch-nightly-macos-latest)/pytest.xml [took 5s]
artifacts/Test Results (py310-torch-nightly-ubuntu-latest)/pytest.xml [took 3s]
artifacts/Test Results (py310-torch-nightly-windows-latest)/pytest.xml [took 2s]
Raw output
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:473: in aten_any_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:473: in aten_any_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:473: in aten_any_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:473: in aten_any_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:473: in aten_any_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:473: in aten_any_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
github-actions / Test Results
3 out of 9 runs failed: test_output_match_opinfo__all_dim_cpu_int64 (onnxscript.tests.function_libs.torch_lib.ops_test.TestOutputConsistencyEagerCPU)
artifacts/Test Results (py310-torch-nightly-macos-latest)/pytest.xml [took 6s]
artifacts/Test Results (py310-torch-nightly-ubuntu-latest)/pytest.xml [took 4s]
artifacts/Test Results (py310-torch-nightly-windows-latest)/pytest.xml [took 3s]
Raw output
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:347: in aten_all_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:347: in aten_all_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:347: in aten_all_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:347: in aten_all_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:347: in aten_all_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:347: in aten_all_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
github-actions / Test Results
3 out of 9 runs failed: test_output_match_opinfo__all_dim_cpu_float32 (onnxscript.tests.function_libs.torch_lib.ops_test.TestOutputConsistencyEagerCPU)
artifacts/Test Results (py310-torch-nightly-macos-latest)/pytest.xml [took 6s]
artifacts/Test Results (py310-torch-nightly-ubuntu-latest)/pytest.xml [took 4s]
artifacts/Test Results (py310-torch-nightly-windows-latest)/pytest.xml [took 3s]
Raw output
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:347: in aten_all_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:347: in aten_all_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:347: in aten_all_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:347: in aten_all_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:347: in aten_all_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:347: in aten_all_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
github-actions / Test Results
3 out of 9 runs failed: test_output_match_opinfo__any_dim_cpu_int64 (onnxscript.tests.function_libs.torch_lib.ops_test.TestOutputConsistencyEagerCPU)
artifacts/Test Results (py310-torch-nightly-macos-latest)/pytest.xml [took 6s]
artifacts/Test Results (py310-torch-nightly-ubuntu-latest)/pytest.xml [took 4s]
artifacts/Test Results (py310-torch-nightly-windows-latest)/pytest.xml [took 2s]
Raw output
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:473: in aten_any_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:473: in aten_any_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:473: in aten_any_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:473: in aten_any_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:473: in aten_any_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:584: in executor
return function(*args, **kwargs)
onnxscript/values.py:519: in __call__
return evaluator.default().eval_function(self, args, kwargs)
onnxscript/evaluator.py:309: in eval_function
result = function.function(*adapted_args, **adapted_kwargs)
onnxscript/function_libs/torch_lib/ops/core.py:473: in aten_any_dim
dims = op.Reshape(dim, op.Constant(value_ints=[-1]))
onnxscript/onnx_opset/_impl/opset14.py:909: in Reshape
return op(*self._prepare_inputs(schema, data, shape), allowzero=allowzero)
onnxscript/values.py:297: in __call__
return evaluator.default().eval(schema, args, kwargs)
onnxscript/evaluator.py:196: in eval
outputs = self._eval(schema, inputs, attributes, closure)
onnxscript/evaluator.py:510: in _eval
return _call_ort(schema, inputs, attributes, closure)
onnxscript/evaluator.py:471: in _call_ort
model, session_run_input, inputs = _prepare_model_and_inputs_for_eager(
onnxscript/evaluator.py:411: in _prepare_model_and_inputs_for_eager
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:411: in <listcomp>
args = [_onnxscript_to_numpy_value(x) for x in args]
onnxscript/evaluator.py:377: in _onnxscript_to_numpy_value
raise TypeError(
E TypeError: Unexpected onnxscript value type '<class 'tuple'>'.Valid value types are 'Tensor | list[Tensor] | None | np.ndarray | list[np.ndarray]'
github-actions / Test Results
All 3 runs failed: test_output_match_opinfo__linspace_tensor_overload_cpu_int64 (onnxscript.tests.function_libs.torch_lib.ops_test.TestOutputConsistencyFullGraphCPU)
artifacts/Test Results (py310-torch-nightly-macos-latest)/pytest.xml [took 5s]
artifacts/Test Results (py310-torch-nightly-ubuntu-latest)/pytest.xml [took 10s]
artifacts/Test Results (py310-torch-nightly-windows-latest)/pytest.xml [took 2s]
Raw output
AssertionError: Tensor-likes are not equal!
Mismatched elements: 1 / 50 (2.0%)
Greatest absolute difference: 1 at index (49,)
Greatest relative difference: 0.3333333432674408 at index (49,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 1 / 50 (2.0%)
Greatest absolute difference: 1 at index (49,)
Greatest relative difference: 0.3333333432674408 at index (49,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 1 / 50 (2.0%)
Greatest absolute difference: 1 at index (49,)
Greatest relative difference: 0.3333333432674408 at index (49,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 2 at index (25,)
Greatest relative difference: inf at index (25,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 2 at index (25,)
Greatest relative difference: inf at index (25,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 2 at index (25,)
Greatest relative difference: inf at index (25,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 3 at index (49,)
Greatest relative difference: inf at index (17,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 3 at index (49,)
Greatest relative difference: inf at index (17,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 3 at index (49,)
Greatest relative difference: inf at index (17,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 6 at index (49,)
Greatest relative difference: inf at index (9,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 6 at index (49,)
Greatest relative difference: inf at index (9,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 6 at index (49,)
Greatest relative difference: inf at index (9,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 34 / 50 (68.0%)
Greatest absolute difference: 3 at index (49,)
Greatest relative difference: inf at index (1,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 34 / 50 (68.0%)
Greatest absolute difference: 3 at index (49,)
Greatest relative difference: inf at index (1,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 34 / 50 (68.0%)
Greatest absolute difference: 3 at index (49,)
Greatest relative difference: inf at index (1,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 33 / 50 (66.0%)
Greatest absolute difference: 3 at index (49,)
Greatest relative difference: 1.0 at index (17,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 33 / 50 (66.0%)
Greatest absolute difference: 3 at index (49,)
Greatest relative difference: 1.0 at index (17,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 33 / 50 (66.0%)
Greatest absolute difference: 3 at index (49,)
Greatest relative difference: 1.0 at index (17,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 1 / 50 (2.0%)
Greatest absolute difference: 1 at index (49,)
Greatest relative difference: 1.0 at index (49,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 1 / 50 (2.0%)
Greatest absolute difference: 1 at index (49,)
Greatest relative difference: 1.0 at index (49,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 1 / 50 (2.0%)
Greatest absolute difference: 1 at index (49,)
Greatest relative difference: 1.0 at index (49,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 37 / 50 (74.0%)
Greatest absolute difference: 4 at index (49,)
Greatest relative difference: 1.0 at index (13,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 37 / 50 (74.0%)
Greatest absolute difference: 4 at index (49,)
Greatest relative difference: 1.0 at index (13,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 37 / 50 (74.0%)
Greatest absolute difference: 4 at index (49,)
Greatest relative difference: 1.0 at index (13,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 1 / 50 (2.0%)
Greatest absolute difference: 1 at index (49,)
Greatest relative difference: 0.019999999552965164 at index (49,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 1 / 50 (2.0%)
Greatest absolute difference: 1 at index (49,)
Greatest relative difference: 0.019999999552965164 at index (49,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 1 / 50 (2.0%)
Greatest absolute difference: 1 at index (49,)
Greatest relative difference: 0.019999999552965164 at index (49,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 7 at index (49,)
Greatest relative difference: inf at index (22,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 7 at index (49,)
Greatest relative difference: inf at index (22,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 7 at index (49,)
Greatest relative difference: inf at index (22,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 4 at index (37,)
Greatest relative difference: inf at index (37,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 4 at index (37,)
Greatest relative difference: inf at index (37,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 4 at index (37,)
Greatest relative difference: inf at index (37,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 3 at index (33,)
Greatest relative difference: 3.0 at index (33,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 3 at index (33,)
Greatest relative difference: 3.0 at index (33,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 3 at index (33,)
Greatest relative difference: 3.0 at index (33,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 48 / 50 (96.0%)
Greatest absolute difference: 46 at index (49,)
Greatest relative difference: 0.9200000166893005 at index (49,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 48 / 50 (96.0%)
Greatest absolute difference: 46 at index (49,)
Greatest relative difference: 0.9200000166893005 at index (49,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 48 / 50 (96.0%)
Greatest absolute difference: 46 at index (49,)
Greatest relative difference: 0.9200000166893005 at index (49,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 4 at index (37,)
Greatest relative difference: inf at index (46,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 4 at index (37,)
Greatest relative difference: inf at index (46,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 4 at index (37,)
Greatest relative difference: inf at index (46,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 1 at index (1,)
Greatest relative difference: inf at index (49,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 1 at index (1,)
Greatest relative difference: inf at index (49,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 1 at index (1,)
Greatest relative difference: inf at index (49,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 46 at index (48,)
Greatest relative difference: 11.5 at index (48,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 46 at index (48,)
Greatest relative difference: 11.5 at index (48,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 46 at index (48,)
Greatest relative difference: 11.5 at index (48,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 43 / 50 (86.0%)
Greatest absolute difference: 7 at index (49,)
Greatest relative difference: 1.0 at index (7,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 1 / 50 (2.0%)
E Greatest absolute difference: 1 at index (49,)
E Greatest relative difference: 0.3333333432674408 at index (49,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 1 / 50 (2.0%)
E Greatest absolute difference: 1 at index (49,)
E Greatest relative difference: 0.3333333432674408 at index (49,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 1 / 50 (2.0%)
E Greatest absolute difference: 1 at index (49,)
E Greatest relative difference: 0.3333333432674408 at index (49,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 2 at index (25,)
E Greatest relative difference: inf at index (25,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 2 at index (25,)
E Greatest relative difference: inf at index (25,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 2 at index (25,)
E Greatest relative difference: inf at index (25,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 3 at index (49,)
E Greatest relative difference: inf at index (17,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 3 at index (49,)
E Greatest relative difference: inf at index (17,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 3 at index (49,)
E Greatest relative difference: inf at index (17,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 6 at index (49,)
E Greatest relative difference: inf at index (9,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 6 at index (49,)
E Greatest relative difference: inf at index (9,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 6 at index (49,)
E Greatest relative difference: inf at index (9,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 34 / 50 (68.0%)
E Greatest absolute difference: 3 at index (49,)
E Greatest relative difference: inf at index (1,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 34 / 50 (68.0%)
E Greatest absolute difference: 3 at index (49,)
E Greatest relative difference: inf at index (1,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 34 / 50 (68.0%)
E Greatest absolute difference: 3 at index (49,)
E Greatest relative difference: inf at index (1,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 33 / 50 (66.0%)
E Greatest absolute difference: 3 at index (49,)
E Greatest relative difference: 1.0 at index (17,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 33 / 50 (66.0%)
E Greatest absolute difference: 3 at index (49,)
E Greatest relative difference: 1.0 at index (17,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 33 / 50 (66.0%)
E Greatest absolute difference: 3 at index (49,)
E Greatest relative difference: 1.0 at index (17,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 1 / 50 (2.0%)
E Greatest absolute difference: 1 at index (49,)
E Greatest relative difference: 1.0 at index (49,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 1 / 50 (2.0%)
E Greatest absolute difference: 1 at index (49,)
E Greatest relative difference: 1.0 at index (49,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 1 / 50 (2.0%)
E Greatest absolute difference: 1 at index (49,)
E Greatest relative difference: 1.0 at index (49,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 37 / 50 (74.0%)
E Greatest absolute difference: 4 at index (49,)
E Greatest relative difference: 1.0 at index (13,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 37 / 50 (74.0%)
E Greatest absolute difference: 4 at index (49,)
E Greatest relative difference: 1.0 at index (13,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 37 / 50 (74.0%)
E Greatest absolute difference: 4 at index (49,)
E Greatest relative difference: 1.0 at index (13,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 1 / 50 (2.0%)
E Greatest absolute difference: 1 at index (49,)
E Greatest relative difference: 0.019999999552965164 at index (49,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 1 / 50 (2.0%)
E Greatest absolute difference: 1 at index (49,)
E Greatest relative difference: 0.019999999552965164 at index (49,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 1 / 50 (2.0%)
E Greatest absolute difference: 1 at index (49,)
E Greatest relative difference: 0.019999999552965164 at index (49,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 7 at index (49,)
E Greatest relative difference: inf at index (22,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 7 at index (49,)
E Greatest relative difference: inf at index (22,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 7 at index (49,)
E Greatest relative difference: inf at index (22,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 4 at index (37,)
E Greatest relative difference: inf at index (37,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 4 at index (37,)
E Greatest relative difference: inf at index (37,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 4 at index (37,)
E Greatest relative difference: inf at index (37,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 3 at index (33,)
E Greatest relative difference: 3.0 at index (33,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 3 at index (33,)
E Greatest relative difference: 3.0 at index (33,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 3 at index (33,)
E Greatest relative difference: 3.0 at index (33,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 48 / 50 (96.0%)
E Greatest absolute difference: 46 at index (49,)
E Greatest relative difference: 0.9200000166893005 at index (49,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 48 / 50 (96.0%)
E Greatest absolute difference: 46 at index (49,)
E Greatest relative difference: 0.9200000166893005 at index (49,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 48 / 50 (96.0%)
E Greatest absolute difference: 46 at index (49,)
E Greatest relative difference: 0.9200000166893005 at index (49,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 4 at index (37,)
E Greatest relative difference: inf at index (46,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 4 at index (37,)
E Greatest relative difference: inf at index (46,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 4 at index (37,)
E Greatest relative difference: inf at index (46,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 1 at index (1,)
E Greatest relative difference: inf at index (49,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 1 at index (1,)
E Greatest relative difference: inf at index (49,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 1 at index (1,)
E Greatest relative difference: inf at index (49,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 46 at index (48,)
E Greatest relative difference: 11.5 at index (48,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 46 at index (48,)
E Greatest relative difference: 11.5 at index (48,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 46 at index (48,)
E Greatest relative difference: 11.5 at index (48,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 43 / 50 (86.0%)
E Greatest absolute difference: 7 at index (49,)
E Greatest relative difference: 1.0 at index (7,)
github-actions / Test Results
All 3 runs failed: test_output_match_opinfo__addmv_cpu_float16 (onnxscript.tests.function_libs.torch_lib.ops_test.TestOutputConsistencyFullGraphCPU)
artifacts/Test Results (py310-torch-nightly-macos-latest)/pytest.xml [took 0s]
artifacts/Test Results (py310-torch-nightly-ubuntu-latest)/pytest.xml [took 0s]
artifacts/Test Results (py310-torch-nightly-windows-latest)/pytest.xml [took 0s]
Raw output
AssertionError: Tensor-likes are not close!
Mismatched elements: 1 / 5 (20.0%)
Greatest absolute difference: 0.01171875 at index (1,) (up to 1e-05 allowed)
Greatest relative difference: 0.0018596649169921875 at index (1,) (up to 0.001 allowed)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not close!
E
E Mismatched elements: 1 / 5 (20.0%)
E Greatest absolute difference: 0.01171875 at index (1,) (up to 1e-05 allowed)
E Greatest relative difference: 0.0018596649169921875 at index (1,) (up to 0.001 allowed)
github-actions / Test Results
All 3 runs failed: test_output_match_opinfo__linspace_tensor_overload_cpu_float16 (onnxscript.tests.function_libs.torch_lib.ops_test.TestOutputConsistencyFullGraphCPU)
artifacts/Test Results (py310-torch-nightly-macos-latest)/pytest.xml [took 27s]
artifacts/Test Results (py310-torch-nightly-ubuntu-latest)/pytest.xml [took 8s]
artifacts/Test Results (py310-torch-nightly-windows-latest)/pytest.xml [took 6s]
Raw output
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float input_0, int64 input_1) => (float16[0] _val_16)
<float _val_2, float _val_3, float _val_4, float _val_5, float _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
{
_val_2 = Constant <value: tensor = float {0}> ()
_val_3 = Cast <to: int = 1> (_val_2)
_val_4 = Constant <value: tensor = float {1}> ()
_val_5 = Cast <to: int = 1> (_val_4)
_val_6 = Cast <to: int = 1> (input_0)
_val_7 = Cast <to: int = 1> (input_1)
_val_8 = Constant <value: tensor = int64 {0}> ()
_val_9 = Cast <to: int = 1> (_val_8)
_val_10 = Range (_val_3, _val_9, _val_5)
_val_11 = CastLike (_val_6, _val_7)
_val_12 = Sub (_val_7, _val_11)
_val_13 = Sub (_val_9, _val_5)
_val_14 = Div (_val_12, _val_13)
_val_15 = Mul (_val_10, _val_14)
_val_16 = Add (_val_15, _val_11)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float input_0) => (float16[0] _val_16)
<float _val_1, float _val_2, float _val_3, float _val_4, float _val_5, int64 _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
{
_val_1 = Constant <value: tensor = float {0}> ()
_val_2 = Cast <to: int = 1> (_val_1)
_val_3 = Constant <value: tensor = float {1}> ()
_val_4 = Cast <to: int = 1> (_val_3)
_val_5 = Cast <to: int = 1> (input_0)
_val_6 = Constant <value: tensor = int64 {-3}> ()
_val_7 = Cast <to: int = 1> (_val_6)
_val_8 = Constant <value: tensor = int64 {0}> ()
_val_9 = Cast <to: int = 1> (_val_8)
_val_10 = Range (_val_2, _val_9, _val_4)
_val_11 = CastLike (_val_5, _val_7)
_val_12 = Sub (_val_7, _val_11)
_val_13 = Sub (_val_9, _val_4)
_val_14 = Div (_val_12, _val_13)
_val_15 = Mul (_val_10, _val_14)
_val_16 = Add (_val_15, _val_11)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int64 input_1) => (float16[0] _val_16)
<float _val_1, float _val_2, float _val_3, float _val_4, float _val_5, float _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
{
_val_1 = Constant <value: tensor = float {0}> ()
_val_2 = Cast <to: int = 1> (_val_1)
_val_3 = Constant <value: tensor = float {1}> ()
_val_4 = Cast <to: int = 1> (_val_3)
_val_5 = Constant <value: tensor = float {-2}> ()
_val_6 = Cast <to: int = 1> (_val_5)
_val_7 = Cast <to: int = 1> (input_1)
_val_8 = Constant <value: tensor = int64 {0}> ()
_val_9 = Cast <to: int = 1> (_val_8)
_val_10 = Range (_val_2, _val_9, _val_4)
_val_11 = CastLike (_val_6, _val_7)
_val_12 = Sub (_val_7, _val_11)
_val_13 = Sub (_val_9, _val_4)
_val_14 = Div (_val_12, _val_13)
_val_15 = Mul (_val_10, _val_14)
_val_16 = Add (_val_15, _val_11)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float input_0, int64 input_1) => (float16[50] _val_16)
<float _val_2, float _val_3, float _val_4, float _val_5, float _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
{
_val_2 = Constant <value: tensor = float {0}> ()
_val_3 = Cast <to: int = 1> (_val_2)
_val_4 = Constant <value: tensor = float {1}> ()
_val_5 = Cast <to: int = 1> (_val_4)
_val_6 = Cast <to: int = 1> (input_0)
_val_7 = Cast <to: int = 1> (input_1)
_val_8 = Constant <value: tensor = int64 {50}> ()
_val_9 = Cast <to: int = 1> (_val_8)
_val_10 = Range (_val_3, _val_9, _val_5)
_val_11 = CastLike (_val_6, _val_7)
_val_12 = Sub (_val_7, _val_11)
_val_13 = Sub (_val_9, _val_5)
_val_14 = Div (_val_12, _val_13)
_val_15 = Mul (_val_10, _val_14)
_val_16 = Add (_val_15, _val_11)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float input_0) => (float16[50] _val_16)
<float _val_1, float _val_2, float _val_3, float _val_4, float _val_5, int64 _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
{
_val_1 = Constant <value: tensor = float {0}> ()
_val_2 = Cast <to: int = 1> (_val_1)
_val_3 = Constant <value: tensor = float {1}> ()
_val_4 = Cast <to: int = 1> (_val_3)
_val_5 = Cast <to: int = 1> (input_0)
_val_6 = Constant <value: tensor = int64 {-3}> ()
_val_7 = Cast <to: int = 1> (_val_6)
_val_8 = Constant <value: tensor = int64 {50}> ()
_val_9 = Cast <to: int = 1> (_val_8)
_val_10 = Range (_val_2, _val_9, _val_4)
_val_11 = CastLike (_val_5, _val_7)
_val_12 = Sub (_val_7, _val_11)
_val_13 = Sub (_val_9, _val_4)
_val_14 = Div (_val_12, _val_13)
_val_15 = Mul (_val_10, _val_14)
_val_16 = Add (_val_15, _val_11)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int64 input_1) => (float16[50] _val_16)
<float _val_1, float _val_2, float _val_3, float _val_4, float _val_5, float _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
{
_val_1 = Constant <value: tensor = float {0}> ()
_val_2 = Cast <to: int = 1> (_val_1)
_val_3 = Constant <value: tensor = float {1}> ()
_val_4 = Cast <to: int = 1> (_val_3)
_val_5 = Constant <value: tensor = float {-2}> ()
_val_6 = Cast <to: int = 1> (_val_5)
_val_7 = Cast <to: int = 1> (input_1)
_val_8 = Constant <value: tensor = int64 {50}> ()
_val_9 = Cast <to: int = 1> (_val_8)
_val_10 = Range (_val_2, _val_9, _val_4)
_val_11 = CastLike (_val_6, _val_7)
_val_12 = Sub (_val_7, _val_11)
_val_13 = Sub (_val_9, _val_4)
_val_14 = Div (_val_12, _val_13)
_val_15 = Mul (_val_10, _val_14)
_val_16 = Add (_val_15, _val_11)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float input_0, int64 input_1) => (float16[0] _val_16)
<float _val_2, float _val_3, float _val_4, float _val_5, float _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
{
_val_2 = Constant <value: tensor = float {0}> ()
_val_3 = Cast <to: int = 1> (_val_2)
_val_4 = Constant <value: tensor = float {1}> ()
_val_5 = Cast <to: int = 1> (_val_4)
_val_6 = Cast <to: int = 1> (input_0)
_val_7 = Cast <to: int = 1> (input_1)
_val_8 = Constant <value: tensor = int64 {0}> ()
_val_9 = Cast <to: int = 1> (_val_8)
_val_10 = Range (_val_3, _val_9, _val_5)
_val_11 = CastLike (_val_6, _val_7)
_val_12 = Sub (_val_7, _val_11)
_val_13 = Sub (_val_9, _val_5)
_val_14 = Div (_val_12, _val_13)
_val_15 = Mul (_val_10, _val_14)
_val_16 = Add (_val_15, _val_11)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float input_0) => (float16[0] _val_16)
<float _val_1, float _val_2, float _val_3, float _val_4, float _val_5, int64 _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
{
_val_1 = Constant <value: tensor = float {0}> ()
_val_2 = Cast <to: int = 1> (_val_1)
_val_3 = Constant <value: tensor = float {1}> ()
_val_4 = Cast <to: int = 1> (_val_3)
_val_5 = Cast <to: int = 1> (input_0)
_val_6 = Constant <value: tensor = int64 {0}> ()
_val_7 = Cast <to: int = 1> (_val_6)
_val_8 = Constant <value: tensor = int64 {0}> ()
_val_9 = Cast <to: int = 1> (_val_8)
_val_10 = Range (_val_2, _val_9, _val_4)
_val_11 = CastLike (_val_5, _val_7)
_val_12 = Sub (_val_7, _val_11)
_val_13 = Sub (_val_9, _val_4)
_val_14 = Div (_val_12, _val_13)
_val_15 = Mul (_val_10, _val_14)
_val_16 = Add (_val_15, _val_11)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int64 input_1) => (float16[0] _val_16)
<float _val_1, float _val_2, float _val_3, float _val_4, float _val_5, float _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
{
_val_1 = Constant <value: tensor = float {0}> ()
_val_2 = Cast <to: int = 1> (_val_1)
_val_3 = Constant <value: tensor = float {1}> ()
_val_4 = Cast <to: int = 1> (_val_3)
_val_5 = Constant <value: tensor = float {-2}> ()
_val_6 = Cast <to: int = 1> (_val_5)
_val_7 = Cast <to: int = 1> (input_1)
_val_8 = Constant <value: tensor = int64 {0}> ()
_val_9 = Cast <to: int = 1> (_val_8)
_val_10 = Range (_val_2, _val_9, _val_4)
_val_11 = CastLike (_val_6, _val_7)
_val_12 = Sub (_val_7, _val_11)
_val_13 = Sub (_val_9, _val_4)
_val_14 = Div (_val_12, _val_13)
_val_15 = Mul (_val_10, _val_14)
_val_16 = Add (_val_15, _val_11)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float input_0, int64 input_1) => (float16[50] _val_16)
<float _val_2, float _val_3, float _val_4, float _val_5, float _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
{
_val_2 = Constant <value: tensor = float {0}> ()
_val_3 = Cast <to: int = 1> (_val_2)
_val_4 = Constant <value: tensor = float {1}> ()
_val_5 = Cast <to: int = 1> (_val_4)
_val_6 = Cast <to: int = 1> (input_0)
_val_7 = Cast <to: int = 1> (input_1)
_val_8 = Constant <value: tensor = int64 {50}> ()
_val_9 = Cast <to: int = 1> (_val_8)
_val_10 = Range (_val_3, _val_9, _val_5)
_val_11 = CastLike (_val_6, _val_7)
_val_12 = Sub (_val_7, _val_11)
_val_13 = Sub (_val_9, _val_5)
_val_14 = Div (_val_12, _val_13)
_val_15 = Mul (_val_10, _val_14)
_val_16 = Add (_val_15, _val_11)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float input_0) => (float16[50] _val_16)
<float _val_1, float _val_2, float _val_3, float _val_4, float _val_5, int64 _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
{
_val_1 = Constant <value: tensor = float {0}> ()
_val_2 = Cast <to: int = 1> (_val_1)
_val_3 = Constant <value: tensor = float {1}> ()
_val_4 = Cast <to: int = 1> (_val_3)
_val_5 = Cast <to: int = 1> (input_0)
_val_6 = Constant <value: tensor = int64 {0}> ()
_val_7 = Cast <to: int = 1> (_val_6)
_val_8 = Constant <value: tensor = int64 {50}> ()
_val_9 = Cast <to: int = 1> (_val_8)
_val_10 = Range (_val_2, _val_9, _val_4)
_val_11 = CastLike (_val_5, _val_7)
_val_12 = Sub (_val_7, _val_11)
_val_13 = Sub (_val_9, _val_4)
_val_14 = Div (_val_12, _val_13)
_val_15 = Mul (_val_10, _val_14)
_val_16 = Add (_val_15, _val_11)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int64 input_1) => (float16[50] _val_16)
<float _val_1, float _val_2, float _val_3, float _val_4, float _val_5, float _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
{
_val_1 = Constant <value: tensor = float {0}> ()
_val_2 = Cast <to: int = 1> (_val_1)
_val_3 = Constant <value: tensor = float {1}> ()
_val_4 = Cast <to: int = 1> (_val_3)
_val_5 = Constant <value: tensor = float {-2}> ()
_val_6 = Cast <to: int = 1> (_val_5)
_val_7 = Cast <to: int = 1> (input_1)
_val_8 = Constant <value: tensor = int64 {50}> ()
_val_9 = Cast <to: int = 1> (_val_8)
_val_10 = Range (_val_2, _val_9, _val_4)
_val_11 = CastLike (_val_6, _val_7)
_val_12 = Sub (_val_7, _val_11)
_val_13 = Sub (_val_9, _val_4)
_val_14 = Div (_val_12, _val_13)
_val_15 = Mul (_val_10, _val_14)
_val_16 = Add (_val_15, _val_11)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float input_0, int64 input_1) => (float16[0] _val_16)
<float _val_2, float _val_3, float _val_4, float _val_5, float _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
{
_val_2 = Constant <value: tensor = float {0}> ()
_val_3 = Cast <to: int = 1> (_val_2)
_val_4 = Constant <value: tensor = float {1}> ()
_val_5 = Cast <to: int = 1> (_val_4)
_val_6 = Cast <to: int = 1> (input_0)
_val_7 = Cast <to: int = 1> (input_1)
_val_8 = Constant <value: tensor = int64 {0}> ()
_val_9 = Cast <to: int = 1> (_val_8)
_val_10 = Range (_val_3, _val_9, _val_5)
_val_11 = CastLike (_val_6, _val_7)
_val_12 = Sub (_val_7, _val_11)
_val_13 = Sub (_val_9, _val_5)
_val_14 = Div (_val_12, _val_13)
_val_15 = Mul (_val_10, _val_14)
_val_16 = Add (_val_15, _val_11)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float input_0) => (float16[0] _val_16)
<float _val_1, float _val_2, float _val_3, float _val_4, float _val_5, int64 _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
{
_val_1 = Constant <value: tensor = float {0}> ()
_val_2 = Cast <to: int = 1> (_val_1)
_val_3 = Constant <value: tensor = float {1}> ()
_val_4 = Cast <to: int = 1> (_val_3)
_val_5 = Cast <to: int = 1> (input_0)
_val_6 = Constant <value: tensor = int64 {1}> ()
_val_7 = Cast <to: int = 1> (_val_6)
_val_8 = Constant <value: tensor = int64 {0}> ()
_val_9 = Cast <to: int = 1> (_val_8)
_val_10 = Range (_val_2, _val_9, _val_4)
_val_11 = CastLike (_val_5, _val_7)
_val_12 = Sub (_val_7, _val_11)
_val_13 = Sub (_val_9, _val_4)
_val_14 = Div (_val_12, _val_13)
_val_15 = Mul (_val_10, _val_14)
_val_16 = Add (_val_15, _val_11)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int64 input_1) => (float16[0] _val_16)
<float _val_1, float _val_2, float _val_3, float _val_4, float _val_5, float _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
{
_val_1 = Constant <value: tensor = float {0}> ()
_val_2 = Cast <to: int = 1> (_val_1)
_val_3 = Constant <value: tensor = float {1}> ()
_val_4 = Cast <to: int = 1> (_val_3)
_val_5 = Constant <value: tensor = float {-2}> ()
_val_6 = Cast <to: int = 1> (_val_5)
_val_7 = Cast <to: int = 1> (input_1)
_val_8 = Constant <value: tensor = int64 {0}> ()
_val_9 = Cast <to: int = 1> (_val_8)
_val_10 = Range (_val_2, _val_9, _val_4)
_val_11 = CastLike (_val_6, _val_7)
_val_12 = Sub (_val_7, _val_11)
_val_13 = Sub (_val_9, _val_4)
_val_14 = Div (_val_12, _val_13)
_val_15 = Mul (_val_10, _val_14)
_val_16 = Add (_val_15, _val_11)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float input_0, int64 input_1) => (float16[50] _val_16)
<float _val_2, float _val_3, float _val_4, float _val_5, float _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
{
_val_2 = Constant <value: tensor = float {0}> ()
_val_3 = Cast <to: int = 1> (_val_2)
_val_4 = Constant <value: tensor = float {1}> ()
_val_5 = Cast <to: int = 1> (_val_4)
_val_6 = Cast <to: int = 1> (input_0)
_val_7 = Cast <to: int = 1> (input_1)
_val_8 = Constant <value: tensor = int64 {50}> ()
_val_9 = Cast <to: int = 1> (_val_8)
_val_10 = Range (_val_3, _val_9, _val_5)
_val_11 = CastLike (_val_6, _val_7)
_val_12 = Sub (_val_7, _val_11)
_val_13 = Sub (_val_9, _val_5)
_val_14 = Div (_val_12, _val_13)
_val_15 = Mul (_val_10, _val_14)
_val_16 = Add (_val_15, _val_11)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float input_0) => (float16[50] _val_16)
<float _val_1, float _val_2, float _val_3, float _val_4, float _val_5, int64 _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
{
_val_1 = Constant <value: tensor = float {0}> ()
_val_2 = Cast <to: int = 1> (_val_1)
_val_3 = Constant <value: tensor = float {1}> ()
_val_4 = Cast <to: int = 1> (_val_3)
_val_5 = Cast <to: int = 1> (input_0)
_val_6 = Constant <value: tensor = int64 {1}> ()
_val_7 = Cast <to: int = 1> (_val_6)
_val_8 = Constant <value: tensor = int64 {50}> ()
_val_9 = Cast <to: int = 1> (_val_8)
_val_10 = Range (_val_2, _val_9, _val_4)
_val_11 = CastLike (_val_5, _val_7)
_val_12 = Sub (_val_7, _val_11)
_val_13 = Sub (_val_9, _val_4)
_val_14 = Div (_val_12, _val_13)
_val_15 = Mul (_val_10, _val_14)
_val_16 = Add (_val_15, _val_11)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int64 input_1) => (float16[50] _val_16)
<float _val_1, float _val_2, float _val_3, float _val_4, float _val_5, float _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
{
_val_1 = Constant <value: tensor = float {0}> ()
_val_2 = Cast <to: int = 1> (_val_1)
_val_3 = Constant <value: tensor = float {1}> ()
_val_4 = Cast <to: int = 1> (_val_3)
_val_5 = Constant <value: tensor = float {-2}> ()
_val_6 = Cast <to: int = 1> (_val_5)
_val_7 = Cast <to: int = 1> (input_1)
_val_8 = Constant <value: tensor = int64 {50}> ()
_val_9 = Cast <to: int = 1> (_val_8)
_val_10 = Range (_val_2, _val_9, _val_4)
_val_11 = CastLike (_val_6, _val_7)
_val_12 = Sub (_val_7, _val_11)
_val_13 = Sub (_val_9, _val_4)
_val_14 = Div (_val_12, _val_13)
_val_15 = Mul (_val_10, _val_14)
_val_16 = Add (_val_15, _val_11)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float input_0, int64 input_1) => (float16[0] _val_16)
<float _val_2, float _val_3, float _val_4, float _val_5, float _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
{
_val_2 = Constant <value: tensor = float {0}> ()
_val_3 = Cast <to: int = 1> (_val_2)
_val_4 = Constant <value: tensor = float {1}> ()
_val_5 = Cast <to: int = 1> (_val_4)
_val_6 = Cast <to: int = 1> (input_0)
_val_7 = Cast <to: int = 1> (input_1)
_val_8 = Constant <value: tensor = int64 {0}> ()
_val_9 = Cast <to: int = 1> (_val_8)
_val_10 = Range (_val_3, _val_9, _val_5)
_val_11 = CastLike (_val_6, _val_7)
_val_12 = Sub (_val_7, _val_11)
_val_13 = Sub (_val_9, _val_5)
_val_14 = Div (_val_12, _val_13)
_val_15 = Mul (_val_10, _val_14)
_val_16 = Add (_val_15, _val_11)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (float input_0) => (float16[0] _val_16)
<float _val_1, float _val_2, float _val_3, float _val_4, float _val_5, int64 _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
{
_val_1 = Constant <value: tensor = float {0}> ()
_val_2 = Cast <to: int = 1> (_val_1)
_val_3 = Constant <value: tensor = float {1}> ()
_val_4 = Cast <to: int = 1> (_val_3)
_val_5 = Cast <to: int = 1> (input_0)
_val_6 = Constant <value: tensor = int64 {4}> ()
_val_7 = Cast <to: int = 1> (_val_6)
_val_8 = Constant <value: tensor = int64 {0}> ()
_val_9 = Cast <to: int = 1> (_val_8)
_val_10 = Range (_val_2, _val_9, _val_4)
_val_11 = CastLike (_val_5, _val_7)
_val_12 = Sub (_val_7, _val_11)
_val_13 = Sub (_val_9, _val_4)
_val_14 = Div (_val_12, _val_13)
_val_15 = Mul (_val_10, _val_14)
_val_16 = Add (_val_15, _val_11)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
IsScalar (input) => (return_val)
{
tmp = Shape (input)
tmp_0 = Size (tmp)
tmp_1 = Constant <value_int: int = 0> ()
return_val = Equal (tmp_0, tmp_1)
}
AssertionError: ONNX model is invalid. Model:
<
ir_version: 8,
opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
producer_name: "pytorch",
producer_version: "2.2.0"
>
main_graph (int64 input_1) => (float16[0] _val_16)
<float _val_1, float _val_2, float _val_3, float _val_4, float _val_5, float _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
{
_val_1 = Constant <value: tensor = float {0}> ()
_val_2 = Cast <to: int = 1> (_val_1)
_val_3 = Constant <value: tensor = float {1}> ()
_val_4 = Cast <to: int = 1> (_val_3)
_val_5 = Constant <value: tensor = float {-2}> ()
_val_6 = Cast <to: int = 1> (_val_5)
_val_7 = Cast <to: int = 1> (input_1)
_val_8 = Constant <value: tensor = int64 {0}> ()
_val_9 = Cast <to: int = 1> (_val_8)
_val_10 = Range (_val_2, _val_9, _val_4)
_val_11 = CastLike (_val_6, _val_7)
_val_12 = Sub (_val_7, _val_11)
_val_13 = Sub (_val_9, _val_4)
_val_14 = Div (_val_12, _val_13)
_val_15 = Mul (_val_10, _val_14)
_val_16 = Add (_val_15, _val_11)
}
<
domain: "pkg.onnxscript.torch_lib.common",
opset_import: ["" : 18]
>
Rank (input) => (return_val)
{
tmp = Shape (input)
return_val = Size (tmp)
}
<
domain:…
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:Add, node name: Add_19): [TypeInferenceError] Inferred elem type differs from existing elem type: (1) vs (10)
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int64 input_0) => (float16[0] _val_16)
E <float _val_1, float _val_2, float _val_3, float _val_4, float _val_5, int64 _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
E {
E _val_1 = Constant <value: tensor = float {0}> ()
E _val_2 = Cast <to: int = 1> (_val_1)
E _val_3 = Constant <value: tensor = float {1}> ()
E _val_4 = Cast <to: int = 1> (_val_3)
E _val_5 = Cast <to: int = 1> (input_0)
E _val_6 = Constant <value: tensor = int64 {4}> ()
E _val_7 = Cast <to: int = 1> (_val_6)
E _val_8 = Constant <value: tensor = int64 {0}> ()
E _val_9 = Cast <to: int = 1> (_val_8)
E _val_10 = Range (_val_2, _val_9, _val_4)
E _val_11 = CastLike (_val_5, _val_7)
E _val_12 = Sub (_val_7, _val_11)
E _val_13 = Sub (_val_9, _val_4)
E _val_14 = Div (_val_12, _val_13)
E _val_15 = Mul (_val_10, _val_14)
E _val_16 = Add (_val_15, _val_11)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:Add, node name: Add_19): [TypeInferenceError] Inferred elem type differs from existing elem type: (1) vs (10)
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int64 input_1) => (float16[0] _val_16)
E <float _val_1, float _val_2, float _val_3, float _val_4, int64 _val_5, float _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
E {
E _val_1 = Constant <value: tensor = float {0}> ()
E _val_2 = Cast <to: int = 1> (_val_1)
E _val_3 = Constant <value: tensor = float {1}> ()
E _val_4 = Cast <to: int = 1> (_val_3)
E _val_5 = Constant <value: tensor = int64 {50}> ()
E _val_6 = Cast <to: int = 1> (_val_5)
E _val_7 = Cast <to: int = 1> (input_1)
E _val_8 = Constant <value: tensor = int64 {0}> ()
E _val_9 = Cast <to: int = 1> (_val_8)
E _val_10 = Range (_val_2, _val_9, _val_4)
E _val_11 = CastLike (_val_6, _val_7)
E _val_12 = Sub (_val_7, _val_11)
E _val_13 = Sub (_val_9, _val_4)
E _val_14 = Div (_val_12, _val_13)
E _val_15 = Mul (_val_10, _val_14)
E _val_16 = Add (_val_15, _val_11)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:Add, node name: Add_17): [TypeInferenceError] Inferred elem type differs from existing elem type: (1) vs (10)
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int64 input_0, int64 input_1) => (float16[50] _val_16)
E <float _val_2, float _val_3, float _val_4, float _val_5, float _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
E {
E _val_2 = Constant <value: tensor = float {0}> ()
E _val_3 = Cast <to: int = 1> (_val_2)
E _val_4 = Constant <value: tensor = float {1}> ()
E _val_5 = Cast <to: int = 1> (_val_4)
E _val_6 = Cast <to: int = 1> (input_0)
E _val_7 = Cast <to: int = 1> (input_1)
E _val_8 = Constant <value: tensor = int64 {50}> ()
E _val_9 = Cast <to: int = 1> (_val_8)
E _val_10 = Range (_val_3, _val_9, _val_5)
E _val_11 = CastLike (_val_6, _val_7)
E _val_12 = Sub (_val_7, _val_11)
E _val_13 = Sub (_val_9, _val_5)
E _val_14 = Div (_val_12, _val_13)
E _val_15 = Mul (_val_10, _val_14)
E _val_16 = Add (_val_15, _val_11)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:Add, node name: Add_19): [TypeInferenceError] Inferred elem type differs from existing elem type: (1) vs (10)
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int64 input_0) => (float16[50] _val_16)
E <float _val_1, float _val_2, float _val_3, float _val_4, float _val_5, int64 _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
E {
E _val_1 = Constant <value: tensor = float {0}> ()
E _val_2 = Cast <to: int = 1> (_val_1)
E _val_3 = Constant <value: tensor = float {1}> ()
E _val_4 = Cast <to: int = 1> (_val_3)
E _val_5 = Cast <to: int = 1> (input_0)
E _val_6 = Constant <value: tensor = int64 {4}> ()
E _val_7 = Cast <to: int = 1> (_val_6)
E _val_8 = Constant <value: tensor = int64 {50}> ()
E _val_9 = Cast <to: int = 1> (_val_8)
E _val_10 = Range (_val_2, _val_9, _val_4)
E _val_11 = CastLike (_val_5, _val_7)
E _val_12 = Sub (_val_7, _val_11)
E _val_13 = Sub (_val_9, _val_4)
E _val_14 = Div (_val_12, _val_13)
E _val_15 = Mul (_val_10, _val_14)
E _val_16 = Add (_val_15, _val_11)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:Add, node name: Add_19): [TypeInferenceError] Inferred elem type differs from existing elem type: (1) vs (10)
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int64 input_1) => (float16[50] _val_16)
E <float _val_1, float _val_2, float _val_3, float _val_4, int64 _val_5, float _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
E {
E _val_1 = Constant <value: tensor = float {0}> ()
E _val_2 = Cast <to: int = 1> (_val_1)
E _val_3 = Constant <value: tensor = float {1}> ()
E _val_4 = Cast <to: int = 1> (_val_3)
E _val_5 = Constant <value: tensor = int64 {50}> ()
E _val_6 = Cast <to: int = 1> (_val_5)
E _val_7 = Cast <to: int = 1> (input_1)
E _val_8 = Constant <value: tensor = int64 {50}> ()
E _val_9 = Cast <to: int = 1> (_val_8)
E _val_10 = Range (_val_2, _val_9, _val_4)
E _val_11 = CastLike (_val_6, _val_7)
E _val_12 = Sub (_val_7, _val_11)
E _val_13 = Sub (_val_9, _val_4)
E _val_14 = Div (_val_12, _val_13)
E _val_15 = Mul (_val_10, _val_14)
E _val_16 = Add (_val_15, _val_11)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:Add, node name: Add_17): [TypeInferenceError] Inferred elem type differs from existing elem type: (1) vs (10)
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int64 input_0, int64 input_1) => (float16[0] _val_16)
E <float _val_2, float _val_3, float _val_4, float _val_5, float _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
E {
E _val_2 = Constant <value: tensor = float {0}> ()
E _val_3 = Cast <to: int = 1> (_val_2)
E _val_4 = Constant <value: tensor = float {1}> ()
E _val_5 = Cast <to: int = 1> (_val_4)
E _val_6 = Cast <to: int = 1> (input_0)
E _val_7 = Cast <to: int = 1> (input_1)
E _val_8 = Constant <value: tensor = int64 {0}> ()
E _val_9 = Cast <to: int = 1> (_val_8)
E _val_10 = Range (_val_3, _val_9, _val_5)
E _val_11 = CastLike (_val_6, _val_7)
E _val_12 = Sub (_val_7, _val_11)
E _val_13 = Sub (_val_9, _val_5)
E _val_14 = Div (_val_12, _val_13)
E _val_15 = Mul (_val_10, _val_14)
E _val_16 = Add (_val_15, _val_11)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:Add, node name: Add_19): [TypeInferenceError] Inferred elem type differs from existing elem type: (1) vs (10)
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int64 input_0) => (float16[0] _val_16)
E <float _val_1, float _val_2, float _val_3, float _val_4, float _val_5, int64 _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
E {
E _val_1 = Constant <value: tensor = float {0}> ()
E _val_2 = Cast <to: int = 1> (_val_1)
E _val_3 = Constant <value: tensor = float {1}> ()
E _val_4 = Cast <to: int = 1> (_val_3)
E _val_5 = Cast <to: int = 1> (input_0)
E _val_6 = Constant <value: tensor = int64 {50}> ()
E _val_7 = Cast <to: int = 1> (_val_6)
E _val_8 = Constant <value: tensor = int64 {0}> ()
E _val_9 = Cast <to: int = 1> (_val_8)
E _val_10 = Range (_val_2, _val_9, _val_4)
E _val_11 = CastLike (_val_5, _val_7)
E _val_12 = Sub (_val_7, _val_11)
E _val_13 = Sub (_val_9, _val_4)
E _val_14 = Div (_val_12, _val_13)
E _val_15 = Mul (_val_10, _val_14)
E _val_16 = Add (_val_15, _val_11)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:Add, node name: Add_19): [TypeInferenceError] Inferred elem type differs from existing elem type: (1) vs (10)
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int64 input_1) => (float16[0] _val_16)
E <float _val_1, float _val_2, float _val_3, float _val_4, int64 _val_5, float _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
E {
E _val_1 = Constant <value: tensor = float {0}> ()
E _val_2 = Cast <to: int = 1> (_val_1)
E _val_3 = Constant <value: tensor = float {1}> ()
E _val_4 = Cast <to: int = 1> (_val_3)
E _val_5 = Constant <value: tensor = int64 {50}> ()
E _val_6 = Cast <to: int = 1> (_val_5)
E _val_7 = Cast <to: int = 1> (input_1)
E _val_8 = Constant <value: tensor = int64 {0}> ()
E _val_9 = Cast <to: int = 1> (_val_8)
E _val_10 = Range (_val_2, _val_9, _val_4)
E _val_11 = CastLike (_val_6, _val_7)
E _val_12 = Sub (_val_7, _val_11)
E _val_13 = Sub (_val_9, _val_4)
E _val_14 = Div (_val_12, _val_13)
E _val_15 = Mul (_val_10, _val_14)
E _val_16 = Add (_val_15, _val_11)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:Add, node name: Add_17): [TypeInferenceError] Inferred elem type differs from existing elem type: (1) vs (10)
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int64 input_0, int64 input_1) => (float16[50] _val_16)
E <float _val_2, float _val_3, float _val_4, float _val_5, float _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
E {
E _val_2 = Constant <value: tensor = float {0}> ()
E _val_3 = Cast <to: int = 1> (_val_2)
E _val_4 = Constant <value: tensor = float {1}> ()
E _val_5 = Cast <to: int = 1> (_val_4)
E _val_6 = Cast <to: int = 1> (input_0)
E _val_7 = Cast <to: int = 1> (input_1)
E _val_8 = Constant <value: tensor = int64 {50}> ()
E _val_9 = Cast <to: int = 1> (_val_8)
E _val_10 = Range (_val_3, _val_9, _val_5)
E _val_11 = CastLike (_val_6, _val_7)
E _val_12 = Sub (_val_7, _val_11)
E _val_13 = Sub (_val_9, _val_5)
E _val_14 = Div (_val_12, _val_13)
E _val_15 = Mul (_val_10, _val_14)
E _val_16 = Add (_val_15, _val_11)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:Add, node name: Add_19): [TypeInferenceError] Inferred elem type differs from existing elem type: (1) vs (10)
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int64 input_0) => (float16[50] _val_16)
E <float _val_1, float _val_2, float _val_3, float _val_4, float _val_5, int64 _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
E {
E _val_1 = Constant <value: tensor = float {0}> ()
E _val_2 = Cast <to: int = 1> (_val_1)
E _val_3 = Constant <value: tensor = float {1}> ()
E _val_4 = Cast <to: int = 1> (_val_3)
E _val_5 = Cast <to: int = 1> (input_0)
E _val_6 = Constant <value: tensor = int64 {50}> ()
E _val_7 = Cast <to: int = 1> (_val_6)
E _val_8 = Constant <value: tensor = int64 {50}> ()
E _val_9 = Cast <to: int = 1> (_val_8)
E _val_10 = Range (_val_2, _val_9, _val_4)
E _val_11 = CastLike (_val_5, _val_7)
E _val_12 = Sub (_val_7, _val_11)
E _val_13 = Sub (_val_9, _val_4)
E _val_14 = Div (_val_12, _val_13)
E _val_15 = Mul (_val_10, _val_14)
E _val_16 = Add (_val_15, _val_11)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:Add, node name: Add_19): [TypeInferenceError] Inferred elem type differs from existing elem type: (1) vs (10)
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int64 input_1) => (float16[50] _val_16)
E <float _val_1, float _val_2, float _val_3, float _val_4, int64 _val_5, float _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
E {
E _val_1 = Constant <value: tensor = float {0}> ()
E _val_2 = Cast <to: int = 1> (_val_1)
E _val_3 = Constant <value: tensor = float {1}> ()
E _val_4 = Cast <to: int = 1> (_val_3)
E _val_5 = Constant <value: tensor = int64 {50}> ()
E _val_6 = Cast <to: int = 1> (_val_5)
E _val_7 = Cast <to: int = 1> (input_1)
E _val_8 = Constant <value: tensor = int64 {50}> ()
E _val_9 = Cast <to: int = 1> (_val_8)
E _val_10 = Range (_val_2, _val_9, _val_4)
E _val_11 = CastLike (_val_6, _val_7)
E _val_12 = Sub (_val_7, _val_11)
E _val_13 = Sub (_val_9, _val_4)
E _val_14 = Div (_val_12, _val_13)
E _val_15 = Mul (_val_10, _val_14)
E _val_16 = Add (_val_15, _val_11)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:522: in _capture_graph_and_evaluate_torch_script_evaluator
onnx.checker.check_model(onnx_model, full_check=True)
.nox/test_torch_nightly/lib/python3.10/site-packages/onnx/checker.py:148: in check_model
C.check_model(protobuf_string, full_check, skip_opset_compatibility_check)
E onnx.onnx_cpp2py_export.shape_inference.InferenceError: [ShapeInferenceError] Inference error(s): (op_type:Add, node name: Add_17): [TypeInferenceError] Inferred elem type differs from existing elem type: (1) vs (10)
The above exception was the direct cause of the following exception:
onnxscript/tests/function_libs/torch_lib/ops_test.py:230: in run_test_output_match
function_output = function_executor(test_name, reference_torch_outputs)(
onnxscript/tests/function_libs/torch_lib/ops_test_common.py:524: in _capture_graph_and_evaluate_torch_script_evaluator
raise AssertionError(
E AssertionError: ONNX model is invalid. Model:
E <
E ir_version: 8,
E opset_import: ["" : 18, "pkg.onnxscript.torch_lib.common" : 1],
E producer_name: "pytorch",
E producer_version: "2.2.0"
E >
E main_graph (int64 input_0, int64 input_1) => (float16[50] _val_16)
E <float _val_2, float _val_3, float _val_4, float _val_5, float _val_6, float _val_7, int64 _val_8, float _val_9, float[unk__0] _val_10, float _val_11, float _val_12, float _val_13, float _val_14, float[unk__0] _val_15>
E {
E _val_2 = Constant <value: tensor = float {0}> ()
E _val_3 = Cast <to: int = 1> (_val_2)
E _val_4 = Constant <value: tensor = float {1}> ()
E _val_5 = Cast <to: int = 1> (_val_4)
E _val_6 = Cast <to: int = 1> (input_0)
E _val_7 = Cast <to: int = 1> (input_1)
E _val_8 = Constant <value: tensor = int64 {50}> ()
E _val_9 = Cast <to: int = 1> (_val_8)
E _val_10 = Range (_val_3, _val_9, _val_5)
E _val_11 = CastLike (_val_6, _val_7)
E _val_12 = Sub (_val_7, _val_11)
E _val_13 = Sub (_val_9, _val_5)
E _val_14 = Div (_val_12, _val_13)
E _val_15 = Mul (_val_10, _val_14)
E _val_16 = Add (_val_15, _val_11)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E Rank (input) => (return_val)
E {
E tmp = Shape (input)
E return_val = Size (tmp)
E }
E <
E domain: "pkg.onnxscript.torch_lib.common",
E opset_import: ["" : 18]
E >
E IsScalar (input) => (return_val)
E {
E tmp = Shape (input)
E tmp_0 = Size (tmp)
E tmp_1 = Constant <value_int: int = 0> ()
E return_val = Equal (tmp_0, tmp_1)
E }
github-actions / Test Results
All 3 runs failed: test_output_match_opinfo__linspace_tensor_overload_cpu_int32 (onnxscript.tests.function_libs.torch_lib.ops_test.TestOutputConsistencyFullGraphCPU)
artifacts/Test Results (py310-torch-nightly-macos-latest)/pytest.xml [took 6s]
artifacts/Test Results (py310-torch-nightly-ubuntu-latest)/pytest.xml [took 10s]
artifacts/Test Results (py310-torch-nightly-windows-latest)/pytest.xml [took 2s]
Raw output
AssertionError: Tensor-likes are not equal!
Mismatched elements: 1 / 50 (2.0%)
Greatest absolute difference: 1 at index (49,)
Greatest relative difference: 0.3333333432674408 at index (49,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 1 / 50 (2.0%)
Greatest absolute difference: 1 at index (49,)
Greatest relative difference: 0.3333333432674408 at index (49,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 1 / 50 (2.0%)
Greatest absolute difference: 1 at index (49,)
Greatest relative difference: 0.3333333432674408 at index (49,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 2 at index (25,)
Greatest relative difference: inf at index (25,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 2 at index (25,)
Greatest relative difference: inf at index (25,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 2 at index (25,)
Greatest relative difference: inf at index (25,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 3 at index (49,)
Greatest relative difference: inf at index (17,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 3 at index (49,)
Greatest relative difference: inf at index (17,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 3 at index (49,)
Greatest relative difference: inf at index (17,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 6 at index (49,)
Greatest relative difference: inf at index (9,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 6 at index (49,)
Greatest relative difference: inf at index (9,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 6 at index (49,)
Greatest relative difference: inf at index (9,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 34 / 50 (68.0%)
Greatest absolute difference: 3 at index (49,)
Greatest relative difference: inf at index (1,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 34 / 50 (68.0%)
Greatest absolute difference: 3 at index (49,)
Greatest relative difference: inf at index (1,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 34 / 50 (68.0%)
Greatest absolute difference: 3 at index (49,)
Greatest relative difference: inf at index (1,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 33 / 50 (66.0%)
Greatest absolute difference: 3 at index (49,)
Greatest relative difference: 1.0 at index (17,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 33 / 50 (66.0%)
Greatest absolute difference: 3 at index (49,)
Greatest relative difference: 1.0 at index (17,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 33 / 50 (66.0%)
Greatest absolute difference: 3 at index (49,)
Greatest relative difference: 1.0 at index (17,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 1 / 50 (2.0%)
Greatest absolute difference: 1 at index (49,)
Greatest relative difference: 1.0 at index (49,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 1 / 50 (2.0%)
Greatest absolute difference: 1 at index (49,)
Greatest relative difference: 1.0 at index (49,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 1 / 50 (2.0%)
Greatest absolute difference: 1 at index (49,)
Greatest relative difference: 1.0 at index (49,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 37 / 50 (74.0%)
Greatest absolute difference: 4 at index (49,)
Greatest relative difference: 1.0 at index (13,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 37 / 50 (74.0%)
Greatest absolute difference: 4 at index (49,)
Greatest relative difference: 1.0 at index (13,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 37 / 50 (74.0%)
Greatest absolute difference: 4 at index (49,)
Greatest relative difference: 1.0 at index (13,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 1 / 50 (2.0%)
Greatest absolute difference: 1 at index (49,)
Greatest relative difference: 0.019999999552965164 at index (49,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 1 / 50 (2.0%)
Greatest absolute difference: 1 at index (49,)
Greatest relative difference: 0.019999999552965164 at index (49,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 1 / 50 (2.0%)
Greatest absolute difference: 1 at index (49,)
Greatest relative difference: 0.019999999552965164 at index (49,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 7 at index (49,)
Greatest relative difference: inf at index (22,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 7 at index (49,)
Greatest relative difference: inf at index (22,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 7 at index (49,)
Greatest relative difference: inf at index (22,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 4 at index (37,)
Greatest relative difference: inf at index (37,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 4 at index (37,)
Greatest relative difference: inf at index (37,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 4 at index (37,)
Greatest relative difference: inf at index (37,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 3 at index (33,)
Greatest relative difference: 3.0 at index (33,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 3 at index (33,)
Greatest relative difference: 3.0 at index (33,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 3 at index (33,)
Greatest relative difference: 3.0 at index (33,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 48 / 50 (96.0%)
Greatest absolute difference: 46 at index (49,)
Greatest relative difference: 0.9200000166893005 at index (49,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 48 / 50 (96.0%)
Greatest absolute difference: 46 at index (49,)
Greatest relative difference: 0.9200000166893005 at index (49,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 48 / 50 (96.0%)
Greatest absolute difference: 46 at index (49,)
Greatest relative difference: 0.9200000166893005 at index (49,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 4 at index (37,)
Greatest relative difference: inf at index (46,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 4 at index (37,)
Greatest relative difference: inf at index (46,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 4 at index (37,)
Greatest relative difference: inf at index (46,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 1 at index (1,)
Greatest relative difference: inf at index (49,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 1 at index (1,)
Greatest relative difference: inf at index (49,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 1 at index (1,)
Greatest relative difference: inf at index (49,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 46 at index (48,)
Greatest relative difference: 11.5 at index (48,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 46 at index (48,)
Greatest relative difference: 11.5 at index (48,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 49 / 50 (98.0%)
Greatest absolute difference: 46 at index (48,)
Greatest relative difference: 11.5 at index (48,)
AssertionError: Tensor-likes are not equal!
Mismatched elements: 43 / 50 (86.0%)
Greatest absolute difference: 7 at index (49,)
Greatest relative difference: 1.0 at index (7,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 1 / 50 (2.0%)
E Greatest absolute difference: 1 at index (49,)
E Greatest relative difference: 0.3333333432674408 at index (49,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 1 / 50 (2.0%)
E Greatest absolute difference: 1 at index (49,)
E Greatest relative difference: 0.3333333432674408 at index (49,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 1 / 50 (2.0%)
E Greatest absolute difference: 1 at index (49,)
E Greatest relative difference: 0.3333333432674408 at index (49,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 2 at index (25,)
E Greatest relative difference: inf at index (25,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 2 at index (25,)
E Greatest relative difference: inf at index (25,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 2 at index (25,)
E Greatest relative difference: inf at index (25,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 3 at index (49,)
E Greatest relative difference: inf at index (17,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 3 at index (49,)
E Greatest relative difference: inf at index (17,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 3 at index (49,)
E Greatest relative difference: inf at index (17,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 6 at index (49,)
E Greatest relative difference: inf at index (9,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 6 at index (49,)
E Greatest relative difference: inf at index (9,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 6 at index (49,)
E Greatest relative difference: inf at index (9,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 34 / 50 (68.0%)
E Greatest absolute difference: 3 at index (49,)
E Greatest relative difference: inf at index (1,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 34 / 50 (68.0%)
E Greatest absolute difference: 3 at index (49,)
E Greatest relative difference: inf at index (1,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 34 / 50 (68.0%)
E Greatest absolute difference: 3 at index (49,)
E Greatest relative difference: inf at index (1,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 33 / 50 (66.0%)
E Greatest absolute difference: 3 at index (49,)
E Greatest relative difference: 1.0 at index (17,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 33 / 50 (66.0%)
E Greatest absolute difference: 3 at index (49,)
E Greatest relative difference: 1.0 at index (17,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 33 / 50 (66.0%)
E Greatest absolute difference: 3 at index (49,)
E Greatest relative difference: 1.0 at index (17,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 1 / 50 (2.0%)
E Greatest absolute difference: 1 at index (49,)
E Greatest relative difference: 1.0 at index (49,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 1 / 50 (2.0%)
E Greatest absolute difference: 1 at index (49,)
E Greatest relative difference: 1.0 at index (49,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 1 / 50 (2.0%)
E Greatest absolute difference: 1 at index (49,)
E Greatest relative difference: 1.0 at index (49,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 37 / 50 (74.0%)
E Greatest absolute difference: 4 at index (49,)
E Greatest relative difference: 1.0 at index (13,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 37 / 50 (74.0%)
E Greatest absolute difference: 4 at index (49,)
E Greatest relative difference: 1.0 at index (13,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 37 / 50 (74.0%)
E Greatest absolute difference: 4 at index (49,)
E Greatest relative difference: 1.0 at index (13,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 1 / 50 (2.0%)
E Greatest absolute difference: 1 at index (49,)
E Greatest relative difference: 0.019999999552965164 at index (49,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 1 / 50 (2.0%)
E Greatest absolute difference: 1 at index (49,)
E Greatest relative difference: 0.019999999552965164 at index (49,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 1 / 50 (2.0%)
E Greatest absolute difference: 1 at index (49,)
E Greatest relative difference: 0.019999999552965164 at index (49,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 7 at index (49,)
E Greatest relative difference: inf at index (22,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 7 at index (49,)
E Greatest relative difference: inf at index (22,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 7 at index (49,)
E Greatest relative difference: inf at index (22,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 4 at index (37,)
E Greatest relative difference: inf at index (37,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 4 at index (37,)
E Greatest relative difference: inf at index (37,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 4 at index (37,)
E Greatest relative difference: inf at index (37,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 3 at index (33,)
E Greatest relative difference: 3.0 at index (33,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 3 at index (33,)
E Greatest relative difference: 3.0 at index (33,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 3 at index (33,)
E Greatest relative difference: 3.0 at index (33,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 48 / 50 (96.0%)
E Greatest absolute difference: 46 at index (49,)
E Greatest relative difference: 0.9200000166893005 at index (49,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 48 / 50 (96.0%)
E Greatest absolute difference: 46 at index (49,)
E Greatest relative difference: 0.9200000166893005 at index (49,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 48 / 50 (96.0%)
E Greatest absolute difference: 46 at index (49,)
E Greatest relative difference: 0.9200000166893005 at index (49,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 4 at index (37,)
E Greatest relative difference: inf at index (46,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 4 at index (37,)
E Greatest relative difference: inf at index (46,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 4 at index (37,)
E Greatest relative difference: inf at index (46,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 1 at index (1,)
E Greatest relative difference: inf at index (49,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 1 at index (1,)
E Greatest relative difference: inf at index (49,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 1 at index (1,)
E Greatest relative difference: inf at index (49,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 46 at index (48,)
E Greatest relative difference: 11.5 at index (48,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 46 at index (48,)
E Greatest relative difference: 11.5 at index (48,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 49 / 50 (98.0%)
E Greatest absolute difference: 46 at index (48,)
E Greatest relative difference: 11.5 at index (48,)
onnxscript/tests/function_libs/torch_lib/ops_test.py:267: in run_test_output_match
torch.testing.assert_close(
E AssertionError: Tensor-likes are not equal!
E
E Mismatched elements: 43 / 50 (86.0%)
E Greatest absolute difference: 7 at index (49,)
E Greatest relative difference: 1.0 at index (7,)