Skip to content

Commit

Permalink
change parse_onnx to optimize_onnx
Browse files Browse the repository at this point in the history
  • Loading branch information
ahsan-ca committed Jun 3, 2024
1 parent c35fb00 commit 83e9726
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 5 deletions.
2 changes: 1 addition & 1 deletion test/onnx/parse/binary_dyn_brcst_mul_fp8_test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ TEST_CASE(binary_dyn_brcst_mul_fp8_test)

migraphx::onnx_options options;
options.default_dyn_dim_value = {1, 4};
auto prog = migraphx::parse_onnx("binary_dyn_brcst_mul_fp8_test.onnx", options);
auto prog = read_onnx("binary_dyn_brcst_mul_fp8_test.onnx", options);

EXPECT(p == prog);
}
1 change: 1 addition & 0 deletions test/onnx/parse/gemm_fp8_test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ TEST_CASE(gemm_fp8_test)
auto l0 = mm->add_parameter("A", migraphx::shape{migraphx::shape::fp8e4m3fnuz_type, {8, 6}});
auto l1 = mm->add_parameter("B", migraphx::shape{migraphx::shape::fp8e4m3fnuz_type, {8, 7}});
auto l2 = mm->add_parameter("C", migraphx::shape{migraphx::shape::fp8e4m3fnuz_type, {6, 1}});

auto alpha = 0.5f;
auto beta = 0.8f;
auto a_l = mm->add_literal(alpha);
Expand Down
2 changes: 1 addition & 1 deletion test/onnx/verify/add_fp8_test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@

TEST_CASE(add_fp8_test)
{
auto p = migraphx::parse_onnx("add_fp8_test.onnx");
auto p = optimize_onnx("add_fp8_test.onnx");
p.compile(migraphx::make_target("ref"));

migraphx::shape s{migraphx::shape::fp8e4m3fnuz_type, {1}};
Expand Down
2 changes: 1 addition & 1 deletion test/onnx/verify/gemm_fp8_test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@

TEST_CASE(gemm_fp8_test)
{
migraphx::program p = migraphx::parse_onnx("gemm_fp8_test.onnx");
migraphx::program p = optimize_onnx("gemm_fp8_test.onnx");
p.compile(migraphx::make_target("ref"));

migraphx::shape a_shape{migraphx::shape::fp8e4m3fnuz_type, {8, 6}};
Expand Down
2 changes: 1 addition & 1 deletion test/onnx/verify/shrink_fp8_test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@

TEST_CASE(shrink_fp8_test)
{
migraphx::program p = migraphx::parse_onnx("shrink_fp8_test.onnx");
migraphx::program p = optimize_onnx("shrink_fp8_test.onnx");
p.compile(migraphx::make_target("ref"));

migraphx::shape s{migraphx::shape::fp8e4m3fnuz_type, {3, 3}};
Expand Down
2 changes: 1 addition & 1 deletion test/onnx/verify/size_fp8_test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@

TEST_CASE(size_fp8_test)
{
migraphx::program p = migraphx::parse_onnx("size_fp8_test.onnx");
migraphx::program p = optimize_onnx("size_fp8_test.onnx");
p.compile(migraphx::make_target("ref"));

migraphx::shape s{migraphx::shape::fp8e4m3fnuz_type, {2, 5, 3}};
Expand Down

0 comments on commit 83e9726

Please sign in to comment.