Skip to content

Commit e7680ce

Browse files
committed
Trim unused methods in the adapters
1 parent df479e7 commit e7680ce

File tree

3 files changed

+0
-27
lines changed

3 files changed

+0
-27
lines changed

src/cpp/include/adapters/inference_adapter.h

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -30,16 +30,11 @@ class InferenceAdapter {
3030
virtual bool isReady() = 0;
3131
virtual void awaitAll() = 0;
3232
virtual void awaitAny() = 0;
33-
virtual size_t getNumAsyncExecutors() const = 0;
3433
virtual void loadModel(const std::string& modelPath,
3534
const std::string& device = "",
3635
const ov::AnyMap& adapterConfig = {},
3736
bool preCompile = true) = 0;
3837
virtual void compileModel(const std::string& device = "", const ov::AnyMap& adapterConfig = {}) = 0;
39-
virtual ov::PartialShape getInputShape(const std::string& inputName) const = 0;
40-
virtual ov::PartialShape getOutputShape(const std::string& inputName) const = 0;
41-
virtual ov::element::Type_t getInputDatatype(const std::string& inputName) const = 0;
42-
virtual ov::element::Type_t getOutputDatatype(const std::string& outputName) const = 0;
4338
virtual std::vector<std::string> getInputNames() const = 0;
4439
virtual std::vector<std::string> getOutputNames() const = 0;
4540
virtual const ov::AnyMap& getModelConfig() const = 0;

src/cpp/include/adapters/openvino_adapter.h

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -30,11 +30,6 @@ class OpenVINOInferenceAdapter : public InferenceAdapter {
3030
const ov::AnyMap& adapterConfig = {},
3131
bool preCompile = true) override;
3232
virtual void compileModel(const std::string& device = "", const ov::AnyMap& adapterConfig = {}) override;
33-
virtual size_t getNumAsyncExecutors() const;
34-
virtual ov::PartialShape getInputShape(const std::string& inputName) const override;
35-
virtual ov::PartialShape getOutputShape(const std::string& outputName) const override;
36-
virtual ov::element::Type_t getInputDatatype(const std::string& inputName) const override;
37-
virtual ov::element::Type_t getOutputDatatype(const std::string& outputName) const override;
3833
virtual std::vector<std::string> getInputNames() const override;
3934
virtual std::vector<std::string> getOutputNames() const override;
4035
virtual const ov::AnyMap& getModelConfig() const override;

src/cpp/src/adapters/openvino_adapter.cpp

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -120,17 +120,6 @@ void OpenVINOInferenceAdapter::awaitAny() {
120120
asyncQueue->get_idle_request_id();
121121
}
122122

123-
size_t OpenVINOInferenceAdapter::getNumAsyncExecutors() const {
124-
return asyncQueue->size();
125-
}
126-
127-
ov::PartialShape OpenVINOInferenceAdapter::getInputShape(const std::string& inputName) const {
128-
return compiledModel.input(inputName).get_partial_shape();
129-
}
130-
ov::PartialShape OpenVINOInferenceAdapter::getOutputShape(const std::string& outputName) const {
131-
return compiledModel.output(outputName).get_partial_shape();
132-
}
133-
134123
void OpenVINOInferenceAdapter::initInputsOutputs() {
135124
for (const auto& input : compiledModel.inputs()) {
136125
inputNames.push_back(input.get_any_name());
@@ -140,12 +129,6 @@ void OpenVINOInferenceAdapter::initInputsOutputs() {
140129
outputNames.push_back(output.get_any_name());
141130
}
142131
}
143-
ov::element::Type_t OpenVINOInferenceAdapter::getInputDatatype(const std::string& name) const {
144-
return compiledModel.input(name).get_element_type();
145-
}
146-
ov::element::Type_t OpenVINOInferenceAdapter::getOutputDatatype(const std::string& name) const {
147-
return compiledModel.output(name).get_element_type();
148-
}
149132

150133
std::vector<std::string> OpenVINOInferenceAdapter::getInputNames() const {
151134
return inputNames;

0 commit comments

Comments
 (0)