@Namespace(value="cv::face") @Properties(inherit=opencv_face.class) public class LBPHFaceRecognizer extends FaceRecognizer
Pointer.CustomDeallocator, Pointer.Deallocator, Pointer.NativeDeallocator, Pointer.ReferenceCounter| Constructor and Description | 
|---|
LBPHFaceRecognizer(Algorithm pointer)
Downcast constructor. 
 | 
LBPHFaceRecognizer(Pointer p)
Pointer cast constructor. 
 | 
| Modifier and Type | Method and Description | 
|---|---|
static LBPHFaceRecognizer | 
create()  | 
static LBPHFaceRecognizer | 
create(int radius,
      int neighbors,
      int grid_x,
      int grid_y,
      double threshold)  | 
int | 
getGridX()  | 
int | 
getGridY()  | 
MatVector | 
getHistograms()  | 
Mat | 
getLabels()  | 
int | 
getNeighbors()  | 
int | 
getRadius()  | 
double | 
getThreshold()
\brief threshold parameter accessor - required for default BestMinDist collector 
 | 
void | 
setGridX(int val)
\copybrief getGridX @see getGridX 
 | 
void | 
setGridY(int val)
\copybrief getGridY @see getGridY 
 | 
void | 
setNeighbors(int val)
\copybrief getNeighbors @see getNeighbors 
 | 
void | 
setRadius(int val)
\copybrief getRadius @see getRadius 
 | 
void | 
setThreshold(double val)
\copybrief getThreshold @see getThreshold 
 | 
asAlgorithm, asAlgorithm, empty, getLabelInfo, getLabelsByString, getLabelsByString, predict_collect, predict_collect, predict_collect, predict_label, predict_label, predict_label, predict, predict, predict, predict, predict, predict, predict, predict, predict, read, read, read, setLabelInfo, setLabelInfo, train, train, train, train, train, train, train, train, train, update, update, update, update, update, update, update, update, update, write, write, writeclear, getDefaultName, getPointer, position, save, save, write, writeaddress, asBuffer, asByteBuffer, availablePhysicalBytes, calloc, capacity, capacity, close, deallocate, deallocate, deallocateReferences, deallocator, deallocator, equals, fill, formatBytes, free, getDirectBufferAddress, getPointer, getPointer, getPointer, hashCode, interruptDeallocatorThread, isNull, isNull, limit, limit, malloc, maxBytes, maxPhysicalBytes, memchr, memcmp, memcpy, memmove, memset, offsetAddress, offsetof, offsetof, parseBytes, physicalBytes, physicalBytesInaccurate, position, put, realloc, referenceCount, releaseReference, retainReference, setNull, sizeof, sizeof, toString, totalBytes, totalCount, totalPhysicalBytes, withDeallocator, zeropublic LBPHFaceRecognizer(Pointer p)
Pointer(Pointer).public LBPHFaceRecognizer(Algorithm pointer)
public int getGridX()
setGridXpublic void setGridX(int val)
public int getGridY()
setGridYpublic void setGridY(int val)
public int getRadius()
setRadiuspublic void setRadius(int val)
public int getNeighbors()
setNeighborspublic void setNeighbors(int val)
public double getThreshold()
FaceRecognizergetThreshold in class FaceRecognizersetThresholdpublic void setThreshold(double val)
setThreshold in class FaceRecognizer@opencv_core.Ptr public static LBPHFaceRecognizer create(int radius, int neighbors, int grid_x, int grid_y, double threshold)
radius - 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.neighbors - The number of sample points to build a Circular Local Binary Pattern from. An
    appropriate value is to use 8 sample points. Keep in mind: the more sample points you include,
    the higher the computational cost.grid_x - The number of cells in the horizontal direction, 8 is a common value used in
    publications. The more cells, the finer the grid, the higher the dimensionality of the resulting
    feature vector.grid_y - The number of cells in the vertical direction, 8 is a common value used in
    publications. The more cells, the finer the grid, the higher the dimensionality of the resulting
    feature vector.threshold - The threshold applied in the prediction. If the distance to the nearest neighbor
    is larger than the threshold, this method returns -1.
    ### Notes:
- 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.
### Model internal data:
- radius see LBPHFaceRecognizer::create. - neighbors see LBPHFaceRecognizer::create. - grid_x see LLBPHFaceRecognizer::create. - grid_y see LBPHFaceRecognizer::create. - threshold see LBPHFaceRecognizer::create. - histograms Local Binary Patterns Histograms calculated from the given training data (empty if none was given). - labels Labels corresponding to the calculated Local Binary Patterns Histograms.
@opencv_core.Ptr public static LBPHFaceRecognizer create()
Copyright © 2025. All rights reserved.