Face Recognition Project on MXNet
Convolutional neural networks have significantly boosted the performance of face recognition in recent years due to its high capacity in learning discriminative features. To enhance the discriminative power of the Softmax loss, multiplicative angular margin and additive cosine margin incorporate angular margin and cosine margin into the loss functions, respectively. In this paper, we propose a novel supervisor signal, additive angular margin (ArcFace), which has a better geometrical interpretation than supervision signals proposed so far. Specifically, the proposed ArcFace cos(θ + m) directly maximise decision boundary in angular (arc) space based on the L2 normalised weights and features. Compared to multiplicative angular margin cos(mθ) and additive cosine margin cosθ-m, ArcFace can obtain more discriminative deep features. We also emphasise the importance of network settings and data refinement in the problem of deep face recognition. Extensive experiments on several relevant face recognition benchmarks, LFW, CFP and AgeDB, prove the effectiveness of the proposed ArcFace. Most importantly, we get state-of-art performance in the MegaFace Challenge in a totally reproducible way. We make data, models and training/test code public available [https://github.com/deepinsight/insightface].READ FULL TEXT VIEW PDF
Face recognition has achieved revolutionary advancement owing to the
In this paper, we propose a conceptually simple and geometrically
Benefit from large-scale training datasets, deep Convolutional Neural
Chromosome classification is an important but difficult and tedious task...
The margin-based softmax loss functions greatly enhance intra-class
Researches using margin based comparison loss demonstrate the effectiven...
Owe to the rapid development of deep neural network (DNN) techniques and...
Face Recognition Project on MXNet
. The deep convolutional network is responsible for mapping the face image, typically after a pose normalisation step, into an embedding feature vector such that features of the same person have a small distance while features of different individuals have a considerable distance.
The various face recognition approaches by deep convolutional network embedding differ along three primary attributes.
The first attribute is the training data employed to train the model. The identity number of public available training data, such as VGG-Face , VGG2-Face , CAISA-WebFace , UMDFaces , MS-Celeb-1M , and MegaFace , ranges from several thousand to half million. Although MS-Celeb-1M and MegaFace have a significant number of identities, they suffer from annotation noises  and long tail distributions . By comparison, private training data of Google  even has several million identities. As we can check from the latest performance report of Face Recognition Vendor Test (FRVT) , Yitu, a start-up company from China, ranks first based on their private 1.8 billion face images . Due to orders of magnitude difference on the training data scale, face recognition models from industry perform much better than models from academia. The difference of training data also makes some deep face recognition results  not fully reproducible.
The second attribute is the network architecture and settings. High capacity deep convolutional networks, such as ResNet [14, 15, 46, 50, 23] and Inception-ResNet [40, 3], can obtain better performance compared to VGG network [37, 31] and Google Inception V1 network [41, 35]. Different applications of deep face recognition prefer different trade-off between speed and accuracy [16, 51]. For face verification on mobile devices, real-time running speed and compact model size are essential for slick customer experience. For billion level security system, high accuracy is as important as efficiency.
The third attribute is the design of the loss functions.
(1) Euclidean margin based loss.
In  and , a Softmax classification layer is trained over a set of known identities. The feature vector is then taken from an intermediate layer of the network and used to generalise recognition beyond the set of identities used in training. Centre loss  Range loss  and Marginal loss 
add extra penalty to compress intra-variance or enlarge inter-distance to improve the recognition rate, but all of them still combine Softmax to train recognition models. However, the classification-based methods[42, 31] suffer from massive GPU memory consumption on the classification layer when the identity number increases to million level, and prefer balanced and sufficient training data for each identity.
The contrastive loss  and the Triplet loss  utilise pair training strategy. The contrastive loss function consists of positive pairs and negative pairs. The gradients of the loss function pull together positive pairs and push apart negative pairs. Triplet loss minimises the distance between an anchor and a positive sample and maximises the distance between the anchor and a negative sample from a different identity. However, the training procedure of the contrastive loss  and the Triplet loss  is tricky due to the selection of effective training samples.
(2) Angular and cosine margin based loss.
Liu et al.  proposed a large margin Softmax (L-Softmax) by adding multiplicative angular constraints to each identity to improve feature discrimination. SphereFace  applies L-Softmax to deep face recognition with weights normalisation. Due to the non-monotonicity of the cosine function, a piece-wise function is applied in SphereFace to guarantee the monotonicity. During training of SphereFace, Softmax loss is combined to facilitate and ensure the convergence. To overcome the optimisation difficulty of SphereFace, additive cosine margin [44, 43] moves the angular margin into cosine space. The implementation and optimisation of additive cosine margin are much easier than SphereFace. Additive cosine margin is easily reproducible and achieves state-of-the-art performance on MegaFace (TencentAILab_FaceCNN_v1) . Compared to Euclidean margin based loss, angular and cosine margin based loss explicitly adds discriminative constraints on a hypershpere manifold, which intrinsically matches the prior that human face lies on a manifold.
As is well known that the above mentioned three attributes, data, network and loss, have a high-to-low influence on the performance of face recognition models. In this paper, we contribute to improving deep face recognition from all of these three attributes.
Data. We refined the largest public available training data, MS-Celeb-1M , in both automatic and manual way. We have checked the quality of the refined MS1M dataset with the Resnet-27 [14, 50, 10] network and the marginal loss  on the NIST Face Recognition Prize Challenge 222http://nvlpubs.nist.gov/nistpubs/ir/2017/NIST.IR.8197.pdf. We also find that there are hundreds of overlap face images between the MegaFace one million distractors and the FaceScrub dataset, which significantly affects the evaluation results. We manually find these overlap face images from the MegaFace distractors. Both the refinement of training data and test data will be public available.
Network. Taking VGG2  as the training data, we conduct extensive contrast experiments regarding the convolutional network settings and report the verification accuracy on LFW, CFP and AgeDB. The proposed network settings have been confirmed robust under large pose and age variations. We also explore the trade-off between the speed and accuracy based on the most recent network structures.
Loss. We propose a new loss function, additive angular margin (ArcFace), to learn highly discriminative features for robust face recognition. As shown in Figure 1, the proposed loss function directly maximise decision boundary in angular (arc) space based on the L2 normalised weights and features. We show that ArcFace not only has a more clear geometrical interpretation but also outperforms the baseline methods, e.g. multiplicative angular margin  and additive cosine margin [44, 43]. We innovatively explain why ArcFace is better than Softmax, SphereFace  and CosineFace [44, 43] from the view of semi-hard sample distributions.
Performance. The proposed ArcFace achieves state-of-the-art results on the MegaFace Challenge , which is the largest public face benchmark with one million faces for recognition. We make these results totally reproducible with data, trained models and training/test code public available.
The most widely used classification loss function, Softmax loss, is presented as follows:
where denotes the deep feature of the -th samples, belonging to the -th class. The feature dimension is set as in this paper following [46, 50, 23, 43]. denotes the -th column of the weights in the last fully connected layer and is the bias term. The batch size and the class number is and , respectively. Traditional Softmax loss is widely used in deep face recognition [31, 7]. However, the Softmax loss function does not explicitly optimise the features to have higher similarity score for positive pairs and lower similarity score for negative pairs, which leads to a performance gap.
For simplicity, we fix the bias as 
. Then, we transform the target logit as follows:
In the experiments of SphereFace, L2 weight normalisation only improves little on performance.
where . In order to remove this restriction, is substituted by a piece-wise monotonic function . The SphereFace is formulated as:
where ,,, is the integer that controls the size of angular margin. However, during the implementation of SphereFace, Softmax supervision is incorporated to guarantee the convergence of training, and the weight is controlled by a dynamic hyper-parameter . With the additional Softmax loss, in fact is:
where is a additional hyper-parameter to facilitate the training of SphereFace. is set to 1,000 at beginning and decreases to 5 to make the angular space of each class more compact . This additional dynamic hyper-parameter makes the training of SphereFace relatively tricky.
Feature normalisation is widely used for face verification, e.g. L2-normalised Euclidean distance and cosine distance . Parde et al.  observe that the L2-norm of features learned using Softmax loss is informative of the quality of the face. Features for good quality frontal faces have a high L2-norm while blurry faces with extreme pose have low L2-norm. Ranjan et al. 
add the L2-constraint to the feature descriptors and restrict features to lie on a hypersphere of a fixed radius. L2 normalisation on features can be easily implemented using existing deep learning frameworks and significantly boost the performance of face verification. Wanget al.  point out that gradient norm may be extremely large when the feature norm from low-quality face image is very small, which potentially increases the risk of gradient explosion. The advantages of feature normalisation are also revealed in [25, 26, 43, 45] and the feature normalisation is explained from analytic, geometric and experimental perspectives.
As we can see from above works, L2 normalisation on features and weights is an important step for hypersphere metric learning. The intuitive insight behind feature and weight normalisation is to remove the radial variation and push every feature to distribute on a hypersphere manifold.
Following [33, 43, 45, 44], we fix by L2 normalisation and re-scale to , which is the hypersphere radius and the lower bound is give in . In this paper, we use for face recognition experiments [33, 43]. Based on feature and weight normalisation, we can get .
If the feature normalisation is applied to SphereFace, we can get the feature normalised SphareFace, denoted as SphereFace-FNorm
In this paper, we set the cosine margin as [44, 43]. Compared to SphereFace, additive cosine margin (CosineFace) has three advantages: (1) extremely easy to implement without tricky hyper-parameters; (2) more clear and able to converge without the Softmax supervision; (3) obvious performance improvement.
Although the cosine margin in [44, 43] has a one-to-one mapping from the cosine space to the angular space, there is still a difference between these two margins. In fact, the angular margin has a more clear geometric interpretation compared to cosine margin, and the margin in angular space corresponds to the arc distance on the hypersphere manifold.
We add an angular margin within . Since is lower than when , the constraint is more stringent for classification. We define the proposed ArcFace as:
In Figure 2, we illustrate the proposed ArcFace, and the angular margin corresponds to the arc margin. Compared to SphereFace and CosineFace, our method has the best geometric interpretation.
To better understand the process from Softmax to the proposed ArcFace, we give the decision boundaries under binary classification case in Table 1 and Figure 3. Based on the weights and features normalisation, the main difference among these methods is where we put the margin.
To investigate why the face recognition performance can be improved by SphereFace, CosineFace and ArcFace, we analysis the target logit curves and the distributions during training. Here, we use the LResNet34E-IR (refer to Sec. 3.2) network and the refined MS1M dataset (refer to Sec. 3.1).
In Figure 4(a), we plot the target logit curves for Softmax, SphereFace, CosineFace and ArcFace. For SphereFace, the best setting is and , which is similar to the curve with and . However, the implementation of SphereFace requires the to be an integer. When we try the minimum multiplicative margin, and , the training can not converge. Therefore, decreasing the target logit curve slightly from Softmax is able to increase the training difficulty and improve the performance, but decreasing too much may cause the training divergence.
Both CosineFace and ArcFace follow this insight. As we can see from Figure 4(a), CosineFace moves the target logit curve along the negative direction of y-axis, while ArcFace moves the target logit curve along the negative direction of x-axis. Now, we can easily understand the performance improvement from Softmax to CosineFace and ArcFace.
For ArcFace with the margin , the target logit curve is not monotonic decreasing when . In fact, the target logit curve increases when . However, as shown in Figure 4(c), the
has a Gaussian distribution with the centre atand the largest angle below when starting from the randomly initialised network. The increasing interval of ArcFace is almost never reached during training. Therefore, we do not need to deal with this explicitly.
In Figure 4(c), we show the distributions of CosineFace and ArcFace in three phases of training, e.g. start, middle and end. The distribution centres gradually move from to . In Figure 4(a), we find the target logit curve of ArcFace is lower than that of CosineFace between to . Therefore, the proposed ArcFace puts more strict margin penalty compared to CosineFace in this interval. In Figure 4(b)
, we show the target logit converge curves estimated on training batches for Softmax, CosineFace and ArcFace. We can also find that the margin penalty of ArcFace is heavier than that of CosineFace at the beginning, as the red dotted line is lower than the blue dotted line. At the end of training, ArcFace converges better than CosineFace, as the histogram ofis in the left (Figure 4(c)) and the target logit converge curve is higher (Figure 4(b)). From Figure 4(c), we can find that almost all of the s are smaller than at the end of training. The samples beyond this field are the hardest samples as well as the noise samples of the training dataset. Even though CosineFace puts more strict margin penalty when (Figure 4(a)), this field is seldom reached even at the end of training (Figure 4(c)). Therefore, we can also understand why SphereFace can obtain very good performance even with a relatively small margin in this section.
In conclusion, adding too much margin penalty when may cause training divergence, e.g. SphereFace ( and ). Adding margin when can potentially improve the performance, because this section corresponds to the most effective semi-hard negative samples . Adding margin when can not obviously improve the performance, because this section corresponds to the easiest samples. When we go back to Figure 4(a) and rank the curves between , we can understand why the performance can improve from Softmax, SphereFace, CosineFace to ArcFace under their best parameter settings. Note that, and here are the roughly estimated thresholds for easy and hard training samples.
In this paper, we target to obtain state-of-the-art performance on MegaFace Challenge , the largest face identification and verification benchmark, in a totally reproducible way. We take Labelled Faces in the Wild (LFW) , Celebrities in Frontal Profile (CFP) , Age Database (AgeDB)  as the validation datasets, and conduct extensive experiments regarding network settings and loss function designs. The proposed ArcFace achieves state-of-the-art performance on all of these four datasets.
VGG2. VGG2 dataset contains a training set with 8,631 identities (3,141,890 images) and a test set with 500 identities (169,396 images). VGG2 has large variations in pose, age, illumination, ethnicity and profession. Since VGG2 is a high-quality dataset, we use it directly without data refinement.
MS-Celeb-1M. The original MS-Celeb-1M dataset contains about 100k identities with 10 million images. To decrease the noise of MS-Celeb-1M and get a high-quality training data, we rank all face images of each identity by their distances to the identity centre. For a particular identity, the face image whose feature vector is too far from the identity’s feature centre is automatically removed . We further manually check the face images around the threshold of the first automatic step for each identity. Finally, we obtain a dataset which contains 3.8M images of 85k unique identities. To facilitate other researchers to reproduce all of the experiments in this paper, we make the refined MS1M dataset public available within a binary file, but please cite the original paper  and follow the original license  when using this dataset. Our contribution here is only training data refinement, not release.
LFW.  LFW dataset contains web-collected images from different identities, with large variations in pose, expression and illuminations. Following the standard protocol of unrestricted with labelled outside data, we give the verification accuracy on face pairs.
CFP. . CFP dataset consists of 500 subjects, each with 10 frontal and 4 profile images. The evaluation protocol includes frontal-frontal (FF) and frontal-profile (FP) face verification, each having 10 folders with 350 same-person pairs and 350 different-person pairs. In this paper, we only use the most challenging subset, CFP-FP, to report the performance.
AgeDB. [27, 10] AgeDB dataset is an in-the-wild dataset with large variations in pose, expression, illuminations, and age. AgeDB contains images of distinct subjects, such as actors, actresses, writers, scientists, and politicians. Each image is annotated with respect to the identity, age and gender attribute. The minimum and maximum ages are and , respectively. The average age range for each subject is years. There are four groups of test data with different year gaps ( years, years, years and years, respectively) . Each group has ten split of face images, and each split contains positive examples and
negative examples. The face verification evaluation metric is the same as LFW. In this paper, we only use the most challenging subset, AgeDB-30, to report the performance.
MegaFace. MegaFace datasets  are released as the largest public available testing benchmark, which aims at evaluating the performance of face recognition algorithms at the million scale of distractors. MegaFace datasets include gallery set and probe set. The gallery set, a subset of Flickr photos from Yahoo, consists of more than one million images from 690k different individuals. The probe sets are two existing databases: FaceScrub  and FGNet . FaceScrub is a publicly available dataset that containing 100k photos of unique individuals, in which images are males, and images are females. FGNet is a face ageing dataset, with images from identities. Each identity has multiple face images at different ages (ranging from to ).
It is quite understandable that data collection of MegaFace is very arduous and time-consuming thus data noise is inevitable. For FaceScrub dataset, all of the face images from one particular identity should have the same identity. For the one million distractors, there should not be any overlap with the FaceScrub identities. However, we find noisy face images not only exist in FaceScrub dataset but also exist in the one million distractors, which significantly affect the performance.
In Figure 5, we give the noisy face image examples from the Facesrub dataset. As shown in Figure 8(c), we rank all of the faces according to the cosine distance to the identity centre. In fact, face image 221 and 136 are not Aaron Eckhart. We manually clean the FaceScrub dataset and finally find noisy face images. During testing, we change the noisy face to another right face, which can increase the identification accuracy by about . In Figure 6(b), we give the noisy face image examples from the MegaFace distractors. All of the four face images from the MegaFace distractors are Alec Baldwin. We manually clean the MegaFace distractors and finally find noisy face images. During testing, we add one additional feature dimension to distinguish these noisy faces, which can increase the identification accuracy by about .
Even though the noisy face images are double checked by seven annotators who are very familiar with these celebrities, we still can not promise these images are noisy. We put the noise lists of the FaceScrub dataset and the MegaFace distractors online. We believe the masses have sharp eyes and we will update these lists based on other researchers’ feedback.
We first evaluate the face verification performance based on different network settings by using VGG2 as the training data and Softmax as the loss function. All experiments in this paper are implemented by MxNet . We set the batch size as and train models on four or eight NVIDIA Tesla P40 (24GB) GPUs. The learning rate is started from and divided by at the 100k, 140k, 160k iterations. Total iteration step is set as 200k. We set momentum at and weight decay at (Table 5).
Following [46, 23], we use five facial landmarks (eye centres, nose tip and mouth corners)  for similarity transformation to normalise the face images. The faces are cropped and resized to , and each pixel (ranged between ) in RGB images is normalised by subtracting then divided by .
As most of the convolutional networks are designed for the Image-Net  classification task, the input image size is usually set as or larger. However, the size of our face crops is only . To preserve higher feature map resolution, we use and in the first convolutional layer instead of using and . For these two settings, the output size of the convolutional networks is (denoted as “L” in front of the network names) and , respectively.
In last several layers, some different options can be investigated to check how the embedding settings affect the model performance. All feature embedding dimension is set to expect for Option-A, as the embedding size in Option-A is determined by the channel size of last convolutional layer.
During testing, the score is computed by the Cosine Distance of two feature vectors. Nearest neighbour and threshold comparison are used for face identification and verification tasks.
Besides the original ResNet  unit, we also investigate a more advanced residual unit setting  for the training of face recognition model. In Figure 7, we show the improved residual unit (denoted as “IR” in the end of model names), which has a BN-Conv-BN-PReLu-Conv-BN structure. Compared to the residual unit proposed by , we set for the second convolutional layer instead of the first one. In addition, PReLu 
is used to substitute the original ReLu.
Based on recent advances on the model structure designs, we also explore MobileNet , Inception-Resnet-V2 , Densely connected convolutional networks (DenseNet) , Squeeze and excitation networks (SE)  and Dual path Network (DPN)  for deep face recognition. In this paper, we compare the differences between these networks from the aspects of accuracy, speed and model size.
Input selects L. In Table 2, we compare two networks with and without the setting of “L”. When using and as the first convolutional layer, the network output is . By contrast, if we use and as the first convolutional layer, the network output is only . It is obvious from Table 2 that choosing larger feature maps during training obtains higher verification accuracy.
Output selects E. In Table 3, we give the detailed comparison between different output settings. The option E (BN-Dropout-FC-BN) obtains the best performance. In this paper, the dropout parameter is set as . Dropout can effectively act as the regularisation term to avoid over-fitting and obtain better generalisation for deep face recognition.
Block selects IR. In Table 4
, we give the comparison between the original residual unit and the improved residual unit. As we can see from the results, the proposed BN-Conv(stride=1)-BN-PReLu-Conv(stride=2)-BN unit can obviously improve the verification performance.
Backbones Comparisons. In Table 8, we give the verification accuracy, test speed and model size of different backbones. The running time is estimated on the P40 GPU. As the performance on LFW is almost saturated, we focus on the more challenging test sets, CFP-FP and AgeDB-30, to compare these network backbones. The Inception-Resnet-V2 network obtains the best performance with long running time () and largest model size (). By contrast, MobileNet can finish face feature embedding within with a model of , and the performance only drops slightly. As we can see from Table 8, the performance gaps between these large networks, e.g. ResNet-100, Inception-Resnet-V2, DenseNet, DPN and SE-Resnet-100, are relatively small. Based on the trade-off between accuracy, speed and model size, we choose LResNet100E-IR to conduct experiments on the Megaface challenge.
Weight decay. Based on the SE-LResNet50E-IR network, we also explore how the weight decay (WD) value affects the verification performance. As we can see from Table 5, when the weight decay value is set as , the verification accuracy reaches the highest point. Therefore, we fix the weight decay at in all other experiments.
Since the margin parameter plays an important role in the proposed ArcFace, we first conduct experiments to search the best angular margin. By varying from to , we use the LMobileNetE network and the ArcFace loss to train models on the refined MS1M dataset. As illustrated in Table 6, the performance improves consistently from on all datasets and gets saturated at . Then, the verification accuracy turns to decrease from . In this paper, we fix the additive angular margin as .
Based on the LResNet100E-IR network and the refined MS1M dataset, we compare the performance of different loss functions, e.g. Softmax, SphereFace , CosineFace [44, 43] and ArcFace. In Table 7, we give the detailed verification accuracy on the LFW, CFP-FP, and AgeDB-30 datasets. As LFW is almost saturated, the performance improvement is not obvious. We find that (1) Compared to Softmax, SphereFace, CosineFace and ArcFace improve the performance obviously, especially under large pose and age variations. (2) CosineFace and ArcFace obviously outperform SphereFace with much easier implementation. Both CosineFace and ArcFace can converge easily without additional supervision from Softmax. By contrast, additional supervision from Softmax is indispensable for SphereFace to avoid divergence during training. (3) ArcFace is slightly better than CosineFace. However, ArcFace is more intuitive and has a more clear geometric interpretation on the hypersphere manifold as shown in Figure 1.
|SphereFace (m=4, )||99.76||93.7||97.56|
|Backbones||LFW ()||CFP-FP ()||AgeDB-30 ()||Speed(ms)||Model-Size(MB)|
For the experiments on the MegaFace challenge, we use the LResNet100E-IR network and the refined MS1M dataset as the training data. In both Table 9 and 10, we give the identification and verification results on the original MegaFace dataset and the refined MegaFace dataset.
In Table 9, we use the whole refined MS1M dataset to train models. We compare the performance of the proposed ArcFace with related baseline methods, e.g. Softmax, Triplet, SphereFace, and CosineFace. The proposed ArcFace obtains the best performance before and after the distractors refinement. After the overlapped face images are removed from the one million distractors, the identification performance significantly improves. We believe that the results on the manually refined MegaFace dataset are more reliable, and the performance of face identification under million distractors is better than we think .
|Methods||Rank1@||VR@FAR||Rank1@ (R)||VR@FAR (R)|
To strictly follow the evaluation instructions on MegaFace, we need to remove all of the identities appearing in the FaceScrub dataset from our training data. We calculate the feature centre for each identity in the refined MS1M dataset and the FaceScrub dataset. We find that 578 identities from the refined MS1M dataset have a close distance (cosine similarity is higher than) with the identities from the FaceScrub dataset. We remove these 578 identities from the refined MS1M dataset and compare the proposed ArcFace to other baseline methods in Table 10. ArcFace still outperforms CosineFace with a slight performance drop compared to Table 9. But for Softmax, the identification rate drops obviously from to after the suspectable overlap identities are removed from the training data. On the refined MegaFace testset, the verification result of CosineFace is slightly higher than that of ArcFace. This is because we read the verification results which are closest to FAR=1e-6 from the outputs of the devkit. As we can see from Figure 8, the proposed ArcFace always outperforms CosineFace under both identification and verification metric.
|Methods||Rank1@||VR@FAR||Rank1@ (R)||VR@FAR (R)|
Due to the limitation of GPU memory, it is hard to train Softmax-based methods,e.g. SphereFace, CosineFace and ArcFace, with millions of identities. One practical solution is to employ metric learning methods, and the most widely used method is the Triplet loss [35, 22]. However, the converging speed of Triplet loss is relatively slow. To this end, we explore Triplet loss to fine-turn exist face recognition models which are trained with Softmax based methods.
For Triplet loss fine-tuning, we use the LResNet100E-IR network and set learning rate at , momentum at and weight decay at . As shown in Table 11, we give the verification accuracy by Triplet loss fine-tuning on the AgeDB-30 dataset. We find that (1) The Softmax model trained on a dataset with fewer identity numbers (e.g. VGG2 with 8,631 identities) can be obviously improved by Triplet loss fine-tuning on a dataset with more identity numbers (e.g. MS1M with 85k identities). This improvement confirms the effectiveness of the two-step training strategy, and this strategy can significantly accelerate the whole model training compared to training Triplet loss from scratch. (2) The Softmax model can be further improved by Triplet loss fine-tuning on the same dataset, which proves that the local refinement can improve the global model. (3) The excellence of margin improved Softmax methods, e.g. SphereFace, CosineFace, and ArcFace, can be kept and further improved by Triplet loss fine-tuning, which also verifies that local metric learning method, e.g. Triplet loss, is complementary to global hypersphere metric learning based methods.
As the margin used in Triplet loss is the Euclidean distance, we will investigate Triplet loss with the angular margin recently.
In this paper, we contribute to improving deep face recognition from data refinement, network settings and loss function designs. We have (1) refined the largest public available training dataset (MS1M) and test dataset (MegaFace); (2) explored different network settings and analysed the trade-off between accuracy and speed; (3) proposed a geometrically interpretable loss function called ArcFace and explained why the proposed ArcFace is better than Softmax, SphereFace and CosineFace from the view of semi-hard sample distributions; (4) obtained state-of-the-art performance on the MegaFace dataset in a totally reproducible way.
European Conference on Computer Vision, pages 87–102. Springer, 2016.
Delving deep into rectifiers: Surpassing human-level performance on imagenet classification.In Proceedings of the IEEE international conference on computer vision, pages 1026–1034, 2015.
Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, pages 770–778, 2016.
International Conference on Machine Learning, pages 448–456, 2015.
Inception-v4, inception-resnet and the impact of residual connections on learning.In AAAI, pages 4278–4284, 2017.