OpenCV  4.10.0-dev
Open Source Computer Vision
Loading...
Searching...
No Matches
Classes | Functions
Common functions and classes

Detailed Description

Classes

class  cv::GraphicalCodeDetector
 
class  cv::SimilarRects
 This class is used for grouping object candidates detected by Cascade Classifier, HOG etc. More...
 

Functions

void cv::groupRectangles (std::vector< Rect > &rectList, int groupThreshold, double eps, std::vector< int > *weights, std::vector< double > *levelWeights)
 
void cv::groupRectangles (std::vector< Rect > &rectList, int groupThreshold, double eps=0.2)
 Groups the object candidate rectangles.
 
void cv::groupRectangles (std::vector< Rect > &rectList, std::vector< int > &rejectLevels, std::vector< double > &levelWeights, int groupThreshold, double eps=0.2)
 
void cv::groupRectangles (std::vector< Rect > &rectList, std::vector< int > &weights, int groupThreshold, double eps=0.2)
 
void cv::groupRectangles_meanshift (std::vector< Rect > &rectList, std::vector< double > &foundWeights, std::vector< double > &foundScales, double detectThreshold=0.0, Size winDetSize=Size(64, 128))
 

Function Documentation

◆ groupRectangles() [1/4]

void cv::groupRectangles ( std::vector< Rect > &  rectList,
int  groupThreshold,
double  eps,
std::vector< int > *  weights,
std::vector< double > *  levelWeights 
)
Python:
cv.groupRectangles(rectList, groupThreshold[, eps]) -> rectList, weights

#include <opencv2/objdetect.hpp>

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

◆ groupRectangles() [2/4]

void cv::groupRectangles ( std::vector< Rect > &  rectList,
int  groupThreshold,
double  eps = 0.2 
)
Python:
cv.groupRectangles(rectList, groupThreshold[, eps]) -> rectList, weights

#include <opencv2/objdetect.hpp>

Groups the object candidate rectangles.

Parameters
rectListInput/output vector of rectangles. Output vector includes retained and grouped rectangles. (The Python list is not modified in place.)
groupThresholdMinimum possible number of rectangles minus 1. The threshold is used in a group of rectangles to retain it.
epsRelative difference between sides of the rectangles to merge them into a group.

The function is a wrapper for the generic function partition . It clusters all the input rectangles using the rectangle equivalence criteria that combines rectangles with similar sizes and similar locations. The similarity is defined by eps. When eps=0 , no clustering is done at all. If \(\texttt{eps}\rightarrow +\inf\) , all the rectangles are put in one cluster. Then, the small clusters containing less than or equal to groupThreshold rectangles are rejected. In each other cluster, the average rectangle is computed and put into the output rectangle list.

◆ groupRectangles() [3/4]

void cv::groupRectangles ( std::vector< Rect > &  rectList,
std::vector< int > &  rejectLevels,
std::vector< double > &  levelWeights,
int  groupThreshold,
double  eps = 0.2 
)
Python:
cv.groupRectangles(rectList, groupThreshold[, eps]) -> rectList, weights

#include <opencv2/objdetect.hpp>

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

◆ groupRectangles() [4/4]

void cv::groupRectangles ( std::vector< Rect > &  rectList,
std::vector< int > &  weights,
int  groupThreshold,
double  eps = 0.2 
)
Python:
cv.groupRectangles(rectList, groupThreshold[, eps]) -> rectList, weights

#include <opencv2/objdetect.hpp>

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

◆ groupRectangles_meanshift()

void cv::groupRectangles_meanshift ( std::vector< Rect > &  rectList,
std::vector< double > &  foundWeights,
std::vector< double > &  foundScales,
double  detectThreshold = 0.0,
Size  winDetSize = Size(64, 128) 
)

#include <opencv2/objdetect.hpp>

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.