|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#ifndef OPENCV_GAPI_OAK_INFER_HPP |
|
|
#define OPENCV_GAPI_OAK_INFER_HPP |
|
|
|
|
|
#include <unordered_map> |
|
|
#include <string> |
|
|
#include <array> |
|
|
#include <tuple> |
|
|
|
|
|
#include <opencv2/gapi/opencv_includes.hpp> |
|
|
#include <opencv2/gapi/util/any.hpp> |
|
|
|
|
|
#include <opencv2/core/cvdef.h> |
|
|
#include <opencv2/gapi/gkernel.hpp> |
|
|
|
|
|
namespace cv { |
|
|
namespace gapi { |
|
|
namespace oak { |
|
|
|
|
|
namespace detail { |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
struct ParamDesc { |
|
|
std::string blob_file; |
|
|
}; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
template<typename Net> class Params { |
|
|
public: |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
explicit Params(const std::string &model) { |
|
|
desc.blob_file = model; |
|
|
}; |
|
|
|
|
|
|
|
|
GBackend backend() const { return cv::gapi::oak::backend(); } |
|
|
std::string tag() const { return Net::tag(); } |
|
|
cv::util::any params() const { return { desc }; } |
|
|
|
|
|
|
|
|
protected: |
|
|
detail::ParamDesc desc; |
|
|
}; |
|
|
|
|
|
} |
|
|
} |
|
|
} |
|
|
|
|
|
#endif |
|
|
|