Git Product home page Git Product logo

face_verification_api's Introduction

Keras Face Verification System deployed as Flask REST API

What

A POST request can be used to integrate face verification in your system.

POST Request Format

  • Add
curl -X POST -F [email protected] 'http://localhost:5000/add?name=sachin'
  • Verify
curl -X POST -F [email protected] 'http://localhost:5000/verify?name=sachin'

API Flow Diagram

image

Here name should be unique to the person like emailid or something and image should be the image file containing the person's face.

How to RUN

CMD

pip install -r requirements.txt
python app.py

Docker

docker build -t face_api:latest .
docker run -dp 5000:5000 face_api
curl -X GET http://0.0.0.0:5000/

Pre-built docker image at docker pull ravip18597/face-api:v1

Kubernetes

kubectl apply -f ./deployment.yaml
minikube servive face-api

Output Response

Verify

  • First
{
	"code":1,
	"message":"Person is verified correctly",
	"score":"0.8051153"
}
  • Second
{
	"code":0,
	"message":"Person is not verified",
	"score":"1.051153"
}
  • Third
{
    "code": -3,
    "message": "Name does not exist in database"
}
  • Fourth
{
	"code":-1,
	"message":"No frontal face detected on picture"
}
  • Fifth
{
	"code":-2,
	"message":"Model could not be loaded"
}

Score is the value of the similarity of the face with the registered face. Lower the value of score , means more similarity

ADD

  • First
{
	"code":1,
	"message":"Face added to the database",
}
  • Second
{
	"code":-1,
	"message":"No frontal face detected",
}

face_verification_api's People

Contributors

ravip18596 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

face_verification_api's Issues

Error installing requirements

Hi I was going through your repo while researching face recognition. I couldn't run the repo.

I got this error :-
ERROR: Could not find a version that satisfies the requirement opencv_python==3.4.1.15 (from -r requirements.txt (line 6)) (from versions: 3.4.8.29, 3.4.9.31, 3.4.9.33, 3.4.10.35, 4.1.2.30, 4.2.0.32, 4.2.0.34, 4.3.0.36)
ERROR: No matching distribution found for opencv_python==3.4.1.15 (from -r requirements.txt (line 6))

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.