From 749ed9dec7f2817fb3f27838ea3d307bf14c9ebf Mon Sep 17 00:00:00 2001 From: Ilya Lavrenov Date: Tue, 3 Oct 2023 22:47:52 +0400 Subject: [PATCH] Added python search path for Conda (#19929) --- src/bindings/python/src/openvino/utils.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/bindings/python/src/openvino/utils.py b/src/bindings/python/src/openvino/utils.py index a1467b427b9a75..a62418d951fc24 100644 --- a/src/bindings/python/src/openvino/utils.py +++ b/src/bindings/python/src/openvino/utils.py @@ -18,9 +18,12 @@ def _add_openvino_libs_to_search_path() -> None: # If you're using a custom installation of openvino, # add the location of openvino dlls to your system PATH. openvino_libs = [] - # looking for the libs in the pip installation path. if os.path.isdir(os.path.join(os.path.dirname(__file__), "libs")): + # looking for the libs in the pip installation path. openvino_libs.append(os.path.join(os.path.dirname(__file__), "libs")) + elif os.path.isdir(os.path.join(os.path.dirname(__file__), "..", "..", "..", "Library", "bin")): + # looking for the libs in the conda installation path + openvino_libs.append(os.path.join(os.path.dirname(__file__), "..", "..", "..", "Library", "bin")) else: # setupvars.bat script set all libs paths to OPENVINO_LIB_PATHS environment variable. openvino_libs_installer = os.getenv("OPENVINO_LIB_PATHS")