OpenCV

How to do face recognition in OpenCV and how to improve it by aligning faces

After a long time here I come with some great news. In my semestral project for computer vision I worked on application which can improve face recognition by rotating faces so they align with training set. Without further adue here it comes: Face recognition consists of these steps: Create training set for face recognition Load training set for face recognition Train faces and create model Capture/load image where you want to recognize people Find face/s Adjust the image for face recognition (greyscale, crop, resize, rotate …) Use trained model for face recognition Display result This post requires you to have…
Read more

FacePreview on Android with native libraries

Android has its own face recognition and we don’t need OpenCV to find faces on pictures or while shooting with camera. In this example I used FaceDetector to find faces on Bitmap image which I had to create from Raw data. The biggest problem of this solution is the conversion. Since FaceDetector supports RGB_565 and many android cameras support only YUV. I tested this on my Huawei Honor 2 with NV21 bitmap image type. If your device supports other image format feel free to edit code and/or post your conversion function in comments or ask for help if needed. Second…
Read more

How to run JavaCV (with sample face recognition) on Android ARM device – Netbeans and nbandroid

I promised some tutorials so here we go. Here is simple tutorial of how to detect face on Android device using Netbeans IDE with nbandroid, JavaCV wrapper to OpenCV and FFMpeg. Android developers in netbeans skip to step 6 Download and install Netbeans – http://www.netbeans.org/ Download and install nbandroid plugin to netbeans http://nbandroid.org/wiki/index.php/Installation Download Android SDK – http://developer.android.com/sdk/index.html Extract it Run SDK manager Download desired SDK (ARM system image is essential since javacv supports only arm)– I suggest 4.0.3 and update what you can Download drivers for your phone or Create android virtual device Create AVD make sure you select back…
Read more