From e98677db63f318e812de000cfcab635555ff9c3f Mon Sep 17 00:00:00 2001 From: River Li Date: Wed, 17 Jan 2024 14:38:37 +0800 Subject: [PATCH] Remove some legacy API header files (#830) --- .../nvidia_plugin/src/cuda_compiled_model.cpp | 17 ----------- .../nvidia_plugin/src/cuda_infer_request.cpp | 1 - modules/nvidia_plugin/src/cuda_plugin.cpp | 28 ------------------- modules/nvidia_plugin/src/ops/result.cpp | 1 - .../src/transformer/concat_transformation.cpp | 1 - .../fuse_conv_biasadd_activation.cpp | 1 - .../src/transformer/fuse_matmul_add.cpp | 1 - .../transformer/matmul_transformations.cpp | 1 - .../src/transformer/reduce_transformation.cpp | 1 - 9 files changed, 52 deletions(-) diff --git a/modules/nvidia_plugin/src/cuda_compiled_model.cpp b/modules/nvidia_plugin/src/cuda_compiled_model.cpp index 0add8e16e..9bbf59063 100644 --- a/modules/nvidia_plugin/src/cuda_compiled_model.cpp +++ b/modules/nvidia_plugin/src/cuda_compiled_model.cpp @@ -2,10 +2,6 @@ // SPDX-License-Identifier: Apache-2.0 // -#include -// ^^ must come before ie_plugin_config.hpp, which is indirectly included by -// cuda_executable_network.hpp - #include #include @@ -309,19 +305,6 @@ ov::Any CompiledModel::get_property(const std::string& name) const { for (auto& rw_property : rw_properties) supported_properties.emplace_back(ov::PropertyName(rw_property, PropertyMutability::RO)); return decltype(ov::supported_properties)::value_type{supported_properties}; - } else if (EXEC_NETWORK_METRIC_KEY(SUPPORTED_METRICS) == name) { - IE_SET_METRIC_RETURN(SUPPORTED_METRICS, - std::vector{METRIC_KEY(NETWORK_NAME), - METRIC_KEY(SUPPORTED_METRICS), - METRIC_KEY(SUPPORTED_CONFIG_KEYS), - METRIC_KEY(OPTIMAL_NUMBER_OF_INFER_REQUESTS)}); - } else if (EXEC_NETWORK_METRIC_KEY(SUPPORTED_CONFIG_KEYS) == name) { - std::vector configKeys = {}; - auto config_properties = config_.get_rw_properties(); - for (auto&& key : config_properties) { - configKeys.emplace_back(key); - } - IE_SET_METRIC_RETURN(SUPPORTED_CONFIG_KEYS, configKeys); } else if (ov::model_name == name) { auto model_name = model_->get_friendly_name(); return decltype(ov::model_name)::value_type{model_name}; diff --git a/modules/nvidia_plugin/src/cuda_infer_request.cpp b/modules/nvidia_plugin/src/cuda_infer_request.cpp index 4098ac389..598501758 100644 --- a/modules/nvidia_plugin/src/cuda_infer_request.cpp +++ b/modules/nvidia_plugin/src/cuda_infer_request.cpp @@ -5,7 +5,6 @@ #include "cuda_infer_request.hpp" #include -#include #include #include diff --git a/modules/nvidia_plugin/src/cuda_plugin.cpp b/modules/nvidia_plugin/src/cuda_plugin.cpp index ecb04c9f1..cda4e2ec1 100644 --- a/modules/nvidia_plugin/src/cuda_plugin.cpp +++ b/modules/nvidia_plugin/src/cuda_plugin.cpp @@ -201,29 +201,6 @@ ov::Any Plugin::get_property(const std::string& name, const ov::AnyMap& properti return decltype(ov::supported_properties)::value_type{Configuration::get_supported_properties()}; } else if (ov::internal::supported_properties == name) { return decltype(ov::internal::supported_properties)::value_type{Configuration::get_supported_internal_properties()}; - } else if (METRIC_KEY(SUPPORTED_METRICS) == name) { - std::vector supportedMetrics = {METRIC_KEY(AVAILABLE_DEVICES), - METRIC_KEY(SUPPORTED_METRICS), - METRIC_KEY(SUPPORTED_CONFIG_KEYS), - ov::device::uuid.name(), - METRIC_KEY(FULL_DEVICE_NAME), - METRIC_KEY(IMPORT_EXPORT_SUPPORT), - METRIC_KEY(DEVICE_ARCHITECTURE), - METRIC_KEY(OPTIMIZATION_CAPABILITIES), - METRIC_KEY(RANGE_FOR_ASYNC_INFER_REQUESTS)}; - IE_SET_METRIC_RETURN(SUPPORTED_METRICS, supportedMetrics); - } else if (METRIC_KEY(SUPPORTED_CONFIG_KEYS) == name) { - std::vector configKeys = { - CONFIG_KEY(DEVICE_ID), CONFIG_KEY(PERF_COUNT), NVIDIA_CONFIG_KEY(THROUGHPUT_STREAMS)}; - auto streamExecutorConfigKeys = ov::threading::IStreamsExecutor::Config{} - .get_property(ov::supported_properties.name()) - .as>(); - for (auto&& configKey : streamExecutorConfigKeys) { - if (configKey != InferenceEngine::PluginConfigParams::KEY_CPU_THROUGHPUT_STREAMS) { - configKeys.emplace_back(configKey); - } - } - IE_SET_METRIC_RETURN(SUPPORTED_CONFIG_KEYS, configKeys); } else if (ov::internal::caching_properties == name) { return decltype(ov::internal::caching_properties)::value_type{Configuration::get_caching_properties()}; } else if (ov::available_devices == name) { @@ -243,8 +220,6 @@ ov::Any Plugin::get_property(const std::string& name, const ov::AnyMap& properti const auto& props = device.props(); const std::string name = props.name; return decltype(ov::device::full_name)::value_type{name}; - } else if (METRIC_KEY(IMPORT_EXPORT_SUPPORT) == name) { - IE_SET_METRIC_RETURN(IMPORT_EXPORT_SUPPORT, true); } else if (ov::device::architecture == name) { CUDA::Device device{full_config.get_device_id()}; const auto& props = device.props(); @@ -258,9 +233,6 @@ ov::Any Plugin::get_property(const std::string& name, const ov::AnyMap& properti ov::device::capability::EXPORT_IMPORT, ov::device::capability::FP32, ov::device::capability::FP16}}; - } else if (METRIC_KEY(OPTIMIZATION_CAPABILITIES) == name) { - std::vector capabilities = {METRIC_VALUE(FP32)}; - IE_SET_METRIC_RETURN(OPTIMIZATION_CAPABILITIES, capabilities); } else if (ov::range_for_streams == name) { return decltype(ov::range_for_streams)::value_type{1, Configuration::reasonable_limit_of_streams}; } else if (ov::range_for_async_infer_requests == name) { diff --git a/modules/nvidia_plugin/src/ops/result.cpp b/modules/nvidia_plugin/src/ops/result.cpp index 7f7aaf757..2b867804b 100644 --- a/modules/nvidia_plugin/src/ops/result.cpp +++ b/modules/nvidia_plugin/src/ops/result.cpp @@ -7,7 +7,6 @@ #include #include -#include #include #include #include diff --git a/modules/nvidia_plugin/src/transformer/concat_transformation.cpp b/modules/nvidia_plugin/src/transformer/concat_transformation.cpp index 3446c3a93..e584e8884 100644 --- a/modules/nvidia_plugin/src/transformer/concat_transformation.cpp +++ b/modules/nvidia_plugin/src/transformer/concat_transformation.cpp @@ -5,7 +5,6 @@ #include "openvino/cc/pass/itt.hpp" #include "concat_transformation.hpp" -#include #include "openvino/core/rt_info.hpp" #include "openvino/op/concat.hpp" #include "openvino/pass/pattern/op/wrap_type.hpp" diff --git a/modules/nvidia_plugin/src/transformer/fuse_conv_biasadd_activation.cpp b/modules/nvidia_plugin/src/transformer/fuse_conv_biasadd_activation.cpp index 5fe82ac82..8e563e298 100644 --- a/modules/nvidia_plugin/src/transformer/fuse_conv_biasadd_activation.cpp +++ b/modules/nvidia_plugin/src/transformer/fuse_conv_biasadd_activation.cpp @@ -8,7 +8,6 @@ #include "openvino/cc/pass/itt.hpp" #include "fuse_conv_biasadd_activation.hpp" -#include "exec_graph_info.hpp" #include "openvino/core/graph_util.hpp" #include "openvino/core/node.hpp" #include "openvino/core/node_output.hpp" diff --git a/modules/nvidia_plugin/src/transformer/fuse_matmul_add.cpp b/modules/nvidia_plugin/src/transformer/fuse_matmul_add.cpp index a012f2a87..5db667760 100644 --- a/modules/nvidia_plugin/src/transformer/fuse_matmul_add.cpp +++ b/modules/nvidia_plugin/src/transformer/fuse_matmul_add.cpp @@ -5,7 +5,6 @@ #include "openvino/cc/pass/itt.hpp" #include "fuse_matmul_add.hpp" -#include #include "openvino/core/rt_info.hpp" #include "openvino/pass/pattern/op/wrap_type.hpp" #include "openvino/pass/pattern/op/or.hpp" diff --git a/modules/nvidia_plugin/src/transformer/matmul_transformations.cpp b/modules/nvidia_plugin/src/transformer/matmul_transformations.cpp index 97551ed4e..ba7bb4f1f 100644 --- a/modules/nvidia_plugin/src/transformer/matmul_transformations.cpp +++ b/modules/nvidia_plugin/src/transformer/matmul_transformations.cpp @@ -6,7 +6,6 @@ #include "matmul_transformations.hpp" #include -#include #include #include "openvino/core/rt_info.hpp" #include "openvino/pass/pattern/op/wrap_type.hpp" diff --git a/modules/nvidia_plugin/src/transformer/reduce_transformation.cpp b/modules/nvidia_plugin/src/transformer/reduce_transformation.cpp index f9e25971c..1901558ee 100644 --- a/modules/nvidia_plugin/src/transformer/reduce_transformation.cpp +++ b/modules/nvidia_plugin/src/transformer/reduce_transformation.cpp @@ -4,7 +4,6 @@ #include "openvino/cc/pass/itt.hpp" -#include "exec_graph_info.hpp" #include "openvino/core/rt_info.hpp" #include "openvino/pass/manager.hpp" #include "openvino/pass/pattern/op/wrap_type.hpp"