[ONNX] Bump ORT version to 1.15.0 (#102248)

Pull Request resolved: https://github.com/pytorch/pytorch/pull/102248
Approved by: https://github.com/abock
This commit is contained in:
AllenTiTaiWang 2023-05-25 20:40:55 +00:00 committed by PyTorch MergeBot
parent 3c77310752
commit 053dff1111
4 changed files with 11 additions and 33 deletions

View File

@ -16,7 +16,7 @@ pip_install \
onnx==1.14.0
pip_install \
onnxruntime==1.14.0 \
onnxruntime==1.15.0 \
parameterized==0.8.1 \
pytest-cov==4.0.0 \
pytest-subtests==0.10.0 \

View File

@ -406,21 +406,6 @@ EXPECTED_SKIPS_OR_FAILS: Tuple[onnx_test_common.DecorateMeta, ...] = (
dtypes=(torch.uint8, torch.int8, torch.int16,),
reason=onnx_test_common.reason_onnx_script_does_not_support("Add", "int8, int16"),
),
xfail(
"new_full",
dtypes=onnx_test_common.BOOL_TYPES + onnx_test_common.INT_TYPES + onnx_test_common.FLOAT_TYPES,
reason=onnx_test_common.reason_onnx_runtime_does_not_support("new_full", "ORT 1.15 will support"),
),
xfail(
"new_ones",
dtypes=onnx_test_common.BOOL_TYPES + onnx_test_common.INT_TYPES + onnx_test_common.FLOAT_TYPES,
reason=onnx_test_common.reason_onnx_runtime_does_not_support("new_ones", "ORT 1.15 will support"),
),
xfail(
"new_zeros",
dtypes=onnx_test_common.BOOL_TYPES + onnx_test_common.INT_TYPES + onnx_test_common.FLOAT_TYPES,
reason=onnx_test_common.reason_onnx_runtime_does_not_support("new_zeros", "ORT 1.15 will support"),
),
xfail(
"nn.functional.adaptive_avg_pool1d",
reason=onnx_test_common.reason_onnx_script_does_not_support("aten.mean.dim"),

View File

@ -100,6 +100,8 @@ EXPECTED_SKIPS_OR_FAILS: Tuple[onnx_test_common.DecorateMeta, ...] = (
skip("nn.functional.scaled_dot_product_attention", reason="fixme: ORT crashes on Windows, segfaults randomly on Linux"),
skip("sqrt", dtypes=onnx_test_common.BOOL_TYPES, reason=onnx_test_common.reason_onnx_does_not_support("Sqrt")),
skip("stft", opsets=[onnx_test_common.opsets_before(17)], reason=onnx_test_common.reason_onnx_does_not_support("STFT")),
xfail("stft",
reason=onnx_test_common.reason_onnx_runtime_does_not_support("STFT", "Regression on ORT=1.15 4 percent difference")),
skip("tile", opsets=[onnx_test_common.opsets_before(13)], reason=onnx_test_common.reason_onnx_does_not_support("Tile")),
xfail("unflatten", opsets=[onnx_test_common.opsets_before(13)], reason="Helper function is needed to support legacy ops."),
)

View File

@ -650,15 +650,7 @@ class TestONNXRuntime(onnx_test_common._TestONNXRuntime):
self.run_test(model, (x, y, z), input_names=("x", "y", "z"))
self.run_test(model, (x,), {"y": y, "z": z}, input_names=("x", "y", "z"))
# Requires input_names to be set so that we can feed the inputs properly into ORT.
# TODO: Export default values as ONNX initializers, then this should not raise.
# https://msdata.visualstudio.com/Vienna/_workitems/edit/969268
# Default values are accessible via FunctionSchema.
with self.assertRaisesRegex(
ValueError, "Model requires 3 inputs. Input Feed contains 2"
):
self.run_test(model, (x,), {"y": y}, input_names=("x", "y"))
self.run_test(model, (x,), {"y": y}, input_names=("x", "y"))
for example_inputs, example_kwargs in (
((x, y, None), {}),
@ -742,14 +734,13 @@ class TestONNXRuntime(onnx_test_common._TestONNXRuntime):
y = torch.randn(2, 3)
model = torch.jit.script(Model())
# TODO: Export default values as ONNX initializers, then this should not raise.
# https://msdata.visualstudio.com/Vienna/_workitems/edit/969268
# Default values are accessible via FunctionSchema.
with self.assertRaisesRegex(
ValueError, "Model requires 2 inputs. Input Feed contains 1"
):
self.run_test(model, (x,))
self.run_test(model, (), {"y": y})
# Optional supports None inputs
self.run_test(model, (x,))
# NOTE: default value is not supported on ONNX, so torch and ONNX has
# different behavior
with self.assertRaisesRegex(AssertionError, "Tensor-likes are not close!"):
self.run_test(model, (), {"y": y}, input_names=["y"])
self.run_test(model, (x, y))
self.run_test(model, (), {"x": x, "y": y}, input_names=("x", "y"))