Rotation Consistent Margin Loss for Efficient Low-Bit Face Recognition

Yudong Wu, Yichao Wu, Ruihao Gong, Yuanhao Lv, Ken Chen, Ding Liang, Xiaolin Hu, Xianglong Liu, Junjie Yan

Introduction

Deep learning has revolutionized face recognition (FR), but state-of-the-art models are often too computationally expensive for mobile or embedded devices. Network quantization—reducing precision from 32-bit floating point to low-bit integers (e.g., 4-bit or 3-bit)—offers a solution. However, standard quantization techniques that excel in closed-set image classification often fail in open-set face recognition. This paper introduces Rotation Consistent Margin (RCM) loss, a novel training objective designed to maintain high accuracy in low-bit FR models.

The Challenge: Open-Set Quantization

In closed-set tasks like ImageNet classification, a model only needs to distinguish between predefined categories. In contrast, open-set FR requires the model to generalize to identities never seen during training by maintaining a discriminative margin between feature clusters.

Impact of quantization on closed-set vs. open-set tasks and resulting accuracy degradation.

As shown in Figure 4, while 4-bit quantization has a negligible effect on Top-1 classification accuracy, it causes a significant drop in True Positive Rate (TPR) for face recognition. The authors observe that quantization "cracks" the tight clusters of features necessary for identifying individuals, leading to a loss of intra-class compactness.

Rotation Consistent Margin (RCM) Loss

The core innovation is the RCM loss, which addresses the Angular Quantization Error (A-QE). By mapping features to a hypersphere, the authors disentangle quantization noise into two components:

  1. Class Error: A global rotation of an identity's entire feature cluster.
  2. Individual Error: The "jitter" of specific samples within that cluster.

The authors discovered that Class Error is relatively benign because clusters remain separated. However, Individual Error expands the cluster spread, causing overlap between different identities. RCM loss incorporates this individual error directly as an additive angular margin during training. This forces the model to learn features that are inherently robust to the specific rotations caused by low-bit arithmetic.

Key Insights: Compactness vs. Separability

Quantization at low bit-widths does not necessarily reduce the distance between class centers, but it severely impacts intra-class compactness.

Intra-class angle distributions for various bit-widths, demonstrating the loss of compactness at lower precisions.

Figure 6 illustrates how decreasing the bit-width shifts the distribution of intra-class angles. At 4-bits, the distribution becomes significantly wider and shifts toward larger angles compared to full-precision (FP) models. RCM loss mitigates this by training the model to be "rotation consistent," ensuring clusters remain tight even after quantization.

Experimental Results

The RCM loss was evaluated on industry-standard benchmarks including MegaFace, LFW, YTF, and IJB-C.

  • MegaFace (ResNet18): At 4-bits, RCM achieved 88.56% rank-1 accuracy. At 3-bits, the advantage became more pronounced, with RCM reaching 74.34% compared to 67.83% for the standard ArcFace baseline.
  • MobileNetV2: RCM boosted 4-bit accuracy by nearly 3% over the baseline, demonstrating its effectiveness on compact architectures.

Conclusion

By recognizing that quantization error manifests as angular rotation, the RCM loss provides a mathematically grounded way to train robust low-bit face recognition models. This approach allows for significant reductions in memory and computation without the catastrophic performance loss typically associated with ultra-low-bit quantization in open-set tasks.

Summary updated

BibTeX
@inproceedings{wu2020rotation,
  author = {Yudong Wu and Yichao Wu and Ruihao Gong and Yuanhao Lv and Ken Chen and Ding Liang and Xiaolin Hu and Xianglong Liu and Junjie Yan},
  title = {{Rotation Consistent Margin Loss for Efficient Low-Bit Face Recognition}},
  booktitle = {IEEE/CVF Conference on Computer Vision and Pattern Recognition},
  year = {2020},
  doi = {10.1109/cvpr42600.2020.00690},
}
Figure