go-face

go-face implements face recognition for Go using dlib, a popular machine learning toolkit.
Requirements
To compile go-face you need to have dlib (>= 19.10) and libjpeg development packages installed.
Ubuntu 16.04, Ubuntu 18.04
You may use dlib PPA which contains latest dlib package compiled with Intel MKL support:
sudo add-apt-repository ppa:kagamih/dlib
sudo apt-get update
sudo apt-get install libdlib-dev libjpeg-turbo8-dev
Ubuntu 18.10+, Debian sid
Latest versions of Ubuntu and Debian provide suitable dlib package so just run:
# Ubuntu
sudo apt-get install libdlib-dev libblas-dev liblapack-dev libjpeg-turbo8-dev
# Debian
sudo apt-get install libdlib-dev libblas-dev liblapack-dev libjpeg62-turbo-dev
Unfortunately libdlib-dev doesn't contain pkgconfig metadata file so create one
in /usr/local/lib/pkgconfig/dlib-1.pc
with the following content:
libdir=/usr/lib/x86_64-linux-gnu
includedir=/usr/include
Name: dlib
Description: Numerical and networking C++ library
Version: 19.10.0
Libs: -L${libdir} -ldlib -lblas -llapack
Cflags: -I${includedir}
Requires:
Other systems
Try to install dlib/libjpeg with package manager of your distribution or compile from sources. Note that go-face won't work with old packages of dlib such as libdlib18.
Or create issue with the name of your system and someone might help you with the installation process.
Models
Currently shape_predictor_5_face_landmarks.dat
and
dlib_face_recognition_resnet_model_v1.dat
are required. You may download them
from dlib-models repo.
Usage
Test
To fetch test data and run tests:
make test
License
CC0.