Class LBPHFaceRecognizer
- Namespace
- OpenCvSharp.Face
- Assembly
- OpenCvSharp.dll
Abstract base class for all face recognition models. All face recognition models in OpenCV are derived from the abstract base class FaceRecognizer, which provides a unified access to all face recongition algorithms in OpenCV.
public class LBPHFaceRecognizer : FaceRecognizer, IDisposable
- Inheritance
-
LBPHFaceRecognizer
- Implements
- Inherited Members
Methods
- Create(int, int, int, int, double)
The Circular Local Binary Patterns (used in training and prediction) expect the data given as grayscale images, use cvtColor to convert between the color spaces. This model supports updating.
- GetGridX()
Gets the number of cells in the horizontal direction used to build the Circular Local Binary Pattern.
- GetGridY()
Gets the number of cells in the vertical direction used to build the Circular Local Binary Pattern.
- GetHistograms()
Gets the Local Binary Patterns histograms calculated from the given training data (empty if none was given).
- GetLabels()
Gets the labels corresponding to the calculated Local Binary Patterns histograms.
- GetNeighbors()
Gets the number of sample points used to build the Circular Local Binary Pattern.
- GetRadius()
Gets the radius used for building the Circular Local Binary Pattern.
- GetThreshold()
Gets the threshold applied in the prediction. If the distance to the nearest neighbor is larger than the threshold, the prediction returns -1.
- SetGridX(int)
Sets the number of cells in the horizontal direction used to build the Circular Local Binary Pattern.
- SetGridY(int)
Sets the number of cells in the vertical direction used to build the Circular Local Binary Pattern.
- SetNeighbors(int)
Sets the number of sample points used to build the Circular Local Binary Pattern. An appropriate value is 8; keep in mind that including more sample points increases the computational cost.
- SetRadius(int)
Sets the radius used for building the Circular Local Binary Pattern. The greater the radius, the smoother the image but more spatial information you can get.
- SetThreshold(double)
Sets the threshold applied in the prediction. If the distance to the nearest neighbor is larger than the threshold, the prediction returns -1.