Table of Contents

Method Detect

Namespace
OpenCvSharp
Assembly
OpenCvSharp.dll

Detect(Mat, double, Size?, Size?, Point[]?)

Performs object detection without a multi-scale window.

public virtual Point[] Detect(Mat img, double hitThreshold = 0, Size? winStride = null, Size? padding = null, Point[]? searchLocations = null)

Parameters

img Mat

Source image. CV_8UC1 and CV_8UC4 types are supported for now.

hitThreshold double

Threshold for the distance between features and SVM classifying plane. Usually it is 0 and should be specified in the detector coefficients (as the last free coefficient). But if the free coefficient is omitted (which is allowed), you can specify it manually here.

winStride Size?

Window stride. It must be a multiple of block stride.

padding Size?

Mock parameter to keep the CPU interface compatibility. It must be (0,0).

searchLocations Point[]

Returns

Point[]

Left-top corner points of detected objects boundaries.

Detect(Mat, out double[], double, Size?, Size?, Point[]?)

Performs object detection without a multi-scale window.

public virtual Point[] Detect(Mat img, out double[] weights, double hitThreshold = 0, Size? winStride = null, Size? padding = null, Point[]? searchLocations = null)

Parameters

img Mat

Source image. CV_8UC1 and CV_8UC4 types are supported for now.

weights double[]
hitThreshold double

Threshold for the distance between features and SVM classifying plane. Usually it is 0 and should be specfied in the detector coefficients (as the last free coefficient). But if the free coefficient is omitted (which is allowed), you can specify it manually here.

winStride Size?

Window stride. It must be a multiple of block stride.

padding Size?

Mock parameter to keep the CPU interface compatibility. It must be (0,0).

searchLocations Point[]

Returns

Point[]

Left-top corner points of detected objects boundaries.