This repository refer to 3DDFA and DECA.
3DDFA use 40 shape parameter and 10 expression parameter. In order to improve the reconstruction accuracy, this repository try to use 199 shape parameter and 29 expression parameter. but the result don't seem to improve much. (dataset:300W_LP, net: mobilenet_v1)
DECA has better result in close eye and the outline of the mouth. this repository just extract the 3d facial landmark detection code.
- Python 3.7 (numpy, skimage, scipy, opencv)
- PyTorch >= 1.6 (pytorch3d)
You can runThen follow the instruction to install pytorch3d.pip install -r requirements.txt
- Download config(3DDFA) and model
- config file Google Cloud
- related model Google Cloud
- Run demos
3DDFA
python detect_landmark_bfm.py video/demo.mp4
DECA
python detect_landmark_flame.py video/demo.mp4
facial landmark face-alignment
The code is available for non-commercial scientific research purposes.
We use the FLAME.py from FLAME_PyTorch