- argparse
pip install argparse
- Keras
pip install keras
- opencv-python
pip install opencv-python
- opencv-contrib-python
pip install opencv-contrib-python
- Numpy
pip install numpy
- facenet-pytorch
pip install facenet-pytorch
- Clone this repository
$ git clone https://github.com/aiis-research/Face-detection
- Run the demo:
image input
$ python detect_demo.py --image data/image/image.jpg
video input
$ python detect_demo.py --video data/video/video.mp4
webcam
$ python detect_demo.py --src 0
We use pre-trained model trained by FER2013 dataset(See here). The dataset consists of visual data of facial expression labeled with 7 emotion categories.
We used MTCNN(See here) as a facial recognition model to detect emotions.
In order to inference the model, we used pre-trained model XCEPTION(See here) developed by Google(2017).
sample image output:
sample video output:
-
Tim Esler's facenet-pytorch repo: https://github.com/timesler/facenet-pytorch
-
Octavio Arriaga's pre-trained model repo: https://github.com/oarriaga/face_classification
-
K. Zhang, Z. Zhang, Z. Li and Y. Qiao. Joint Face Detection and Alignment Using Multitask Cascaded Convolutional Networks, IEEE Signal Processing Letters, 2016. PDF
-
F. Chollet. Xception: Deep Learning with Depthwise Separable Convolutions, 2017. PDF