https://github.com/quantivio/face_characters_detection
A simple Face detection API made with Python, Flask, and Deepface capable of detecting emotion, race, gender, and ethnicity.
https://github.com/quantivio/face_characters_detection
deepface face-detection-api python3
Last synced: 5 months ago
JSON representation
A simple Face detection API made with Python, Flask, and Deepface capable of detecting emotion, race, gender, and ethnicity.
- Host: GitHub
- URL: https://github.com/quantivio/face_characters_detection
- Owner: Quantivio
- Created: 2020-11-24T08:32:37.000Z (almost 5 years ago)
- Default Branch: main
- Last Pushed: 2023-05-15T20:17:05.000Z (over 2 years ago)
- Last Synced: 2024-05-02T04:10:33.491Z (over 1 year ago)
- Topics: deepface, face-detection-api, python3
- Language: Python
- Homepage:
- Size: 255 KB
- Stars: 2
- Watchers: 1
- Forks: 2
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Face Detection API
A simple face detection API made with Python Flask and FastAPI, using the Deepface library.
## Tech Stack
- Python
- Flask
- Deepface## Dependencies
- Deepface: https://github.com/serengil/deepface
## Running the API
1. Clone the repository
2. Install the dependencies with Poetry:
- Install Poetry
with `curl -sSL https://raw.githubusercontent.com/python-poetry/poetry/master/get-poetry.py | python`
or `pip install poetry`
- Install the packages with `poetry install`
- Start a poetry shell with `poetry shell`
3. Start the Flask development server with `flask run`
4. Start the FastAPI development server with `uvicorn fast_app:app`## Installing Deepface on MacOS or Troubleshooting
If you encounter any errors during installation, try the following steps:
1. Remove the `pyproject.toml` and `poetry.lock` files
2. For MacOS with M1, run:
- `poetry add tensorflow-macos tensorflow-Metal fastapi flask pillow`
3. Start a Poetry shell with `poetry shell`
4. Install Deepface without dependencies by running `pip install deepface --no-deps`## Note
Before running the API, make sure to check that you have all the required dependencies installed and configured
correctly.