Deep transfer metric learning

Junlin Hu, Jiwen Lu, Yap-Peng TanCVPR 2015

Abstract

Deep Transfer Metric Learning (DTML) addresses the challenge of dataset shift in computer vision by learning a nonlinear distance metric that generalizes across domains. By integrating deep neural networks with distribution alignment via Maximum Mean Discrepancy (MMD), the proposed framework transfers discriminative knowledge from labeled source data to unlabeled target data. Experimental results on face verification and person re-identification demonstrate that DTML and its deeply supervised variant (DSTML) significantly outperform traditional linear and non-transfer deep metric learning methods.

Introduction

In computer vision, metric learning aims to learn a similarity function that calculates the "distance" between images to determine if they represent the same entity. Traditional algorithms often assume that training and test data share the same distribution. However, real-world variations in lighting, camera angles, and backgrounds—known as "dataset shift"—frequently violate this assumption, causing standard models to fail. Furthermore, linear methods often struggle to capture the complex, nonlinear relationships inherent in high-dimensional image data.

Proposed Methodology

The authors introduce two nested frameworks to overcome these limitations: Deep Transfer Metric Learning (DTML) and Deeply Supervised Transfer Metric Learning (DSTML).

Deep Transfer Metric Learning (DTML)

DTML utilizes a deep neural network to learn a hierarchy of nonlinear transformations. The training objective is twofold:

  1. Discriminative Metric Learning: The network employs a Marginal Fisher Analysis criterion to ensure intra-class compactness (bringing images of the same person closer) and inter-class separability (pushing different identities apart).
  2. Domain Alignment: To bridge the gap between source and target domains, Maximum Mean Discrepancy (MMD) is used as a constraint at the top layer. This minimizes the divergence between source and target data distributions, aligning them in a shared feature space.
Overview of the DTML framework aligning source and target domains into a shared subspace.

Deeply Supervised Transfer Metric Learning (DSTML)

To mitigate the "vanishing gradient" problem and better exploit discriminative information, DSTML introduces deep supervision. In addition to the final output layer, hidden layers are optimized using an auxiliary objective function (hinge loss). This ensures that intermediate representations also contribute to the discriminative power of the model.

Experimental Setup

The proposed methods were evaluated on two primary tasks:

  • Face Verification: Using WDRef (Wide and Deep Reference) as the source domain and LFW (Labeled Faces in the Wild) as the target domain.
  • Person Re-identification: Testing across four diverse datasets (VIPeR, i-LIDS, CAVIAR, and 3DPeS) in cross-camera scenarios where the model is trained on one dataset and tested on another.

Results and Analysis

The experiments yielded several key insights:

  • Nonlinearity and Alignment: The transition from shallow to deep architectures provided a significant performance boost. Explicitly minimizing distribution divergence via MMD consistently improved accuracy by 1% to 1.7% on the LFW dataset compared to models without transfer learning.
  • Effectiveness of Deep Supervision: DSTML outperformed standard DTML, achieving 87.32% accuracy on LFW versus 85.58%. This confirms that supervising intermediate layers helps the network learn more robust features.
ROC curves on the LFW dataset comparing DSTML, DTML, and DTML without transfer.

In person re-identification tasks, DSTML consistently outperformed baseline metrics and state-of-the-art deep metric learning methods like DDML. For instance, on the 3DPeS dataset, DSTML achieved a Rank-1 accuracy of 32.53%.

Conclusion

DTML and DSTML provide a robust framework for cross-domain metric learning. By combining deep nonlinear feature extraction with explicit distribution alignment, these methods effectively handle dataset shift. Future work may address the computational overhead of MMD constraints and explore semi-supervised settings where limited labeled target data is available to further refine domain alignment.

Summary updated

BibTeX
@inproceedings{hu2015deep,
  author = {Junlin Hu and Jiwen Lu and Yap-Peng Tan},
  title = {{Deep transfer metric learning}},
  booktitle = {IEEE/CVF Conference on Computer Vision and Pattern Recognition},
  year = {2015},
  doi = {10.1109/cvpr.2015.7298629},
}
Figure