OpenFace
OpenFace is a Python
and Torch implementation of face recognition with deep neural networks and is based on theCVPR 2015 paper FaceNet: A Unified Embedding for Face Recognition and Clustering by Florian Schroff, Dmitry Kalenichenko, and James Philbin at Google.
Dependencies
- OpenCV (for python)
- DLib (for python)
- Torch
- numpy, pandas, scipy, scikit-learn, scikit-image (python dependencies)
- dpnn nn optim csvigo cunn fblualib torchx (Torch dependencies)
# clone repository
$ git clone --recursive https://github.com/cmusatyalab/openface.git
# install the dependencies (Torch)
$ luarocks install dpnn nn optim csvigo cunn fblualib torchx
# install OpenFace
$ cd openface
$ sudo python setup.py install
Test
$ cd models
$ ./get-models.sh
$ cd ..
$ ./run-tests.sh
Demo
$ python ./demos/compare.py images/examples/{lennon*,clapton*}
fix permission
Error
OpenFace: `openface_server.lua` subprocess has died.
$ cd /usr/local/lib/python2.7/dist-packages/openface
$ sudo chmod +r *
FAQ
ImportError: libcudart.so.7.5: cannot open shared object file: No such file or directory
sudo ldconfig /usr/local/cuda/lib64