FaceRecognition - Docker

This demo demonstrates face recognition and face liveness detection by mitigating biometric fraud on Linux server in python language.

Overview

This project demonstrates an advanced face recognition technology implemented via a Dockerized Flask API.

It stands for face recognition docker, facial recognition docker, face liveness check docker, spoofing prevention docker, face matching docker, face comparison docker, face search engine docker, face identification docker on Linux server.

SDK

Github

dockerhub

Test Online

Postman

To test the API, you can use Postman. Here are the endpoints for testing:

How to Run

1. System Requirements

CPU: 2 cores or more (Recommended: 8 cores)

RAM: 4 GB or more (Recommended: 8 GB)

HDD: 4 GB or more (Recommended: 8 GB)

OS: Ubuntu 20.04 or later

Dependency: OpenVINO™ Runtime (Version: 2022.3)

2. Setup and Test

  • Clone the project:

git clone https://github.com/kby-ai/FaceRecognition-Docker.git
  • Download the model from Google Drive and unzip it: click here

cd FaceRecognition-Docker

wget --load-cookies /tmp/cookies.txt "https://docs.google.com/uc?export=download&confirm=$(wget --quiet --save-cookies /tmp/cookies.txt --keep-session-cookies --no-check-certificate 'https://docs.google.com/uc?export=download&id=19vA7ZOlo19BcW8v4iCoCGahUEbgKCo48' -O- | sed -rn 's/.*confirm=([0-9A-Za-z_]+).*/\1\n/p')&id=19vA7ZOlo19BcW8v4iCoCGahUEbgKCo48" -O data.zip && rm -rf /tmp/cookies.txt

unzip data.zip
  • Build the Docker image:

sudo docker build --pull --rm -f Dockerfile -t kby-ai-face:latest .
  • Run the Docker container:

sudo docker run -v ./license.txt:/home/openvino/kby-ai-face/license.txt -p 8081:8080 kby-ai-face
  • Send us the machine code and replace the license.txt file you received. Then, run the Docker container again.

3. Execute the Gradio demo

  • Setup Gradio

Ensure that you have the necessary dependencies installed. Gradio requires Python 3.6 or above. You can install Gradio using pip by running the following command:

pip install gradio
  • Run the demo by using the following command:

cd gradio
python demo.py

Last updated