Top AI Repos — open-source AI, indexed and scored
Top AI Repos tracks AI repositories on GitHub and answers two different questions about each one: is it moving right now, and would you bet a product on it.
Top AI Repos tracks AI repositories on GitHub and answers two different questions about each one: is it moving right now, and would you bet a product on it.
RetinaFace: Deep Face Detection Library for Python
| Date | Stars |
|---|---|
| 2026-07-24 | 2018 |
| 2026-07-25 | 2019 |
| 2026-07-28 | 2019 |
| 2026-07-30 | 2019 |
| 2026-08-06 | 2019 |
Today
— stars today
This week
— stars this week
This month
— stars this month
Momentum
0.0
growth rate 0.00%/day
# RetinaFace
<div align="center">
[](https://pepy.tech/project/retina-face)
[](https://github.com/serengil/retinaface/stargazers)
[](https://github.com/serengil/retinaface/blob/master/LICENSE)
[](https://doi.org/10.35378/gujs.1794891)
</div>
RetinaFace is a deep learning based cutting-edge facial detector for Python coming with facial landmarks. Its detection performance is amazing even in the crowd as shown in the following illustration.
RetinaFace is the face detection module of [insightface](https://github.com/deepinsight/insightface) project. The original implementation is mainly based on mxnet. Then, its tensorflow based [re-implementation](https://github.com/StanislasBertrand/RetinaFace-tf2) is published by [Stanislas Bertrand](https://github.com/StanislasBertrand). So, this repo is heavily inspired from the study of Stanislas Bertrand. Its source code is simplified and it is transformed to pip compatible but the main structure of the reference model and its pre-trained weights are same.
<p align="center"><img src="https://raw.githubusercontent.com/serengil/retinaface/master/tests/outputs/img3.jpg" width="90%">
<br><em>The Yellow Angels - Fenerbahce Women's Volleyball Team</em>
</p>
## Installation [](https://pypi.org/project/retina-face/)
The easiest way to install retinaface is to download it from [PyPI](https://pypi.org/project/retina-face/). It's going to install the library itself and its prerequisites as well.
```shell
$ pip install retina-face
```
Then, you will be able to import the library and use its functionalities.
```python
from retinaface import RetinaFace
```
**Face Detection** - [`Demo`](https://youtu.be/Wm1DucuQk70)
RetinaFace offers a face detection function. It expects an exact path of an image as input.
```python
resp = RetinaFace.detect_faces("img1.jpg")
```
Then, it will return the facial area coordinates and some landmarks (eyes, nose and mouth) with a confidence score.
```json
{
"face_1": {
"score": 0.9993440508842468,
"facial_area": [155, 81, 434, 443],
"landmarks": {
"right_eye": [257.82974, 209.64787],
"left_eye": [374.93427, 251.78687],
"nose": [303.4773, 299.91144],
"mouth_right": [228.37329, 338.73193],
"mouth_left": [320.21982, 374.58798]
}
}
}
```
**Alignment** - [`Tutorial`](https://sefiks.com/2020/02/23/face-alignment-for-face-recognition-in-python-within-opencv/), [`Demo`](https://youtu.be/WA9i68g4meI)
A modern face recognition [pipeline](https://sefiks.com/2020/05/01/a-gentle-introduction-to-face-recognition-in-deep-learning/) consists of 4 common stages: detect, [align](https://sefiks.com/2020/02/23/face-alignment-for-face-recognition-in-python-within-opencv/), [normalize](https://sefiks.com/2020/11/20/facial-landmarks-for-face-recognition-with-dlib/), [represent](https://sefiks.com/2020/12/14/deep-face-recognition-with-arcface-in-keras-and-python/) and [verify](https://sefiks.com/2020/05/22/fine-tuning-the-threshold-in-face-recognition/). Experiments show that alignment increases the face recognition accuracy almost 1%. Here, retinaface can find the facial landmarks including eye coordinates. In this way, it can apply alignment to detected faces with its extracting faces function.
```python
import matplotlib.pyplot as plt
faces = RetinaFace.extract_faces(img_path = "img.jpg", align = True)
for face in faces:
plt.imshow(face)
plt.show()
```
<p align="center"><img src="https://raw.githubusercontent.com/serenExcerpt of 8,017 characters
Read on GitHubSefik Ilkin Serengil · @Neo4j · United Kingdom
198
10
7
Tobias Hermann · Germany
4
2
1
1
1
1
Jay Carlson · No Operation Partners
1
Pierre Moulon @ Meta · Meta
1
Erwann Millon · Krea AI · United States
1
Guspan Tanadi
1
Would you bet a product on this? Bounded 0–100 and slow moving.
matched fp:eaeddf69f1347529, topic:face-recognition, readme:face recognition
matched fp:eaeddf69f1347529, topic:tensorflow