Skip to content

Re-implementation of triplet loss function used in FaceNet and DeepFace

Notifications You must be signed in to change notification settings

SummerTrains/triplet

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Triplet

This is the re-implementation of triplet loss function used in Google's FaceNet paper and VGG's DeepFace paper.

Dataset

I use FaceScrub as traning dataset, you should modify sampledata.py to fit your dataset.

Setup

Rebuild your caffe directory:

cd $CAFFEROOT$
cp Makefile.configexample Makefile.config

Remember to uncomment the line to makesure your python layers could be found:

WITH_PYTHON_LAYER := 1

Then build caffe and pycaffe:

make all -j8 & make pycaffe

Usage

  1. Modify sampledata.py, config.py and train.py to fit your dataset and working environment.

  2. Pre-train your model with softmax loss.

  3. Train triplet model based on your pre-trained model.

  4. Learn to adjust parameters.

About

Re-implementation of triplet loss function used in FaceNet and DeepFace

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%