Node.js + face-recognition.js : Simple and Robust Face Recognition using Deep Learning

The npm package for face recognition

Trained to recognize faces of Raj, Sheldon, Lennard and Howard

Why?

So, what is face-recognition.js?

Face Detection

Face Recognition

Face Landmarks

Cool story, let’s finally see it in action!

Preparing the data

['sheldon', 'lennard', 'raj', 'howard', 'stuart'] 

Detecting the faces

Training the Recognizer

Recognizing new faces

{ className: 'sheldon', distance: 0.5 }
[
{ className: 'sheldon', distance: 0.5 },
{ className: 'raj', distance: 0.8 },
{ className: 'howard', distance: 0.7 },
{ className: 'lennard', distance: 0.69 },
{ className: 'stuart', distance: 0.75 }
]

Results

sheldon ( 90.9% ) : 10 of 11 faces have been recognized correctly
lennard ( 100% ) : 12 of 12 faces have been recognized correctly
raj ( 100% ) : 12 of 12 faces have been recognized correctly
howard ( 100% ) : 12 of 12 faces have been recognized correctly
stuart ( 100% ) : 3 of 3 faces have been recognized correctly
sheldon ( 100% ) : 16 of 16 faces have been recognized correctly
lennard ( 88.23% ) : 15 of 17 faces have been recognized correctly
raj ( 100% ) : 17 of 17 faces have been recognized correctly
howard ( 100% ) : 17 of 17 faces have been recognized correctly
stuart ( 87.5% ) : 7 of 8 faces have been recognized correctly

Conclusion