Skip to content

valmarath/face-recognition-javascript

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

41 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Face Recognition - JavaScript

NodeJS Next JS Postgres Docker

This project was developed with the purpose of exploring facial recognition methods using JavaScript. Although this topic is widely covered in languages like Python, it's interesting to implement this process using a different technology than usual.

When I developed this project, I wanted to understand what a minimal implementation of facial recognition would look like. For this, I used Node.js for creating the APIs, Next.js for the user interface, and Postgres (with the pgvector extension) as the database. To generate the image embeddings, instead of training my own model and implementing it, I used the Human library .

If you want to start understanding how facial recognition works, I recommend reading this article.

Table of Contents

Features

  • Registers a new user with a username, password, and face data.
  • User login with face recognition, based on username + face data.
  • Identify a user through face recognition, without any information besides face data.

Prerequisites

Before installing, ensure you have the following installed on your system:

  • Docker: You can download and install Docker from here.

Installation

  1. Clone the repository:
git clone https://github.com/valmarath/face-recognition-javascript.git
  1. Build the application
docker-compose build --no-cache
  1. Run the application and tests
docker-compose up -d

Usage

  1. The user interface will be accessible at http://localhost:3000
  2. The API will be accessible at http://localhost:5001
  3. The API documentation will be accessible at http://localhost:5001/api-docs

Limitations

This project was, above all, an experiment. Therefore, the implementation and architecture are not ready for real-world use. Specifically, using facial recognition for login in a web application could introduce several security vulnerabilities, so caution should be exercised before considering its implementation.

The frontend is quite simple, given that I just wanted to have one to make it easier for people to test the functionalities (myself included). However, the main goal of this project was exploratory, and it should be treated as such.

About

face-recognition login application using node.js

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published