diff --git a/docs/IE_PLUGIN_DG/Plugin.md b/docs/IE_PLUGIN_DG/Plugin.md index 124852d6cf6..10876fcb30b 100644 --- a/docs/IE_PLUGIN_DG/Plugin.md +++ b/docs/IE_PLUGIN_DG/Plugin.md @@ -43,6 +43,7 @@ As an example, a plugin configuration has three value parameters: - `streams_executor_config` - configuration of `ov::threading::IStreamsExecutor` to handle settings of multi-threaded context. - `performance_mode` - configuration of `ov::hint::PerformanceMode` to set the performance mode. - `disable_transformations` - allows to disable transformations which are applied in the process of model compilation. +- `exclusive_async_requests` - allows to use exclusive task executor for asynchronous infer requests. ### Plugin Constructor diff --git a/src/inference/dev_api/cpp_interfaces/interface/ie_internal_plugin_config.hpp b/src/inference/dev_api/cpp_interfaces/interface/ie_internal_plugin_config.hpp index f3d67bd98cf..f7e50602372 100644 --- a/src/inference/dev_api/cpp_interfaces/interface/ie_internal_plugin_config.hpp +++ b/src/inference/dev_api/cpp_interfaces/interface/ie_internal_plugin_config.hpp @@ -10,7 +10,7 @@ #pragma once #include "ie_plugin_config.hpp" -#include "openvino/runtime/properties.hpp" +#include "openvino/runtime/internal_properties.hpp" namespace InferenceEngine { @@ -120,14 +120,3 @@ DECLARE_CONFIG_VALUE(DISABLE); } // namespace PluginConfigInternalParams } // namespace InferenceEngine - -namespace ov { - -/** - * @brief Read-only property to get a std::vector of properties - * which should affect the hash calculation for model cache - * @ingroup ie_dev_api_plugin_api - */ -static constexpr Property, PropertyMutability::RO> caching_properties{"CACHING_PROPERTIES"}; - -} // namespace ov diff --git a/src/inference/dev_api/openvino/runtime/internal_properties.hpp b/src/inference/dev_api/openvino/runtime/internal_properties.hpp new file mode 100644 index 00000000000..c4b8507ed28 --- /dev/null +++ b/src/inference/dev_api/openvino/runtime/internal_properties.hpp @@ -0,0 +1,29 @@ +// Copyright (C) 2018-2023 Intel Corporation +// SPDX-License-Identifier: Apache-2.0 +// + +/** + * @brief A header for internal properties that are passed from one plugin to another + * @file openvino/runtime/internal_properties.hpp + */ + +#pragma once + +#include "openvino/runtime/properties.hpp" + +namespace ov { + +/** + * @brief Read-only property to get a std::vector of properties + * which should affect the hash calculation for model cache + * @ingroup ov_dev_api_plugin_api + */ +static constexpr Property, PropertyMutability::RO> caching_properties{"CACHING_PROPERTIES"}; + +/** + * @brief Allow to create exclusive_async_requests with one executor + * @ingroup ov_dev_api_plugin_api + */ +static constexpr Property exclusive_async_requests{"EXCLUSIVE_ASYNC_REQUESTS"}; + +} // namespace ov diff --git a/src/inference/dev_api/openvino/runtime/iplugin.hpp b/src/inference/dev_api/openvino/runtime/iplugin.hpp index a64073b3ebe..7246e1a00b4 100644 --- a/src/inference/dev_api/openvino/runtime/iplugin.hpp +++ b/src/inference/dev_api/openvino/runtime/iplugin.hpp @@ -42,6 +42,9 @@ namespace ov { * @defgroup ov_dev_api_compiled_model_api Compiled Model base classes * @brief A set of base and helper classes to implement an compiled model class * + * @defgroup ov_dev_api_infer_request_api Inference Request common classes + * @brief A set of base and helper classes to implement a common inference request functionality. + * * @defgroup ov_dev_api_sync_infer_request_api Inference Request base classes * @brief A set of base and helper classes to implement a syncrhonous inference request class. * diff --git a/src/plugins/auto/src/plugin_config.cpp b/src/plugins/auto/src/plugin_config.cpp index 09a8a99574d..70870c57ba7 100644 --- a/src/plugins/auto/src/plugin_config.cpp +++ b/src/plugins/auto/src/plugin_config.cpp @@ -110,4 +110,4 @@ ov::AnyMap PluginConfig::get_full_properties() { return full_properties; } -} // namespace MultiDevicePlugin \ No newline at end of file +} // namespace MultiDevicePlugin diff --git a/src/plugins/template/backend/int_executable.cpp b/src/plugins/template/backend/int_executable.cpp index db8c4f9a18b..c310f508b2b 100644 --- a/src/plugins/template/backend/int_executable.cpp +++ b/src/plugins/template/backend/int_executable.cpp @@ -16,8 +16,6 @@ #include "perf_counter.hpp" #include "tensor_conversion_util.hpp" -NGRAPH_SUPPRESS_DEPRECATED_START - namespace { class DynamicTensor : public ngraph::runtime::HostTensor { @@ -47,7 +45,6 @@ protected: }; inline ngraph::HostTensorPtr make_tmp_host_tensor(const ov::Tensor& t) { - OPENVINO_SUPPRESS_DEPRECATED_START if (!t) { return std::make_shared(ov::element::dynamic); } else if (t.get_shape() == ov::Shape{0, std::numeric_limits::max()}) { @@ -55,7 +52,6 @@ inline ngraph::HostTensorPtr make_tmp_host_tensor(const ov::Tensor& t) { } else { return std::make_shared(t.get_element_type(), t.get_shape(), t.data()); } - OPENVINO_SUPPRESS_DEPRECATED_END } inline ngraph::HostTensorVector create_tmp_tensors(const ov::TensorVector& tensors) { ngraph::HostTensorVector result; @@ -126,10 +122,7 @@ bool ov::runtime::interpreter::INTExecutable::call(std::vector& outp auto variable = var_extension->get_variable(); if (!variable_context.get_variable_value(variable)) { auto h_tensor = ov::Tensor(op->get_input_element_type(0), op->get_input_shape(0)); - // h_tensor->write(h_tensor->get_data_ptr(), h_tensor->get_size_in_bytes()); - const auto tensor_input = make_tmp_host_tensor(h_tensor); - variable_context.set_variable_value(variable, - std::make_shared(tensor_input)); + variable_context.set_variable_value(variable, std::make_shared(h_tensor)); } } } diff --git a/src/plugins/template/src/config.cpp b/src/plugins/template/src/config.cpp index 2e2075d39bd..f4e565c6704 100644 --- a/src/plugins/template/src/config.cpp +++ b/src/plugins/template/src/config.cpp @@ -7,6 +7,7 @@ #include #include +#include "openvino/runtime/internal_properties.hpp" #include "openvino/runtime/properties.hpp" #include "template/properties.hpp" @@ -25,14 +26,16 @@ Configuration::Configuration(const ov::AnyMap& config, const Configuration& defa if (ov::template_plugin::disable_transformations == key) { disable_transformations = value.as(); + } else if (ov::exclusive_async_requests == key) { + exclusive_async_requests = value.as(); } else if (streamExecutorConfigKeys.end() != std::find(std::begin(streamExecutorConfigKeys), std::end(streamExecutorConfigKeys), key)) { streams_executor_config.set_property(key, value); - } else if (ov::device::id.name() == key) { + } else if (ov::device::id == key) { device_id = std::stoi(value.as()); OPENVINO_ASSERT(device_id <= 0, "Device ID ", device_id, " is not supported"); - } else if (CONFIG_KEY(PERF_COUNT) == key) { - perf_count = (CONFIG_VALUE(YES) == value.as()); + } else if (ov::enable_profiling == key) { + perf_count = value.as(); } else if (ov::hint::performance_mode == key) { std::stringstream strm{value.as()}; strm >> performance_mode; @@ -48,10 +51,12 @@ ov::Any Configuration::Get(const std::string& name) const { if ((streamExecutorConfigKeys.end() != std::find(std::begin(streamExecutorConfigKeys), std::end(streamExecutorConfigKeys), name))) { return streams_executor_config.get_property(name); - } else if (name == CONFIG_KEY(DEVICE_ID)) { + } else if (name == ov::device::id) { return {std::to_string(device_id)}; - } else if (name == CONFIG_KEY(PERF_COUNT)) { + } else if (name == ov::enable_profiling) { return {perf_count}; + } else if (name == ov::exclusive_async_requests) { + return {exclusive_async_requests}; } else if (name == ov::template_plugin::disable_transformations) { return {disable_transformations}; } else if (name == ov::num_streams) { diff --git a/src/plugins/template/src/config.hpp b/src/plugins/template/src/config.hpp index 15478074906..e2fb945e977 100644 --- a/src/plugins/template/src/config.hpp +++ b/src/plugins/template/src/config.hpp @@ -35,6 +35,7 @@ struct Configuration { ov::threading::IStreamsExecutor::Config streams_executor_config; ov::hint::PerformanceMode performance_mode = ov::hint::PerformanceMode::LATENCY; bool disable_transformations = false; + bool exclusive_async_requests = false; }; // ! [configuration:header] diff --git a/src/plugins/template/src/plugin.cpp b/src/plugins/template/src/plugin.cpp index 1f607b48dce..9f4edbadf39 100644 --- a/src/plugins/template/src/plugin.cpp +++ b/src/plugins/template/src/plugin.cpp @@ -6,11 +6,11 @@ #include -#include "cpp_interfaces/interface/ie_internal_plugin_config.hpp" #include "cpp_interfaces/interface/ie_iplugin_internal.hpp" #include "ie_plugin_config.hpp" #include "itt.hpp" #include "openvino/pass/manager.hpp" +#include "openvino/runtime/internal_properties.hpp" #include "openvino/runtime/properties.hpp" #include "remote_context.hpp" #include "template/properties.hpp" @@ -23,6 +23,7 @@ namespace { static constexpr const char* wait_executor_name = "TemplateWaitExecutor"; static constexpr const char* stream_executor_name = "TemplateStreamsExecutor"; +static constexpr const char* template_exclusive_executor = "TemplateExecutor"; } // namespace // ! [plugin:ctor] @@ -43,8 +44,6 @@ ov::template_plugin::Plugin::~Plugin() { // Plugin should remove executors from executor cache to avoid threads number growth in the whole application get_executor_manager()->clear(stream_executor_name); get_executor_manager()->clear(wait_executor_name); - // NOTE: Uncomment this if Inference Engine Executor cache is used to create callback executor - // executorManager()->clear("TemplateCallbackExecutor"); } // ! [plugin:dtor] @@ -106,12 +105,14 @@ std::shared_ptr ov::template_plugin::Plugin::compile_model( auto streamsExecutorConfig = ov::threading::IStreamsExecutor::Config::make_default_multi_threaded(fullConfig.streams_executor_config); streamsExecutorConfig._name = stream_executor_name; - auto compiled_model = - std::make_shared(model->clone(), - shared_from_this(), - context, - get_executor_manager()->get_idle_cpu_streams_executor(streamsExecutorConfig), - fullConfig); + auto compiled_model = std::make_shared( + model->clone(), + shared_from_this(), + context, + fullConfig.exclusive_async_requests + ? get_executor_manager()->get_executor(template_exclusive_executor) + : get_executor_manager()->get_idle_cpu_streams_executor(streamsExecutorConfig), + fullConfig); return compiled_model; } // ! [plugin:compile_model_with_remote] @@ -233,6 +234,7 @@ ov::Any ov::template_plugin::Plugin::get_property(const std::string& name, const std::vector rw_properties{ov::device::id, ov::enable_profiling, ov::hint::performance_mode, + ov::exclusive_async_requests, ov::template_plugin::disable_transformations}; return rw_properties; }; diff --git a/src/plugins/template/tests/functional/shared_tests_instances/behavior/ov_executable_network/get_metric.cpp b/src/plugins/template/tests/functional/shared_tests_instances/behavior/ov_executable_network/get_metric.cpp index e50b1b62efa..d39063b5a40 100644 --- a/src/plugins/template/tests/functional/shared_tests_instances/behavior/ov_executable_network/get_metric.cpp +++ b/src/plugins/template/tests/functional/shared_tests_instances/behavior/ov_executable_network/get_metric.cpp @@ -3,6 +3,7 @@ // #include "behavior/ov_executable_network/get_metric.hpp" + #include "behavior/ov_plugin/properties_tests.hpp" #include "openvino/runtime/core.hpp" @@ -15,11 +16,9 @@ namespace { // IE Class Common tests with // - - -INSTANTIATE_TEST_SUITE_P( - smoke_OVClassImportExportTestP, OVClassExecutableNetworkImportExportTestP, - ::testing::Values("HETERO:TEMPLATE")); +INSTANTIATE_TEST_SUITE_P(smoke_OVClassImportExportTestP, + OVClassExecutableNetworkImportExportTestP, + ::testing::Values("HETERO:TEMPLATE")); // // Executable Network GetMetric @@ -27,39 +26,37 @@ INSTANTIATE_TEST_SUITE_P( std::vector devices = {"TEMPLATE", "MULTI:TEMPLATE", "HETERO:TEMPLATE", "AUTO:TEMPLATE"}; -INSTANTIATE_TEST_SUITE_P( - smoke_OVClassExecutableNetworkGetMetricTest, OVClassExecutableNetworkGetMetricTest_SUPPORTED_CONFIG_KEYS, - ::testing::ValuesIn(devices)); +INSTANTIATE_TEST_SUITE_P(smoke_OVClassExecutableNetworkGetMetricTest, + OVClassExecutableNetworkGetMetricTest_SUPPORTED_CONFIG_KEYS, + ::testing::ValuesIn(devices)); -INSTANTIATE_TEST_SUITE_P( - smoke_OVClassExecutableNetworkGetMetricTest, OVClassExecutableNetworkGetMetricTest_SUPPORTED_METRICS, - ::testing::ValuesIn(devices)); +INSTANTIATE_TEST_SUITE_P(smoke_OVClassExecutableNetworkGetMetricTest, + OVClassExecutableNetworkGetMetricTest_SUPPORTED_METRICS, + ::testing::ValuesIn(devices)); -INSTANTIATE_TEST_SUITE_P( - smoke_OVClassExecutableNetworkGetMetricTest, OVClassExecutableNetworkGetMetricTest_NETWORK_NAME, - ::testing::ValuesIn(devices)); +INSTANTIATE_TEST_SUITE_P(smoke_OVClassExecutableNetworkGetMetricTest, + OVClassExecutableNetworkGetMetricTest_NETWORK_NAME, + ::testing::ValuesIn(devices)); -INSTANTIATE_TEST_SUITE_P( - smoke_OVClassExecutableNetworkGetMetricTest, OVClassExecutableNetworkGetMetricTest_OPTIMAL_NUMBER_OF_INFER_REQUESTS, - ::testing::ValuesIn(devices)); +INSTANTIATE_TEST_SUITE_P(smoke_OVClassExecutableNetworkGetMetricTest, + OVClassExecutableNetworkGetMetricTest_OPTIMAL_NUMBER_OF_INFER_REQUESTS, + ::testing::ValuesIn(devices)); -INSTANTIATE_TEST_SUITE_P( - smoke_OVClassExecutableNetworkGetMetricTest, OVClassExecutableNetworkGetMetricTest_ThrowsUnsupported, - ::testing::ValuesIn(devices)); +INSTANTIATE_TEST_SUITE_P(smoke_OVClassExecutableNetworkGetMetricTest, + OVClassExecutableNetworkGetMetricTest_ThrowsUnsupported, + ::testing::ValuesIn(devices)); -const std::vector multiModelPriorityConfigs = { - {ov::hint::model_priority(ov::hint::Priority::HIGH)}, - {ov::hint::model_priority(ov::hint::Priority::MEDIUM)}, - {ov::hint::model_priority(ov::hint::Priority::LOW)}, - {ov::hint::model_priority(ov::hint::Priority::DEFAULT)}}; +const std::vector multiModelPriorityConfigs = {{ov::hint::model_priority(ov::hint::Priority::HIGH)}, + {ov::hint::model_priority(ov::hint::Priority::MEDIUM)}, + {ov::hint::model_priority(ov::hint::Priority::LOW)}, + {ov::hint::model_priority(ov::hint::Priority::DEFAULT)}}; INSTANTIATE_TEST_SUITE_P(smoke_OVClassExecutableNetworkGetMetricTest, OVClassExecutableNetworkGetMetricTest_MODEL_PRIORITY, ::testing::Combine(::testing::Values("AUTO:TEMPLATE"), - ::testing::ValuesIn(multiModelPriorityConfigs))); + ::testing::ValuesIn(multiModelPriorityConfigs))); -const std::vector multiDevicePriorityConfigs = { - {ov::device::priorities(CommonTestUtils::DEVICE_TEMPLATE)}}; +const std::vector multiDevicePriorityConfigs = {{ov::device::priorities(CommonTestUtils::DEVICE_TEMPLATE)}}; INSTANTIATE_TEST_SUITE_P(smoke_OVClassExecutableNetworkGetMetricTest, OVClassExecutableNetworkGetMetricTest_DEVICE_PRIORITY, @@ -71,37 +68,29 @@ INSTANTIATE_TEST_SUITE_P(smoke_OVClassExecutableNetworkGetMetricTest, // Executable Network GetConfig / SetConfig // -INSTANTIATE_TEST_SUITE_P( - smoke_OVClassExecutableNetworkGetConfigTest, OVClassExecutableNetworkGetConfigTest, - ::testing::Values(CommonTestUtils::DEVICE_TEMPLATE)); +INSTANTIATE_TEST_SUITE_P(smoke_OVClassExecutableNetworkGetConfigTest, + OVClassExecutableNetworkGetConfigTest, + ::testing::Values(CommonTestUtils::DEVICE_TEMPLATE)); -INSTANTIATE_TEST_SUITE_P( - smoke_OVClassExecutableNetworkSetConfigTest, OVClassExecutableNetworkSetConfigTest, - ::testing::Values(CommonTestUtils::DEVICE_TEMPLATE)); +INSTANTIATE_TEST_SUITE_P(smoke_OVClassExecutableNetworkSetConfigTest, + OVClassExecutableNetworkSetConfigTest, + ::testing::Values(CommonTestUtils::DEVICE_TEMPLATE)); //// //// Hetero Executable Network GetMetric //// // -INSTANTIATE_TEST_SUITE_P( - smoke_OVClassHeteroExecutableNetworkGetMetricTest, OVClassHeteroExecutableNetworkGetMetricTest_SUPPORTED_CONFIG_KEYS, - ::testing::Values(CommonTestUtils::DEVICE_TEMPLATE)); +INSTANTIATE_TEST_SUITE_P(smoke_OVClassHeteroExecutableNetworkGetMetricTest, + OVClassHeteroExecutableNetworkGetMetricTest_NETWORK_NAME, + ::testing::Values(CommonTestUtils::DEVICE_TEMPLATE)); -INSTANTIATE_TEST_SUITE_P( - smoke_OVClassHeteroExecutableNetworkGetMetricTest, OVClassHeteroExecutableNetworkGetMetricTest_SUPPORTED_METRICS, - ::testing::Values(CommonTestUtils::DEVICE_TEMPLATE)); - -INSTANTIATE_TEST_SUITE_P( - smoke_OVClassHeteroExecutableNetworkGetMetricTest, OVClassHeteroExecutableNetworkGetMetricTest_NETWORK_NAME, - ::testing::Values(CommonTestUtils::DEVICE_TEMPLATE)); - -INSTANTIATE_TEST_SUITE_P( - smoke_OVClassHeteroExecutableNetworkGetMetricTest, OVClassHeteroExecutableNetworkGetMetricTest_TARGET_FALLBACK, - ::testing::Values(CommonTestUtils::DEVICE_TEMPLATE)); -INSTANTIATE_TEST_SUITE_P( - smoke_OVClassHeteroExecutableNetworkGetMetricTest, OVClassHeteroExecutableNetworkGetMetricTest_EXEC_DEVICES, - ::testing::Values("TEMPLATE.0")); +INSTANTIATE_TEST_SUITE_P(smoke_OVClassHeteroExecutableNetworkGetMetricTest, + OVClassHeteroExecutableNetworkGetMetricTest_TARGET_FALLBACK, + ::testing::Values(CommonTestUtils::DEVICE_TEMPLATE)); +INSTANTIATE_TEST_SUITE_P(smoke_OVClassHeteroExecutableNetworkGetMetricTest, + OVClassHeteroExecutableNetworkGetMetricTest_EXEC_DEVICES, + ::testing::Values("TEMPLATE.0")); ////////////////////////////////////////////////////////////////////////////////////////// -} // namespace +} // namespace diff --git a/src/plugins/template/tests/functional/shared_tests_instances/behavior/ov_plugin/properties_tests.cpp b/src/plugins/template/tests/functional/shared_tests_instances/behavior/ov_plugin/properties_tests.cpp index 4daca610407..b9af3a0598f 100644 --- a/src/plugins/template/tests/functional/shared_tests_instances/behavior/ov_plugin/properties_tests.cpp +++ b/src/plugins/template/tests/functional/shared_tests_instances/behavior/ov_plugin/properties_tests.cpp @@ -3,6 +3,7 @@ // #include "behavior/ov_plugin/properties_tests.hpp" + #include "openvino/runtime/properties.hpp" using namespace ov::test::behavior; @@ -10,148 +11,142 @@ using namespace ov::test::behavior; namespace { const std::vector inproperties = { - {ov::device::id("UNSUPPORTED_DEVICE_ID_STRING")}, + {ov::device::id("UNSUPPORTED_DEVICE_ID_STRING")}, }; const std::vector hetero_inproperties = { - {ov::device::id("UNSUPPORTED_DEVICE_ID_STRING")}, + {ov::device::id("UNSUPPORTED_DEVICE_ID_STRING")}, }; const std::vector multi_inproperties = { - {ov::device::id("UNSUPPORTED_DEVICE_ID_STRING")}, + {ov::device::id("UNSUPPORTED_DEVICE_ID_STRING")}, }; - const std::vector auto_inproperties = { - {ov::device::id("UNSUPPORTED_DEVICE_ID_STRING")}, + {ov::device::id("UNSUPPORTED_DEVICE_ID_STRING")}, }; - const std::vector auto_batch_inproperties = { - {ov::device::id("UNSUPPORTED_DEVICE_ID_STRING")}, + {ov::device::id("UNSUPPORTED_DEVICE_ID_STRING")}, }; -INSTANTIATE_TEST_SUITE_P(DISABLED_smoke_BehaviorTests, OVPropertiesIncorrectTests, - ::testing::Combine( - ::testing::Values(CommonTestUtils::DEVICE_TEMPLATE), - ::testing::ValuesIn(inproperties)), - OVPropertiesIncorrectTests::getTestCaseName); +INSTANTIATE_TEST_SUITE_P(smoke_BehaviorTests, + OVPropertiesIncorrectTests, + ::testing::Combine(::testing::Values(CommonTestUtils::DEVICE_TEMPLATE), + ::testing::ValuesIn(inproperties)), + OVPropertiesIncorrectTests::getTestCaseName); -INSTANTIATE_TEST_SUITE_P(DISABLED_smoke_Hetero_BehaviorTests, OVPropertiesIncorrectTests, - ::testing::Combine( - ::testing::Values(CommonTestUtils::DEVICE_HETERO), - ::testing::ValuesIn(hetero_inproperties)), - OVPropertiesIncorrectTests::getTestCaseName); +INSTANTIATE_TEST_SUITE_P(smoke_Hetero_BehaviorTests, + OVPropertiesIncorrectTests, + ::testing::Combine(::testing::Values(CommonTestUtils::DEVICE_HETERO), + ::testing::ValuesIn(hetero_inproperties)), + OVPropertiesIncorrectTests::getTestCaseName); -INSTANTIATE_TEST_SUITE_P(DISABLED_smoke_Multi_BehaviorTests, OVPropertiesIncorrectTests, - ::testing::Combine( - ::testing::Values(CommonTestUtils::DEVICE_MULTI), - ::testing::ValuesIn(multi_inproperties)), - OVPropertiesIncorrectTests::getTestCaseName); +INSTANTIATE_TEST_SUITE_P(smoke_Multi_BehaviorTests, + OVPropertiesIncorrectTests, + ::testing::Combine(::testing::Values(CommonTestUtils::DEVICE_MULTI), + ::testing::ValuesIn(multi_inproperties)), + OVPropertiesIncorrectTests::getTestCaseName); -INSTANTIATE_TEST_SUITE_P(DISABLED_smoke_Auto_BehaviorTests, OVPropertiesIncorrectTests, - ::testing::Combine( - ::testing::Values(CommonTestUtils::DEVICE_AUTO), - ::testing::ValuesIn(auto_inproperties)), - OVPropertiesIncorrectTests::getTestCaseName); +INSTANTIATE_TEST_SUITE_P(smoke_Auto_BehaviorTests, + OVPropertiesIncorrectTests, + ::testing::Combine(::testing::Values(CommonTestUtils::DEVICE_AUTO), + ::testing::ValuesIn(auto_inproperties)), + OVPropertiesIncorrectTests::getTestCaseName); -INSTANTIATE_TEST_SUITE_P(DISABLED_smoke_AutoBatch_BehaviorTests, OVPropertiesIncorrectTests, - ::testing::Combine( - ::testing::Values(CommonTestUtils::DEVICE_BATCH), - ::testing::ValuesIn(auto_batch_inproperties)), - OVPropertiesIncorrectTests::getTestCaseName); +INSTANTIATE_TEST_SUITE_P(smoke_AutoBatch_BehaviorTests, + OVPropertiesIncorrectTests, + ::testing::Combine(::testing::Values(CommonTestUtils::DEVICE_BATCH), + ::testing::ValuesIn(auto_batch_inproperties)), + OVPropertiesIncorrectTests::getTestCaseName); const std::vector default_properties = { - {ov::enable_profiling(true)}, - {ov::device::id(0)}, + {ov::enable_profiling(true)}, + {ov::device::id(0)}, }; -INSTANTIATE_TEST_SUITE_P(smoke_BehaviorTests, OVPropertiesDefaultTests, - ::testing::Combine( - ::testing::Values(CommonTestUtils::DEVICE_TEMPLATE), - ::testing::ValuesIn(default_properties)), - OVPropertiesDefaultTests::getTestCaseName); +INSTANTIATE_TEST_SUITE_P(smoke_BehaviorTests, + OVPropertiesDefaultTests, + ::testing::Combine(::testing::Values(CommonTestUtils::DEVICE_TEMPLATE), + ::testing::ValuesIn(default_properties)), + OVPropertiesDefaultTests::getTestCaseName); const std::vector properties = { - {ov::enable_profiling(true)}, - {ov::device::id(0)}, + {ov::enable_profiling(true)}, + {ov::device::id(0)}, }; const std::vector hetero_properties = { - {ov::device::priorities(CommonTestUtils::DEVICE_TEMPLATE), ov::enable_profiling(true)}, - {ov::device::priorities(CommonTestUtils::DEVICE_TEMPLATE), ov::device::id(0)}, + {ov::device::priorities(CommonTestUtils::DEVICE_TEMPLATE), ov::enable_profiling(true)}, + {ov::device::priorities(CommonTestUtils::DEVICE_TEMPLATE), ov::device::id(0)}, }; - const std::vector multi_properties = { - {ov::device::priorities(CommonTestUtils::DEVICE_TEMPLATE), ov::enable_profiling(true)}, - {ov::device::priorities(CommonTestUtils::DEVICE_TEMPLATE), ov::device::id(0)}, + {ov::device::priorities(CommonTestUtils::DEVICE_TEMPLATE), ov::enable_profiling(true)}, + {ov::device::priorities(CommonTestUtils::DEVICE_TEMPLATE), ov::device::id(0)}, }; const std::vector auto_batch_properties = { - {{CONFIG_KEY(AUTO_BATCH_DEVICE_CONFIG) , CommonTestUtils::DEVICE_TEMPLATE}}, - {{CONFIG_KEY(AUTO_BATCH_DEVICE_CONFIG) , CommonTestUtils::DEVICE_TEMPLATE}, - {CONFIG_KEY(AUTO_BATCH_TIMEOUT) , "1"}}, + {{CONFIG_KEY(AUTO_BATCH_DEVICE_CONFIG), CommonTestUtils::DEVICE_TEMPLATE}}, + {{CONFIG_KEY(AUTO_BATCH_DEVICE_CONFIG), CommonTestUtils::DEVICE_TEMPLATE}, {CONFIG_KEY(AUTO_BATCH_TIMEOUT), "1"}}, }; -INSTANTIATE_TEST_SUITE_P(smoke_BehaviorTests, OVPropertiesTests, - ::testing::Combine( - ::testing::Values(CommonTestUtils::DEVICE_TEMPLATE), - ::testing::ValuesIn(properties)), - OVPropertiesTests::getTestCaseName); +INSTANTIATE_TEST_SUITE_P(smoke_BehaviorTests, + OVPropertiesTests, + ::testing::Combine(::testing::Values(CommonTestUtils::DEVICE_TEMPLATE), + ::testing::ValuesIn(properties)), + OVPropertiesTests::getTestCaseName); -INSTANTIATE_TEST_SUITE_P(DISABLED_smoke_Hetero_BehaviorTests, OVPropertiesTests, - ::testing::Combine( - ::testing::Values(CommonTestUtils::DEVICE_HETERO), - ::testing::ValuesIn(hetero_properties)), - OVPropertiesTests::getTestCaseName); +INSTANTIATE_TEST_SUITE_P(smoke_Hetero_BehaviorTests, + OVPropertiesTests, + ::testing::Combine(::testing::Values(CommonTestUtils::DEVICE_HETERO), + ::testing::ValuesIn(hetero_properties)), + OVPropertiesTests::getTestCaseName); -INSTANTIATE_TEST_SUITE_P(DISABLED_smoke_Multi_BehaviorTests, OVPropertiesTests, - ::testing::Combine( - ::testing::Values(CommonTestUtils::DEVICE_MULTI), - ::testing::ValuesIn(multi_properties)), - OVPropertiesTests::getTestCaseName); +INSTANTIATE_TEST_SUITE_P(smoke_Multi_BehaviorTests, + OVPropertiesTests, + ::testing::Combine(::testing::Values(CommonTestUtils::DEVICE_MULTI), + ::testing::ValuesIn(multi_properties)), + OVPropertiesTests::getTestCaseName); -INSTANTIATE_TEST_SUITE_P(DISABLED_smoke_AutoBatch_BehaviorTests, OVPropertiesTests, - ::testing::Combine( - ::testing::Values(CommonTestUtils::DEVICE_BATCH), - ::testing::ValuesIn(auto_batch_properties)), - OVPropertiesTests::getTestCaseName); +INSTANTIATE_TEST_SUITE_P(smoke_AutoBatch_BehaviorTests, + OVPropertiesTests, + ::testing::Combine(::testing::Values(CommonTestUtils::DEVICE_BATCH), + ::testing::ValuesIn(auto_batch_properties)), + OVPropertiesTests::getTestCaseName); -const std::vector>> GetMetricTest_ExecutionDevice_TEMPLATE = { - {CommonTestUtils::DEVICE_TEMPLATE, std::make_pair(ov::AnyMap{}, CommonTestUtils::DEVICE_TEMPLATE)}}; - -INSTANTIATE_TEST_SUITE_P( - smoke_OVClassExecutableNetworkGetMetricTest, OVClassExecutableNetworkGetMetricTest_EXEC_DEVICES, - ::testing::ValuesIn(GetMetricTest_ExecutionDevice_TEMPLATE), - OVCompileModelGetExecutionDeviceTests::getTestCaseName); +const std::vector>> GetMetricTest_ExecutionDevice_TEMPLATE = + {{CommonTestUtils::DEVICE_TEMPLATE, std::make_pair(ov::AnyMap{}, "TEMPLATE.0")}}; +INSTANTIATE_TEST_SUITE_P(smoke_OVClassExecutableNetworkGetMetricTest, + OVClassExecutableNetworkGetMetricTest_EXEC_DEVICES, + ::testing::ValuesIn(GetMetricTest_ExecutionDevice_TEMPLATE), + OVCompileModelGetExecutionDeviceTests::getTestCaseName); // // OV Class GetMetric // -INSTANTIATE_TEST_SUITE_P( - smoke_OVGetMetricPropsTest, OVGetMetricPropsTest, - ::testing::Values(CommonTestUtils::DEVICE_TEMPLATE)); +INSTANTIATE_TEST_SUITE_P(smoke_OVGetMetricPropsTest, + OVGetMetricPropsTest, + ::testing::Values(CommonTestUtils::DEVICE_TEMPLATE)); -INSTANTIATE_TEST_SUITE_P( - smoke_OVGetConfigTest, OVGetConfigTest_ThrowUnsupported, - ::testing::Values(CommonTestUtils::DEVICE_TEMPLATE)); +INSTANTIATE_TEST_SUITE_P(smoke_OVGetConfigTest, + OVGetConfigTest_ThrowUnsupported, + ::testing::Values(CommonTestUtils::DEVICE_TEMPLATE)); -INSTANTIATE_TEST_SUITE_P( - smoke_OVGetAvailableDevicesPropsTest, OVGetAvailableDevicesPropsTest, - ::testing::Values(CommonTestUtils::DEVICE_TEMPLATE)); +INSTANTIATE_TEST_SUITE_P(smoke_OVGetAvailableDevicesPropsTest, + OVGetAvailableDevicesPropsTest, + ::testing::Values(CommonTestUtils::DEVICE_TEMPLATE)); // // OV Class GetConfig // -INSTANTIATE_TEST_SUITE_P( - smoke_OVGetConfigTest, OVGetConfigTest, - ::testing::Values(CommonTestUtils::DEVICE_TEMPLATE)); +INSTANTIATE_TEST_SUITE_P(smoke_OVGetConfigTest, OVGetConfigTest, ::testing::Values(CommonTestUtils::DEVICE_TEMPLATE)); -INSTANTIATE_TEST_SUITE_P( - smoke_OVClassBasicPropsTestP, OVClassBasicPropsTestP, - ::testing::Values(std::make_pair("openvino_template_plugin", CommonTestUtils::DEVICE_TEMPLATE))); -} // namespace +INSTANTIATE_TEST_SUITE_P(smoke_OVClassBasicPropsTestP, + OVClassBasicPropsTestP, + ::testing::Values(std::make_pair("openvino_template_plugin", + CommonTestUtils::DEVICE_TEMPLATE))); +} // namespace diff --git a/src/plugins/template/tests/functional/shared_tests_instances/behavior/plugin/set_preprocess.cpp b/src/plugins/template/tests/functional/shared_tests_instances/behavior/plugin/set_preprocess.cpp index 247656426ef..e6337577536 100644 --- a/src/plugins/template/tests/functional/shared_tests_instances/behavior/plugin/set_preprocess.cpp +++ b/src/plugins/template/tests/functional/shared_tests_instances/behavior/plugin/set_preprocess.cpp @@ -4,8 +4,6 @@ #include "behavior/plugin/set_preprocess.hpp" -#ifdef ENABLE_GAPI_PREPROCESSING - using namespace BehaviorTestsDefinitions; namespace { @@ -55,12 +53,10 @@ const std::vector ioPrecisions = { }; const std::vector netLayouts = { InferenceEngine::Layout::NCHW, - // InferenceEngine::Layout::NHWC }; const std::vector ioLayouts = { InferenceEngine::Layout::NCHW, - InferenceEngine::Layout::NHWC }; INSTANTIATE_TEST_SUITE_P(smoke_BehaviorTests, InferRequestPreprocessConversionTest, @@ -77,20 +73,4 @@ INSTANTIATE_TEST_SUITE_P(smoke_BehaviorTests, InferRequestPreprocessConversionTe ::testing::ValuesIn(configs)), InferRequestPreprocessConversionTest::getTestCaseName); -INSTANTIATE_TEST_SUITE_P(smoke_BehaviorTests, InferRequestPreprocessDynamicallyInSetBlobTest, - ::testing::Combine( - ::testing::ValuesIn(netPrecisions), - ::testing::Bool(), - ::testing::Bool(), - ::testing::ValuesIn(netLayouts), - ::testing::Bool(), - ::testing::Bool(), - ::testing::Values(true), // only SetBlob - ::testing::Values(true), // only SetBlob - ::testing::Values(CommonTestUtils::DEVICE_TEMPLATE), - ::testing::ValuesIn(configs)), - InferRequestPreprocessDynamicallyInSetBlobTest::getTestCaseName); - } // namespace - -#endif // ENABLE_GAPI_PREPROCESSING diff --git a/src/plugins/template/tests/functional/skip_tests_config.cpp b/src/plugins/template/tests/functional/skip_tests_config.cpp index 31ac9eb4489..94cbfe6e677 100644 --- a/src/plugins/template/tests/functional/skip_tests_config.cpp +++ b/src/plugins/template/tests/functional/skip_tests_config.cpp @@ -3,42 +3,26 @@ // #include "functional_test_utils/skip_tests_config.hpp" -#include "openvino/core/core_visibility.hpp" #include #include +#include "openvino/core/core_visibility.hpp" + std::vector disabledTestPatterns() { std::vector retVector{ - R"(.*ExclusiveAsyncRequests.*)", - R"(.*ReusableCPUStreamsExecutor.*)", - R"(.*SplitLayerTest.*numSplits=30.*)", - // CVS-51758 - R"(.*InferRequestPreprocessConversionTest.*oLT=(NHWC|NCHW).*)", - R"(.*InferRequestPreprocessDynamicallyInSetBlobTest.*oPRC=0.*oLT=1.*)", // Not Implemented - R"(.*(Multi|Auto|Hetero).*Behavior.*OVCompiledModelBaseTest.*(CheckExecGraphInfoBeforeExecution|CheckExecGraphInfoAfterExecution).*)", - R"(.*(Multi|Auto|Hetero).*Behavior.*OVCompiledModelBaseTest.*(checkGetExecGraphInfoIsNotNullptr).*)", - R"(.*OVClassExecutableNetworkGetMetricTest_EXEC_DEVICES.*CanGetExecutionDeviceInfo.*)", - R"(.*OVClassHeteroExecutableNetworkGetMetricTest_SUPPORTED_CONFIG_KEYS.*GetMetricNoThrow.*)", - R"(.*OVClassHeteroExecutableNetworkGetMetricTest_SUPPORTED_METRICS.*GetMetricNoThrow.*)", - + R"(.*(Multi|Auto|Hetero).*Behavior.*OVCompiledModelBaseTest.*CheckExecGraphInfoBeforeExecution.*)", + R"(.*(Multi|Auto|Hetero).*Behavior.*OVCompiledModelBaseTest.*CheckExecGraphInfoAfterExecution.*)", + R"(.*(Multi|Auto|Hetero).*Behavior.*OVCompiledModelBaseTest.*checkGetExecGraphInfoIsNotNullptr.*)", + R"(.*smoke_(Multi|Auto|Hetero)_BehaviorTests.*OVPropertiesTests.*SetCorrectProperties.*)", + R"(.*smoke_(Multi|Auto|Hetero)_BehaviorTests.*OVPropertiesTests.*canSetPropertyAndCheckGetProperty.*)", + // // unsupported metrics R"(.*smoke_OVGetMetricPropsTest.*OVGetMetricPropsTest.*(DEVICE_UUID|FULL_DEVICE_NAME_with_DEVICE_ID|RANGE_FOR_STREAMS|DEVICE_GOPS|DEVICE_TYPE|MAX_BATCH_SIZE).*)", - // TODO: Round with f16 is not supported - R"(.*smoke_Hetero_BehaviorTests.*OVExecGraphImportExportTest.*readFromV10IR.*)", - // TODO: support import / export of precisions in template plugin - R"(.*smoke_Hetero_BehaviorTests.*OVExecGraphImportExportTest.ieImportExportedFunction.*)", - R"(.*smoke_BehaviorTests.*OVExecGraphImportExportTest.ieImportExportedFunction.*)", - // TODO: Round with f16 is not supported - R"(.*smoke_Hetero_BehaviorTests.*OVExecGraphImportExportTest.*readFromV10IR.*)", - - R"(.*importExportedIENetworkParameterResultOnly.*elementType=(i8|u8).*)", - R"(.*importExportedIENetworkParameterResultOnly.*elementType=(i16|u16).*)", - R"(.*importExportedIENetworkParameterResultOnly.*elementType=(i64|u64).*)", - R"(.*importExportedIENetworkParameterResultOnly.*elementType=u32.*)", - R"(.*importExportedIENetworkConstantResultOnly.*elementType=(u32|u64).*)", + // CVS-55937 + R"(.*SplitLayerTest.*numSplits=30.*)", // CVS-64094 R"(.*ReferenceLogSoftmaxLayerTest.*4.*iType=f16.*axis=.*1.*)", @@ -107,8 +91,7 @@ std::vector disabledTestPatterns() { // CVS-71891 R"(.*ReferenceTileTest.*rType=i4.*)", R"(.*ReferenceTileTest.*rType=u4.*)", - // CVS-95608 - R"(.*CachingSupportCase.*CompileModelCacheTestBase.*)", + // New plugin API doesn't support legacy NV12 I420 preprocessing R"(.*ConvertNV12WithLegacyTest.*)", R"(.*ConvertI420WithLegacyTest.*)", @@ -145,7 +128,8 @@ std::vector disabledTestPatterns() { retVector.emplace_back(R"(.*smoke_TopK_With_Hardcoded_Refs/ReferenceTopKTestMaxMinSortV3.CompareWithRefs.*)"); retVector.emplace_back(R"(.*smoke_TopK_With_Hardcoded_Refs/ReferenceTopKTestBackendV3.CompareWithRefs.*)"); // fails only on Linux arm64 - retVector.emplace_back(R"(.*ReferenceConversionLayerTest.CompareWithHardcodedRefs/conversionType=(Convert|ConvertLike)_shape=.*_iType=(f16|f32|bf16)_oType=u4.*)"); + retVector.emplace_back( + R"(.*ReferenceConversionLayerTest.CompareWithHardcodedRefs/conversionType=(Convert|ConvertLike)_shape=.*_iType=(f16|f32|bf16)_oType=u4.*)"); #endif return retVector; }