This project serves an anti-spoofing detection API built using FastAPI. It analyzes facial images and predicts whether they are Real or Spoof using a set of trained models.
[Docker](https://www.docker.com/products/docker-desktop) installed
# Clone the repository
git clone https://github.com/sense-opensource/sense-liveness-checks.git
# Navigate into the project directory
cd sense-liveness-checks
The anti spoof model file is not included in the repository. You must download the model file manually or programmatically and place it in the appropriate folder.
Download the model file from the below link:
https://github.com/sense-opensource/sense-liveness-checks/releases/download/v1.0.0/efficientnet-b7.onnx this file needs to be placed inside the resources/deepfake/ folder
Ensure the model is saved in: resources/deepfake/efficientnet-b7.onnx
pip install -r requirements.txt
uvicorn app:app --reload
This will start the API server on: http://localhost:3016
docker build -t sense_liveness_opensource_image .
docker run -d --name sense_liveness_opensource_container -p 3016:3016 sense_liveness_opensource_image
This will start the API server on: http://localhost:3016
cd front-end
npm install
npm run dev
By default, the frontend runs on : http://localhost:3010
docker stop sense_liveness_opensource_container
docker rm -f sense_liveness_opensource_container
docker rmi -f sense_liveness_opensource_image
docker logs anti_spoof_container
MIT License — free to use, share, and modify