Skip to content

Commit

Permalink
Returned win guards.
Browse files Browse the repository at this point in the history
  • Loading branch information
popovaan committed Jul 4, 2024
1 parent dcb7d2f commit 441439e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/bindings/python/src/pyopenvino/frontend/frontend.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ void regclass_frontend_FrontEnd(py::module m) {
py::isinstance<py::str>(py_obj)) {

// Fix unicode path
#if defined(OPENVINO_ENABLE_UNICODE_PATH_SUPPORT)
#if defined(OPENVINO_ENABLE_UNICODE_PATH_SUPPORT) && defined(_WIN32)
return self.load(ov::util::string_to_wstring(model_path.c_str()));
#else
return self.load(model_path.c_str());
Expand Down Expand Up @@ -89,7 +89,7 @@ void regclass_frontend_FrontEnd(py::module m) {
py::isinstance<py::str>(model)) {

// Fix unicode path
#if defined(OPENVINO_ENABLE_UNICODE_PATH_SUPPORT)
#if defined(OPENVINO_ENABLE_UNICODE_PATH_SUPPORT) && defined(_WIN32)
return self.supported(ov::util::string_to_wstring(model_path.c_str()));
#else
return self.supported(model_path.c_str());
Expand Down
2 changes: 1 addition & 1 deletion src/bindings/python/src/pyopenvino/frontend/manager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ void regclass_frontend_FrontEndManager(py::module m) {
std::string model_path = Common::utils::convert_path_to_string(model);

// Fix unicode path
#if defined(OPENVINO_ENABLE_UNICODE_PATH_SUPPORT)
#if defined(OPENVINO_ENABLE_UNICODE_PATH_SUPPORT) && defined(_WIN32)
return fem->load_by_model(ov::util::string_to_wstring(model_path.c_str()));
#else
std::string model_path_str = model_path;
Expand Down

0 comments on commit 441439e

Please sign in to comment.