From 125391b3f8b8813e5ec35f4aa6fe7ab8b87e30f9 Mon Sep 17 00:00:00 2001 From: Changming Sun Date: Tue, 30 Jan 2024 09:42:55 -0800 Subject: [PATCH] update --- onnxruntime/test/providers/cpu/math/einsum_test.cc | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/onnxruntime/test/providers/cpu/math/einsum_test.cc b/onnxruntime/test/providers/cpu/math/einsum_test.cc index 2e7ae176f5cbc..ee367dca5e2eb 100644 --- a/onnxruntime/test/providers/cpu/math/einsum_test.cc +++ b/onnxruntime/test/providers/cpu/math/einsum_test.cc @@ -2074,7 +2074,10 @@ TEST(Einsum, EinsumTransposeMatMulTwoInputsTestSuite) { test.AddAttribute("equation", s); test.AddInput("x", {2, 2, 2}, m1); test.AddInput("y", {2, 2}, m2); - test.AddOutput("o", std::vector(tst.shape.begin(), tst.shape.end()), std::vector(tst.expected.begin(), tst.expected.end())); + + std::vector v1(tst.shape.begin(), tst.shape.end()); + std::vector v2(tst.expected.begin(), tst.expected.end()); + test.AddOutput("o", v1, v2); test.Run(); } } @@ -2098,7 +2101,9 @@ TEST_P(EinsumTransposeMatMulThreeInputsTest, EinsumTransposeMatMulThreeInputsTes test.AddInput("x", {2, 2, 2}, m1); test.AddInput("y", {2, 2}, m2); test.AddInput("z", {2, 2, 2}, m3); - test.AddOutput("o", std::vector(tst.shape.begin(), tst.shape.end()), std::vector(tst.expected.begin(), tst.expected.end())); + std::vector v1(tst.shape.begin(), tst.shape.end()); + std::vector v2(tst.expected.begin(), tst.expected.end()); + test.AddOutput("o", v1, v2); test.Run(); } }