ofekhta1 / Face-Server

0 stars 0 forks source link

Facial Analysis and Comparison Engine (FACE)

Description

This project involves the usage of flask to serve the UI and the insightface library in order to recognize faces and calculate similarity. Additionally it incorporates the usage of a family classifier to calculate the probability for two provided faces to be of relatives.

Features

Installation

Prerequisites

Before you begin, ensure you have the following installed:

Windows

you may need additional dependencies such as:

Option 1 - Script

First, you'll need to install some Prerequisites

pip install gdown gitpython

Run as administrator if using powershell on windows you can use the script in here to automatically clone both frontend and server repositories, setup all requirements with virtual enviornments and download the onnx models

Option 2 - Manual

Clone the Repository


git clone https://github.com/ofekhta1/Face-Server.git

cd  Face-Server

Set Up Virtual Environment (Optional but Recommended)

Setting up a virtual environment is recommended to keep your dependencies isolated.


# Create a virtual environment

python3 -m venv venv

# Activate the virtual environment

# On Windows, use: venv\Scripts\activate

# On macOS and Linux, use: source venv/bin/activate

Install Dependencies


pip install -r requirements.txt

Run the Application


# Set the FLASK_APP environment variable

# On Windows, use: set FLASK_APP=app.py

# On macOS and Linux, use: export FLASK_APP=app.py

# Enable debug mode (optional, recommended for development)

# On Windows, use: set FLASK_ENV=development

# On macOS and Linux, use: export FLASK_ENV=development

python3 app.py

Visit http://localhost:5057 in your web browser to access the application.

Option 3 - Docker Container

Coming soon!