diff --git a/src/plugins/intel_gpu/tests/functional/shared_tests_instances/single_layer_tests/adaptive_pooling.cpp b/src/plugins/intel_gpu/tests/functional/shared_tests_instances/single_layer_tests/adaptive_pooling.cpp index 86e13507e63e14..e6026e85469871 100644 --- a/src/plugins/intel_gpu/tests/functional/shared_tests_instances/single_layer_tests/adaptive_pooling.cpp +++ b/src/plugins/intel_gpu/tests/functional/shared_tests_instances/single_layer_tests/adaptive_pooling.cpp @@ -5,24 +5,21 @@ #include #include -#include "single_layer_tests/adaptive_pooling.hpp" +#include "single_op_tests/adaptive_pooling.hpp" #include "common_test_utils/test_constants.hpp" -using namespace ngraph::helpers; -using namespace LayerTestsDefinitions; -using namespace ngraph::element; - namespace { +using ov::test::AdaPoolLayerTest; const std::vector poolingModes = {"max", "avg"}; -const std::vector netPrecisions = { - InferenceEngine::Precision::FP32, - InferenceEngine::Precision::FP16, +const std::vector types = { + ov::element::f16, + ov::element::f32 }; -const std::vector> inputShapes1D = { - {1, 3, 5}, - {1, 1, 17}, +const std::vector> inputShapes1D = { + {{1, 3, 5}}, + {{1, 1, 17}}, }; const std::vector> outputShapes1D = { {2}, @@ -31,16 +28,16 @@ const std::vector> outputShapes1D = { INSTANTIATE_TEST_SUITE_P(smoke_AdaptivePooling1D, AdaPoolLayerTest, ::testing::Combine( - ::testing::ValuesIn(inputShapes1D), + ::testing::ValuesIn(ov::test::static_shapes_to_test_representation(inputShapes1D)), ::testing::ValuesIn(outputShapes1D), ::testing::ValuesIn(poolingModes), - ::testing::ValuesIn(netPrecisions), + ::testing::ValuesIn(types), ::testing::Values(ov::test::utils::DEVICE_GPU)), AdaPoolLayerTest::getTestCaseName); -const std::vector> inputShapes2D = { - {1, 3, 4, 6}, - {1, 1, 17, 5}, +const std::vector> inputShapes2D = { + {{1, 3, 4, 6}}, + {{1, 1, 17, 5}}, }; const std::vector> outputShapes2D = { {2, 4}, @@ -49,16 +46,16 @@ const std::vector> outputShapes2D = { INSTANTIATE_TEST_SUITE_P(smoke_AdaptivePooling2D, AdaPoolLayerTest, ::testing::Combine( - ::testing::ValuesIn(inputShapes2D), + ::testing::ValuesIn(ov::test::static_shapes_to_test_representation(inputShapes2D)), ::testing::ValuesIn(outputShapes2D), ::testing::ValuesIn(poolingModes), - ::testing::ValuesIn(netPrecisions), + ::testing::ValuesIn(types), ::testing::Values(ov::test::utils::DEVICE_GPU)), AdaPoolLayerTest::getTestCaseName); -const std::vector> inputShapes3D = { - {1, 1, 3, 3, 3}, - {1, 3, 5, 7, 11}, +const std::vector> inputShapes3D = { + {{1, 1, 3, 3, 3}}, + {{1, 3, 5, 7, 11}}, }; const std::vector> outputShapes3D = { {2, 2, 2}, @@ -67,10 +64,10 @@ const std::vector> outputShapes3D = { INSTANTIATE_TEST_SUITE_P(smoke_AdaptivePooling3D, AdaPoolLayerTest, ::testing::Combine( - ::testing::ValuesIn(inputShapes3D), + ::testing::ValuesIn(ov::test::static_shapes_to_test_representation(inputShapes3D)), ::testing::ValuesIn(outputShapes3D), ::testing::ValuesIn(poolingModes), - ::testing::ValuesIn(netPrecisions), + ::testing::ValuesIn(types), ::testing::Values(ov::test::utils::DEVICE_GPU)), AdaPoolLayerTest::getTestCaseName); diff --git a/src/plugins/intel_gpu/tests/functional/shared_tests_instances/single_layer_tests/batch_norm.cpp b/src/plugins/intel_gpu/tests/functional/shared_tests_instances/single_layer_tests/batch_norm.cpp index 0ef10601c3f1b8..da3cbe708b0628 100644 --- a/src/plugins/intel_gpu/tests/functional/shared_tests_instances/single_layer_tests/batch_norm.cpp +++ b/src/plugins/intel_gpu/tests/functional/shared_tests_instances/single_layer_tests/batch_norm.cpp @@ -4,14 +4,13 @@ #include -#include "single_layer_tests/batch_norm.hpp" - -using namespace LayerTestsDefinitions; +#include "single_op_tests/batch_norm.hpp" namespace { -const std::vector netPrecisions = { - InferenceEngine::Precision::FP32, - InferenceEngine::Precision::FP16 +using ov::test::BatchNormLayerTest; +const std::vector types = { + ov::element::f16, + ov::element::f32 }; const std::vector epsilon = { @@ -19,23 +18,19 @@ const std::vector epsilon = { 1e-5, 1e-4 }; -const std::vector> inputShapes = { - {1, 3}, - {2, 5}, - {1, 3, 10}, - {1, 3, 1, 1}, - {2, 5, 4, 4}, -}; +const std::vector> inputShapes = { + {{1, 3}}, + {{2, 5}}, + {{1, 3, 10}}, + {{1, 3, 1, 1}}, + {{2, 5, 4, 4}}, +}; const auto batchNormParams = testing::Combine( testing::ValuesIn(epsilon), - testing::ValuesIn(netPrecisions), - testing::Values(InferenceEngine::Precision::UNSPECIFIED), - testing::Values(InferenceEngine::Precision::UNSPECIFIED), - testing::Values(InferenceEngine::Layout::ANY), - testing::Values(InferenceEngine::Layout::ANY), - testing::ValuesIn(inputShapes), + testing::ValuesIn(types), + testing::ValuesIn(ov::test::static_shapes_to_test_representation(inputShapes)), testing::Values(ov::test::utils::DEVICE_GPU) ); diff --git a/src/plugins/intel_gpu/tests/functional/shared_tests_instances/single_layer_tests/batch_to_space.cpp b/src/plugins/intel_gpu/tests/functional/shared_tests_instances/single_layer_tests/batch_to_space.cpp index b35117443cf47f..e79d3b55551797 100644 --- a/src/plugins/intel_gpu/tests/functional/shared_tests_instances/single_layer_tests/batch_to_space.cpp +++ b/src/plugins/intel_gpu/tests/functional/shared_tests_instances/single_layer_tests/batch_to_space.cpp @@ -4,172 +4,125 @@ #include -#include "single_layer_tests/batch_to_space.hpp" +#include "single_op_tests/batch_to_space.hpp" #include "common_test_utils/test_constants.hpp" -using namespace LayerTestsDefinitions; - namespace { +using ov::test::BatchToSpaceLayerTest; +using ov::test::batchToSpaceParamsTuple; + auto bts_only_test_cases = []() { return std::vector{batchToSpaceParamsTuple({1, 2, 2}, {0, 0, 0}, {0, 0, 0}, - {4, 1, 1}, - InferenceEngine::Precision::FP32, - InferenceEngine::Precision::UNSPECIFIED, - InferenceEngine::Precision::UNSPECIFIED, - InferenceEngine::Layout::ANY, - InferenceEngine::Layout::ANY, + ov::test::static_shapes_to_test_representation(std::vector({ + {4, 1, 1}})), + ov::element::f32, ov::test::utils::DEVICE_GPU), batchToSpaceParamsTuple({1, 1, 2, 2}, {0, 0, 0, 0}, {0, 0, 0, 0}, - {4, 1, 1, 1}, - InferenceEngine::Precision::FP32, - InferenceEngine::Precision::UNSPECIFIED, - InferenceEngine::Precision::UNSPECIFIED, - InferenceEngine::Layout::ANY, - InferenceEngine::Layout::ANY, + ov::test::static_shapes_to_test_representation(std::vector({ + {4, 1, 1, 1}})), + ov::element::f32, ov::test::utils::DEVICE_GPU), batchToSpaceParamsTuple({1, 1, 2, 2}, {0, 0, 0, 0}, {0, 0, 0, 0}, - {4, 3, 1, 1}, - InferenceEngine::Precision::FP32, - InferenceEngine::Precision::UNSPECIFIED, - InferenceEngine::Precision::UNSPECIFIED, - InferenceEngine::Layout::ANY, - InferenceEngine::Layout::ANY, + ov::test::static_shapes_to_test_representation(std::vector({ + {4, 3, 1, 1}})), + ov::element::f32, ov::test::utils::DEVICE_GPU), batchToSpaceParamsTuple({1, 1, 2, 2}, {0, 0, 0, 0}, {0, 0, 0, 0}, - {4, 1, 2, 2}, - InferenceEngine::Precision::FP32, - InferenceEngine::Precision::UNSPECIFIED, - InferenceEngine::Precision::UNSPECIFIED, - InferenceEngine::Layout::ANY, - InferenceEngine::Layout::ANY, + ov::test::static_shapes_to_test_representation(std::vector({ + {4, 1, 2, 2}})), + ov::element::f32, ov::test::utils::DEVICE_GPU), batchToSpaceParamsTuple({1, 1, 2, 2}, {0, 0, 0, 0}, {0, 0, 0, 0}, - {8, 1, 1, 2}, - InferenceEngine::Precision::FP32, - InferenceEngine::Precision::UNSPECIFIED, - InferenceEngine::Precision::UNSPECIFIED, - InferenceEngine::Layout::ANY, - InferenceEngine::Layout::ANY, + ov::test::static_shapes_to_test_representation(std::vector({ + {8, 1, 1, 2}})), + ov::element::f32, ov::test::utils::DEVICE_GPU), batchToSpaceParamsTuple({1, 1, 3, 2, 2}, {0, 0, 1, 0, 3}, {0, 0, 2, 0, 0}, - {24, 1, 2, 1, 2}, - InferenceEngine::Precision::FP32, - InferenceEngine::Precision::UNSPECIFIED, - InferenceEngine::Precision::UNSPECIFIED, - InferenceEngine::Layout::ANY, - InferenceEngine::Layout::ANY, + ov::test::static_shapes_to_test_representation(std::vector({ + {24, 1, 2, 1, 2}})), + ov::element::f32, ov::test::utils::DEVICE_GPU), batchToSpaceParamsTuple({1, 1, 2, 2}, {0, 0, 0, 0}, {0, 0, 0, 0}, - {4, 1, 1, 1}, - InferenceEngine::Precision::I8, - InferenceEngine::Precision::UNSPECIFIED, - InferenceEngine::Precision::UNSPECIFIED, - InferenceEngine::Layout::ANY, - InferenceEngine::Layout::ANY, + ov::test::static_shapes_to_test_representation(std::vector({ + {4, 1, 1, 1}})), + ov::element::i8, ov::test::utils::DEVICE_GPU), batchToSpaceParamsTuple({1, 1, 2, 2}, {0, 0, 0, 0}, {0, 0, 0, 0}, - {4, 3, 1, 1}, - InferenceEngine::Precision::I8, - InferenceEngine::Precision::UNSPECIFIED, - InferenceEngine::Precision::UNSPECIFIED, - InferenceEngine::Layout::ANY, - InferenceEngine::Layout::ANY, + ov::test::static_shapes_to_test_representation(std::vector({ + {4, 3, 1, 1}})), + ov::element::i8, ov::test::utils::DEVICE_GPU), batchToSpaceParamsTuple({1, 1, 2, 2}, {0, 0, 0, 0}, {0, 0, 0, 0}, - {4, 1, 2, 2}, - InferenceEngine::Precision::I8, - InferenceEngine::Precision::UNSPECIFIED, - InferenceEngine::Precision::UNSPECIFIED, - InferenceEngine::Layout::ANY, - InferenceEngine::Layout::ANY, + ov::test::static_shapes_to_test_representation(std::vector({ + {4, 1, 2, 2}})), + ov::element::i8, ov::test::utils::DEVICE_GPU), batchToSpaceParamsTuple({1, 1, 2, 2}, {0, 0, 0, 0}, {0, 0, 0, 0}, - {8, 1, 1, 2}, - InferenceEngine::Precision::I8, - InferenceEngine::Precision::UNSPECIFIED, - InferenceEngine::Precision::UNSPECIFIED, - InferenceEngine::Layout::ANY, - InferenceEngine::Layout::ANY, + ov::test::static_shapes_to_test_representation(std::vector({ + {8, 1, 1, 2}})), + ov::element::i8, ov::test::utils::DEVICE_GPU), batchToSpaceParamsTuple({1, 1, 3, 2, 2}, {0, 0, 1, 0, 3}, {0, 0, 2, 0, 0}, - {24, 1, 2, 1, 2}, - InferenceEngine::Precision::I8, - InferenceEngine::Precision::UNSPECIFIED, - InferenceEngine::Precision::UNSPECIFIED, - InferenceEngine::Layout::ANY, - InferenceEngine::Layout::ANY, + ov::test::static_shapes_to_test_representation(std::vector({ + {24, 1, 2, 1, 2}})), + ov::element::i8, ov::test::utils::DEVICE_GPU), batchToSpaceParamsTuple({1, 1, 2, 2}, {0, 0, 0, 0}, {0, 0, 0, 0}, - {4, 1, 1, 1}, - InferenceEngine::Precision::U8, - InferenceEngine::Precision::UNSPECIFIED, - InferenceEngine::Precision::UNSPECIFIED, - InferenceEngine::Layout::ANY, - InferenceEngine::Layout::ANY, + ov::test::static_shapes_to_test_representation(std::vector({ + {4, 1, 1, 1}})), + ov::element::u8, ov::test::utils::DEVICE_GPU), batchToSpaceParamsTuple({1, 1, 2, 2}, {0, 0, 0, 0}, {0, 0, 0, 0}, - {4, 3, 1, 1}, - InferenceEngine::Precision::U8, - InferenceEngine::Precision::UNSPECIFIED, - InferenceEngine::Precision::UNSPECIFIED, - InferenceEngine::Layout::ANY, - InferenceEngine::Layout::ANY, + ov::test::static_shapes_to_test_representation(std::vector({ + {4, 3, 1, 1}})), + ov::element::u8, ov::test::utils::DEVICE_GPU), batchToSpaceParamsTuple({1, 1, 2, 2}, {0, 0, 0, 0}, {0, 0, 0, 0}, - {4, 1, 2, 2}, - InferenceEngine::Precision::U8, - InferenceEngine::Precision::UNSPECIFIED, - InferenceEngine::Precision::UNSPECIFIED, - InferenceEngine::Layout::ANY, - InferenceEngine::Layout::ANY, + ov::test::static_shapes_to_test_representation(std::vector({ + {4, 1, 2, 2}})), + ov::element::u8, ov::test::utils::DEVICE_GPU), batchToSpaceParamsTuple({1, 1, 2, 2}, {0, 0, 0, 0}, {0, 0, 0, 0}, - {8, 1, 1, 2}, - InferenceEngine::Precision::U8, - InferenceEngine::Precision::UNSPECIFIED, - InferenceEngine::Precision::UNSPECIFIED, - InferenceEngine::Layout::ANY, - InferenceEngine::Layout::ANY, + ov::test::static_shapes_to_test_representation(std::vector({ + {8, 1, 1, 2}})), + ov::element::u8, ov::test::utils::DEVICE_GPU), batchToSpaceParamsTuple({1, 1, 3, 2, 2}, {0, 0, 1, 0, 3}, {0, 0, 2, 0, 0}, - {24, 1, 2, 1, 2}, - InferenceEngine::Precision::U8, - InferenceEngine::Precision::UNSPECIFIED, - InferenceEngine::Precision::UNSPECIFIED, - InferenceEngine::Layout::ANY, - InferenceEngine::Layout::ANY, + ov::test::static_shapes_to_test_representation(std::vector({ + {24, 1, 2, 1, 2}})), + ov::element::u8, ov::test::utils::DEVICE_GPU)}; };