![]() |
digiKam Developer Documentation
Professional Photo Management with the Power of Open Source
|
Public Types | |
enum | Classifier { SVM = 0 , OpenCV_KNN , Tree , DB } |
Public Member Functions | |
OpenCVDNNFaceRecognizer (Classifier method, FaceScanSettings::FaceRecognitionModel recModel) | |
OpenCVDNNFaceRecognizer:Master class to control entire recognition using OpenFace algorithm. | |
void | clearTraining (const QList< int > &idsToClear) |
Clear specified trained data. | |
QVector< int > | recognize (const QList< QPair< QImage *, QString > > &inputImages) |
Try to recognize a list of given images. | |
int | recognize (const QPair< QImage *, QString > &inputImage) |
Try to recognize the given image. | |
bool | registerTrainingData (const cv::Mat &preprocessedImage, int label) |
register training data for unit test. | |
bool | remove (const QString &hash) |
Returns a cvMat of the extracted features from the cvinputImage, optimized for recognition. | |
void | setNbNeighbors (int k) |
Set K parameter of K-Nearest neighbors algorithm. | |
void | setThreshold (int threshold) |
Set maximum square distance of 2 vectors. | |
void | train (const QList< QPair< QImage *, QString > > &images, const int label) |
Register faces corresponding to an identity. | |
int | verifyTestData (const cv::Mat &preprocessedImage) |
predict label of test data for unit test. | |
Enumerator | |
---|---|
SVM | Support Vector Machines (https://docs.opencv.org/4.x/dc/dd6/ml_intro.html#ml_intro_svm) |
OpenCV_KNN | K-Nearest Neighbors (https://docs.opencv.org/4.x/dc/dd6/ml_intro.html#ml_intro_knn) |
Tree | K-Nearest Neighbors Tree (https://en.wikipedia.org/wiki/K-nearest_neighbors_algorithm) |
DB | Closest Neighbors Tree from the database. |
QVector< int > Digikam::OpenCVDNNFaceRecognizer::recognize | ( | const QList< QPair< QImage *, QString > > & | inputImages | ) |
Returns a list of identity ids. If an identity cannot be recognized, returns -1.
int Digikam::OpenCVDNNFaceRecognizer::recognize | ( | const QPair< QImage *, QString > & | inputImage | ) |
Returns the identity id. If the identity cannot be recognized, returns -1. TODO: verify workflow to economize this routine.