[TemplateFuncTests] RGBX->RGB: Increase image size to avoid test failures on some platforms (#8762)

* Increase image size to avoid test failures on some platforms

There is an assert 'length >= nlanes' and 'nlanes' value depends on machine architecture
Set 320x320 test image to guarantee that image size >= nlanes

Also increased image size for 'plugin shared tests' to ensure the same (even though tests do not work with legacy preprocessing)

* Descreased to 160x160
This commit is contained in:
Mikhail Nosov 2021-11-23 15:26:22 +03:00 committed by GitHub
parent 5104bf8ce8
commit c29569ecbd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 5 deletions

View File

@ -108,8 +108,8 @@ TEST_F(ReferencePreprocessLegacyTest, resize) {
}
TEST_F(ReferencePreprocessLegacyTest, bgrx_to_bgr) {
const int h = 32;
const int w = 32;
const int h = 160;
const int w = 160;
auto rgbx_input = std::vector<uint8_t>(h * w * 4, 0);
for (auto i = 0; i < h * w * 4; i++) {
rgbx_input[i] = i % 256;
@ -138,8 +138,8 @@ TEST_F(ReferencePreprocessLegacyTest, bgrx_to_bgr) {
}
TEST_F(ReferencePreprocessLegacyTest, rgbx_to_bgr) {
const int h = 32;
const int w = 32;
const int h = 160;
const int w = 160;
auto rgbx_input = std::vector<uint8_t>(h * w * 4, 0);
for (auto i = 0; i < h * w * 4; i++) {
rgbx_input[i] = i % 256;

View File

@ -387,7 +387,7 @@ inline std::shared_ptr<Function> cvt_color_i420_to_bgr_three_planes() {
inline std::shared_ptr<Function> cvt_color_bgrx_to_bgr() {
using namespace ov::preprocess;
auto function = create_preprocess_2inputs(element::f32, PartialShape{1, 32, 32, 3});
auto function = create_preprocess_2inputs(element::f32, PartialShape{1, 160, 160, 3});
auto p = PrePostProcessor(function);
p.input(0).tensor().set_color_format(ColorFormat::BGRX);
p.input(0).preprocess().convert_color(ColorFormat::BGR);