I am working on a face recognition project using OpenCV FaceRecognizer, making gender differentiation. The algorithm works very well, but I wanted to implement some additional functions in my program, such as confidence in prediction.
The prediction function can output a confidence level, but I'm not sure what that means. What really measures this confidence, and can I convert it to percent?
int predictedLabel = -1; double confidence = 0.0; model->predict(face_resized, predictedLabel, confidence); string result_message = format("Predicted class = %d / Confidence = %d.", predictedLabel, confidence); cout << result_message << endl;
This is what the output looks like. https://www.dropbox.com/s/65h1n5180ulz3hl/facerecConfidence%20.jpg
hammerhands
source share