{"id":17268038,"url":"https://github.com/lauszus/facerecognitionlib","last_synced_at":"2025-06-12T21:36:40.741Z","repository":{"id":143351860,"uuid":"70993400","full_name":"Lauszus/FaceRecognitionLib","owner":"Lauszus","description":"Library for calculating Eigenfaces and Fisherfaces in C++","archived":false,"fork":false,"pushed_at":"2017-07-10T16:49:32.000Z","size":10523,"stargazers_count":72,"open_issues_count":0,"forks_count":35,"subscribers_count":9,"default_branch":"master","last_synced_at":"2025-03-27T22:01:55.558Z","etag":null,"topics":["eigenfaces","face-recognition","fisherfaces"],"latest_commit_sha":null,"homepage":"","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Lauszus.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2016-10-15T14:42:03.000Z","updated_at":"2025-01-21T02:54:04.000Z","dependencies_parsed_at":"2023-06-02T07:00:30.752Z","dependency_job_id":null,"html_url":"https://github.com/Lauszus/FaceRecognitionLib","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Lauszus%2FFaceRecognitionLib","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Lauszus%2FFaceRecognitionLib/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Lauszus%2FFaceRecognitionLib/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Lauszus%2FFaceRecognitionLib/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Lauszus","download_url":"https://codeload.github.com/Lauszus/FaceRecognitionLib/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248844216,"owners_count":21170534,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["eigenfaces","face-recognition","fisherfaces"],"created_at":"2024-10-15T08:12:18.484Z","updated_at":"2025-04-14T08:22:48.846Z","avatar_url":"https://github.com/Lauszus.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Face Recognition Library\n#### Developed by Kristian Lauszus, 2016\n\nThe code is released under the GNU General Public License.\n_________\n\nThis library can be used in order to calculate [Eigenfaces](http://www.face-rec.org/algorithms/PCA/jcn.pdf) and [Fisherfaces](https://cseweb.ucsd.edu/classes/wi14/cse152-a/fisherface-pami97.pdf) in C++.\n\nThis Eigenfaces are calculated efficiently as described in the [paper](http://www.face-rec.org/algorithms/PCA/jcn.pdf) by M. Turk and A. Pentland.\n\nThe [Eigenfaces.m](Eigenfaces.m) Matlab script was used for development and was then ported to C++.\n\nIf you want to convert the PGM image run the [convert_pgm.sh](convert_pgm.sh) script.\n\n## Documentation\n\nSome information can be found in the [Eigenfaces_Report.pdf](Eigenfaces_Report.pdf).\n\nThe [final project report](Final_Project_Report.pdf) describing Fisherfaces and the [Android application](#android-application) is available as well.\n\nA short blog post can be found at the following link: \u003chttp://blog.tkjelectronics.dk/2017/07/face-recognition-using-eigenfaces-and-fisherfaces\u003e.\n\nThe source is documentated using [Doxygen](http://www.stack.nl/~dimitri/doxygen). The documentation can be found at the following link: \u003chttp://lauszus.github.io/FaceRecognitionLib\u003e.\n\n## AT\u0026T Facedatabase\n\nWhen using the code with the [AT\u0026T Facedatabase](http://www.cl.cam.ac.uk/research/dtg/attarchive/facedatabase.html) the output looks like this:\n\n#### Eigenfaces:\n\n\u003cimg src=\"img/eigenfaces_att.png\" width=300/\u003e \u003cimg src=\"img/matches_eigenfaces_att.png\" width=300/\u003e\n\n#### Fisherfaces:\n\n\u003cimg src=\"img/fisherfaces_att.png\" width=300/\u003e \u003cimg src=\"img/matches_fisherfaces_att.png\" width=300/\u003e\n\nNotice how the Eigenfaces is only slightly worse compared to Fisherfaces.\n\n## Yale Face Database\n\nHowever when using the [Yale Face Database](http://vision.ucsd.edu/content/yale-face-database) the difference is significant:\n\n#### Eigenfaces:\n\n\u003cimg src=\"img/eigenfaces_yale.png\" width=300/\u003e \u003cimg src=\"img/matches_eigenfaces_yale.png\" width=300/\u003e\n\n#### Fisherfaces:\n\n\u003cimg src=\"img/fisherfaces_yale.png\" width=300/\u003e \u003cimg src=\"img/matches_fisherfaces_yale.png\" width=300/\u003e\n\nThis clearly shows the weakness of Eigenfaces, as it only maximizes the scatter between classes and thus end up matching all images with light coming from the left side.\n\nNote you need to prepare the Yale Face Database by running the [convert_yalefaces.sh](convert_yalefaces.sh) script first.\n\n## Android application\n\nThis library was used for an [Android application](https://github.com/Lauszus/FaceRecognitionApp). Some screenshots can be seen below:\n\n\u003ca href=\"https://github.com/Lauszus/FaceRecognitionApp\"\u003e\u003cimg src=\"https://github.com/Lauszus/FaceRecognitionApp/raw/master/face_detected_kristian.png\" width=250/\u003e\u003cimg src=\"https://github.com/Lauszus/FaceRecognitionApp/raw/master/face_detected_jon.png\" width=250/\u003e\u003cimg src=\"https://github.com/Lauszus/FaceRecognitionApp/raw/master/navigation_menu.png\" width= 250/\u003e\u003c/a\u003e\n\n## Build instructions\n\nIn order to build the C++ code and run the script you need to install [Eigen3](http://eigen.tuxfamily.org) and [ImageMagick](http://www.imagemagick.org):\n\nMac:\n\n```bash\nbrew install eigen imagemagick\n```\n\nUbuntu:\n\n```bash\nsudo apt-get install libeigen3-dev imagemagick\n```\n\nThe [RedSVD](https://github.com/ntessore/redsvd-h) library is included as a submodule.\n\nFor more information send me an email at \u003clauszus@gmail.com\u003e.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flauszus%2Ffacerecognitionlib","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flauszus%2Ffacerecognitionlib","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flauszus%2Ffacerecognitionlib/lists"}