从零开始学习OpenCV。
GitHub地址为 https://github.com/ZHOUYI-UM/OpenCV4.5.1-step-by-step,欢迎各位大佬打星支持。
For more detail, please refer to this URL[Win10 环境下搭建 Qt5.13.2 + OpenCV4.5.1 + MinGW 开发环境] (https://blog.csdn.net/justidle/article/details/121488711)。
In this project, we will open a picture and show this picture in QMainWindow. Using QtCreator 4.10.1 to generate a “Qt Widgets Application”, use the default selection, But in “Kit Selection”, please use “MinGW 64-bit” not use “MSVC2017 64bit”.
In this project, we will use opencv to face and eyes detection. Using haarcascade_frontalface_alt.xml to do face detection. Using haarcascade_eye_tree_eyeglasses.xml to do eyes detection. This to files are provided by OpenCV, you can get it in the direction “sources/data/haarcascades”.
In this project, get vedio from camera.
In this project, using a 100ms timer to detect face from vedio.
In this project, we detect a face in vedio, and save this pic every 500ms.
In this project, we will use python to train the face image. Because python is simplier than C++.
In this project, we will use the at.txt, which is generated in project 6, to make a face data. We will open a face image, and push “Face data” button, We will generate EigenFaceRecognizer, FisherFaceRecognizer and LBPHFaceRecognizer from at.txt. Then press load image to load a 92*112 gray image to recognize the face.
In this project, we will use the face data, which is generated in poject 7, to make a face recognization from a camera. It seems that the correction using FisherFaceRecognizer is a little low.
目前使用 OpenCV 最基本的人脸识别,即 EigenFaceRecognizer, FisherFaceRecognizer 和 LBPHFaceRecognizer,简单测试后,发现人脸识别的准确率没有资料中说明那么高。
可能问题是自己对 OpenCV 了解还不够,还需要进一步阅读文档。
使用 OpenCV 中的 DNN 来识别人脸。