From a03c7af03846f36248683b2c4b8cfd976485e0c6 Mon Sep 17 00:00:00 2001 From: Inki Dae Date: Tue, 23 Aug 2022 15:10:40 +0900 Subject: [PATCH] fix not-found backend library issue [Version] : 0.4.4 [Issue type] : bug fix Fixed a bug that library isn't found in case that a backend_name is given and backend_type isn't -1, which was reported by VD division. Ps. backend_type will be dropped later because only one path should exist for one purpose. Change-Id: I33a27bad14982fa7913fe12fe8f33efc6a9c7c0e Signed-off-by: Inki Dae --- packaging/inference-engine-interface.spec | 2 +- src/inference_engine_common_impl.cpp | 10 ++++++++++ 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packaging/inference-engine-interface.spec b/packaging/inference-engine-interface.spec index 269b1f9..9dad94f 100644 --- a/packaging/inference-engine-interface.spec +++ b/packaging/inference-engine-interface.spec @@ -1,6 +1,6 @@ Name: inference-engine-interface Summary: Interface of inference engines -Version: 0.4.3 +Version: 0.4.4 Release: 0 Group: Multimedia/Framework License: Apache-2.0 diff --git a/src/inference_engine_common_impl.cpp b/src/inference_engine_common_impl.cpp index 3467ee0..a51ae07 100644 --- a/src/inference_engine_common_impl.cpp +++ b/src/inference_engine_common_impl.cpp @@ -378,6 +378,16 @@ namespace Common mProfiler.Start(IE_PROFILER_MEMORY); } + if (!config->backend_name.empty()) { + // if backend name is "mlapi" then backend path is decided by a given backend_type. + // Otherwise, backend_name has higher priority than backend_type. + // So other backend name(not mlapi) is given then set backend_type to -1 + // so that the backend path can be decided by a given backend_name. + // TODO. drop backend_type later because only one path should exist for one purpose. + if (config->backend_name.compare("mlapi") != 0) + config->backend_type = -1; + } + // If backend_type of config is -1 then update it according to backend_name. if (config->backend_type == -1) { std::map BackendTable; -- 2.7.4