Skip to content

Commit

Permalink
[Tmpl test] Preprocess: Drop legacy comparison (#24622)
Browse files Browse the repository at this point in the history
### Details:
 - Fixed tensors' shapes.

### Tickets:
 - CVS-137216
  • Loading branch information
t-jankowski authored May 23, 2024
1 parent d0e6f8f commit 9ec1c4a
Showing 1 changed file with 9 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ class ReferencePreprocessTest : public testing::TestWithParam<RefPreprocessParam
public:
void SetUp() override {
SKIP_IF_CURRENT_TEST_IS_DISABLED()
legacy_compare = true;
const auto& params = GetParam();
function = params.function();
for (const auto& inp : params.inputs) {
Expand Down Expand Up @@ -869,7 +868,7 @@ static RefPreprocessParams convert_color_nv12_layout_resize() {
auto exp_out = std::vector<float> {255, 0, 0, 255, // R channel
0, 255, 0, 0, // G channel
0, 0, 255, 0}; // B channel
auto out_shape = Shape{1, 2, 2, 3};
auto out_shape = Shape{1, 3, 2, 2};
// clang-format on
res.inputs.emplace_back(element::u8, input_shape, input);
res.expected.emplace_back(out_shape, element::f32, exp_out);
Expand Down Expand Up @@ -1175,8 +1174,8 @@ static RefPreprocessParams post_convert_color_rgb_to_bgr() {
return f;
};

res.inputs.emplace_back(Shape{2, 3, 1, 1}, element::f32, std::vector<float>{1, 2, 3, 4, 5, 6});
res.expected.emplace_back(Shape{2, 3, 1, 1}, element::f32, std::vector<float>{3, 2, 1, 6, 5, 4});
res.inputs.emplace_back(Shape{2, 1, 1, 3}, element::f32, std::vector<float>{1, 2, 3, 4, 5, 6});
res.expected.emplace_back(Shape{2, 1, 1, 3}, element::f32, std::vector<float>{3, 2, 1, 6, 5, 4});
return res;
}

Expand All @@ -1191,8 +1190,8 @@ static RefPreprocessParams post_convert_color_bgr_to_rgb() {
return f;
};

res.inputs.emplace_back(Shape{2, 3, 1, 1}, element::f32, std::vector<float>{1, 2, 3, 4, 5, 6});
res.expected.emplace_back(Shape{2, 3, 1, 1}, element::f32, std::vector<float>{3, 2, 1, 6, 5, 4});
res.inputs.emplace_back(Shape{2, 1, 1, 3}, element::f32, std::vector<float>{1, 2, 3, 4, 5, 6});
res.expected.emplace_back(Shape{2, 1, 1, 3}, element::f32, std::vector<float>{3, 2, 1, 6, 5, 4});
return res;
}

Expand Down Expand Up @@ -1230,8 +1229,8 @@ static RefPreprocessParams rgb_to_bgr() {
return f;
};

res.inputs.emplace_back(Shape{2, 3, 1, 1}, element::f32, std::vector<float>{1, 2, 3, 4, 5, 6});
res.expected.emplace_back(Shape{2, 3, 1, 1}, element::f32, std::vector<float>{3, 2, 1, 6, 5, 4});
res.inputs.emplace_back(Shape{2, 1, 1, 3}, element::f32, std::vector<float>{1, 2, 3, 4, 5, 6});
res.expected.emplace_back(Shape{2, 1, 1, 3}, element::f32, std::vector<float>{3, 2, 1, 6, 5, 4});
return res;
}

Expand All @@ -1246,8 +1245,8 @@ static RefPreprocessParams bgr_to_rgb() {
return f;
};

res.inputs.emplace_back(Shape{2, 3, 1, 1}, element::f32, std::vector<float>{1, 2, 3, 4, 5, 6});
res.expected.emplace_back(Shape{2, 3, 1, 1}, element::f32, std::vector<float>{3, 2, 1, 6, 5, 4});
res.inputs.emplace_back(Shape{2, 1, 1, 3}, element::f32, std::vector<float>{1, 2, 3, 4, 5, 6});
res.expected.emplace_back(Shape{2, 1, 1, 3}, element::f32, std::vector<float>{3, 2, 1, 6, 5, 4});
return res;
}

Expand Down

0 comments on commit 9ec1c4a

Please sign in to comment.