1
0
mirror of https://github.com/opencv/opencv.git synced 2026-07-29 15:23:05 +04:00

Merge pull request #23762 from TolyaTalamanov:at/gapi-ov-backend-hotfix

G-API: OpenVINO Backend Hotfix
This commit is contained in:
Alexander Smorkalov
2023-06-08 09:50:34 +03:00
committed by GitHub
4 changed files with 9 additions and 9 deletions
+3 -3
View File
@@ -10,7 +10,7 @@
// (cv::gapi::ov::backend() is still there and is defined always)
#include "backends/ov/govbackend.hpp"
#ifdef HAVE_INF_ENGINE
#if defined HAVE_INF_ENGINE && INF_ENGINE_RELEASE >= 2022010000
#include "backends/ov/util.hpp"
#include "api/gbackend_priv.hpp" // FIXME: Make it part of Backend SDK!
@@ -991,11 +991,11 @@ void cv::gimpl::ov::GOVExecutable::run(cv::gimpl::GIslandExecutable::IInput &in
}
}
#else // HAVE_INF_ENGINE
#else // HAVE_INF_ENGINE && INF_ENGINE_RELEASE >= 2022010000
cv::gapi::GBackend cv::gapi::ov::backend() {
// Still provide this symbol to avoid linking issues
util::throw_error(std::runtime_error("G-API has been compiled without OpenVINO support"));
}
#endif // HAVE_INF_ENGINE
#endif // HAVE_INF_ENGINE && INF_ENGINE_RELEASE >= 2022010000
+2 -2
View File
@@ -10,7 +10,7 @@
// Include anyway - cv::gapi::ov::backend() still needs to be defined
#include "opencv2/gapi/infer/ov.hpp"
#ifdef HAVE_INF_ENGINE
#if defined HAVE_INF_ENGINE && INF_ENGINE_RELEASE >= 2022010000
#include <openvino/openvino.hpp>
@@ -62,5 +62,5 @@ public:
}}}
#endif // HAVE_INF_ENGINE
#endif // HAVE_INF_ENGINE && INF_ENGINE_RELEASE >= 2022010000
#endif // OPENCV_GAPI_GOVBACKEND_HPP
+2 -2
View File
@@ -7,7 +7,7 @@
#ifndef OPENCV_GAPI_INFER_OV_UTIL_HPP
#define OPENCV_GAPI_INFER_OV_UTIL_HPP
#ifdef HAVE_INF_ENGINE
#if defined HAVE_INF_ENGINE && INF_ENGINE_RELEASE >= 2022010000
// NOTE: This file is not included by default in infer/ov.hpp
// and won't be. infer/ov.hpp doesn't depend on OV headers itself.
@@ -30,6 +30,6 @@ GAPI_EXPORTS int to_ocv(const ::ov::element::Type &type);
}}}}
#endif // HAVE_INF_ENGINE
#endif // HAVE_INF_ENGINE && INF_ENGINE_RELEASE >= 2022010000
#endif // OPENCV_GAPI_INFER_OV_UTIL_HPP
@@ -4,7 +4,7 @@
//
// Copyright (C) 2023 Intel Corporation
#ifdef HAVE_INF_ENGINE
#if defined HAVE_INF_ENGINE && INF_ENGINE_RELEASE >= 2022010000
#include "../test_precomp.hpp"
@@ -537,4 +537,4 @@ TEST(TestAgeGenderOV, InferTensorWithPreproc) {
} // namespace opencv_test
#endif // HAVE_INF_ENGINE
#endif // HAVE_INF_ENGINE && INF_ENGINE_RELEASE >= 2022010000