The code is released under the GNU General Public License.
This project demonstrates how to calculate Eigenfaces and Fisherfaces used for face recognition on an Android device.
The library uses my other project FaceRecognitionLib in order to calculate the Eigenfaces and Fisherfaces.
A short blog post can be found at the following link: http://blog.tkjelectronics.dk/2017/07/face-recognition-using-eigenfaces-and-fisherfaces.
The reports I wrote together with Jonathan Wang can be found at the following links: Eigenfaces_Report.pdf and Final_Project_Report.pdf.
In order to built this project you need to download and install Android Studio. You will then need to install the Android NDK.
Then clone the repository including the submodule:
git clone --recursive https://github.com/Lauszus/FaceRecognitionApp.git
If you have already cloned the project, then please run the following command in order to initialise the submodule:
git submodule update --init --recursive
The project is relying on the environmental variables OPENCV_ANDROID_SDK
and EIGEN3_DIR
in Android.mk to be set to the path of the OpenCV Android SDK and Eigen3 libraries.
Both can be installed manually like so:
wget https://github.com/opencv/opencv/releases/download/3.2.0/opencv-3.2.0-android-sdk.zip -O opencv-android-sdk.zip
unzip opencv-android-sdk.zip
wget https://bitbucket.org/eigen/eigen/get/3.3.3.zip -O Eigen3.zip
unzip Eigen3.zip
Now simple set the environmental variables:
Linux:
nano ~/.bash_profile
export OPENCV_ANDROID_SDK=/path/to/OpenCV-android-sdk
export EIGEN3_DIR=/path/to/eigen3
echo $OPENCV_ANDROID_SDK $EIGEN3_DIR
Mac:
nano /etc/launchd.conf
setenv OPENCV_ANDROID_SDK /path/to/OpenCV-android-sdk
setenv EIGEN3_DIR /path/to/eigen3
echo $OPENCV_ANDROID_SDK $EIGEN3_DIR
Windows:
setx OPENCV_ANDROID_SDK /path/to/OpenCV-android-sdk
setx EIGEN3_DIR /path/to/eigen3
echo %OPENCV_ANDROID_SDK% %EIGEN3_DIR%
Please note that /path/to/
should be replaced with the actual path to the Eigen and OpenCV Android SDK directories.
For more information send me an email at [email protected].