8#include <opencv2/core/mat.hpp>
9#include <opencv2/dnn/dnn.hpp>
11#include <opencv2/core/cuda.hpp>
25 void proc(
const cv::Mat &image, cv::Mat &output);
31 bool procGpu(
const cv::Mat &image, cv::cuda::GpuMat &output);
36 std::unique_ptr<Impl>
impl;
42 explicit Dexined(
const std::string &modelPath);
48 void processFrame(
const cv::Mat &image, cv::Mat &result);
52 std::unique_ptr<Impl>
impl;
59 explicit PPHS(
const std::string &modelPath,
int backendId = -1,
int targetId = -1);
66 cv::Mat
infer(
const cv::Mat &image);
71 std::unique_ptr<Impl>
impl;
74 cv::Mat
isolateBody(
const cv::Mat &image,
const cv::Mat &mask,
float blackPoint = 0.35f,
float whitePoint = 0.75f);
75 cv::Mat
hardenedAlphaMask(
const cv::Mat &image,
const cv::Mat &mask,
float blackPoint = 0.35f,
float whitePoint = 0.75f);
std::unique_ptr< Impl > impl
Dexined(const std::string &modelPath)
Dexined(const Dexined &)=delete
void processFrame(const cv::Mat &image, cv::Mat &result)
Dexined & operator=(const Dexined &)=delete
std::unique_ptr< Impl > impl
OnnxWrapper & operator=(const OnnxWrapper &)=delete
OnnxWrapper(const OnnxWrapper &)=delete
OnnxWrapper(std::string_view yamlPath)
void proc(const cv::Mat &image, cv::Mat &output)
PPHS(const std::string &modelPath, int backendId=-1, int targetId=-1)
cv::Mat postprocess(const cv::Mat &outputBlob)
cv::Mat infer(const cv::Mat &image)
std::unique_ptr< Impl > impl
PPHS & operator=(const PPHS &)=delete
cv::Mat preprocess(const cv::Mat &image)
PPHS(const PPHS &)=delete
cv::Mat hardenedAlphaMask(const cv::Mat &image, const cv::Mat &mask, float blackPoint, float whitePoint)
cv::Mat isolateBody(const cv::Mat &image, const cv::Mat &mask, float blackPoint, float whitePoint)