Cross-modal Deep Metric Learning with Multi-task Regularization

Xin Huang, Yuxin Peng · DOI

Abstract

DNN-based cross-modal retrieval has become a research hotspot, by which users can search results across various modalities like image and text. However, existing methods mainly focus on the pairwise correlation and reconstruction error of labeled data. They ignore the semantically similar and dissimilar constraints between different modalities, and cannot take advantage of unlabeled data. This paper proposes Cross-modal Deep Metric Learning with Multi-task Regularization (CDMLMR), which integrates quadruplet ranking loss and semi-supervised contrastive loss for modeling cross-modal semantic similarity in a unified multi-task learning architecture. The quadruplet ranking loss can model the semantically similar and dissimilar constraints to preserve cross-modal relative similarity ranking information. The semi-supervised contrastive loss is able to maximize the semantic similarity on both labeled and unlabeled data. Compared to the existing methods, CDMLMR exploits not only the similarity ranking information but also unlabeled cross-modal data, and thus boosts cross-modal retrieval accuracy.

The Challenge of Cross-modal Retrieval

Cross-modal retrieval—the ability to search for an image using a text description or vice versa—is a fundamental challenge in multimedia AI. Traditional methods often struggle because they rely on simple linear projections or focus solely on "pairwise" correlations (i.e., "does this specific image match this specific text?").

The authors identify two major gaps in current research:

  1. Ignoring Relative Similarity: Most models don't account for the ranking of similarity. For example, an image of a "husky" should be closer to the text "dog" than to the text "cat," but it should also be closer to "dog" than an image of a "wolf" is to the text "dog."
  2. Wasted Unlabeled Data: Labeled data is expensive and scarce. Most existing deep learning approaches ignore the vast amounts of unlabeled data that could help the model understand the underlying structure of the feature space.

The CDMLMR Framework

The CDMLMR framework addresses these gaps using a two-stage deep learning architecture designed for multi-task learning.

Architecture of the CDMLMR framework, illustrating the base network and the deep metric learning network with multi-task losses.

1. The Base Network

To handle the initial "raw" features of different modalities, the model employs Deep Belief Networks (DBNs) and a Bimodal Autoencoder (AE). This stage compresses images and text into a "shallow" shared representation space where they share the same dimensions.

2. Deep Metric Learning Network

This core innovation consists of two separate pathways (image and text) trained simultaneously using a multi-task objective:

  • Quadruplet Ranking Loss: Unlike standard triplet loss, this uses four samples to ensure that a positive text sample is closer to a positive image than a negative image is, and vice versa. This preserves the relative ranking of semantic similarity.
  • Semi-supervised Contrastive Loss: To leverage unlabeled data, the model builds an online neighborhood graph within each training mini-batch. By calculating $k$-nearest neighbors, the model identifies "similar" pairs even without labels, forcing the model to cluster similar concepts together regardless of whether they are labeled.

Experimental Results

The authors evaluated CDMLMR on two standard benchmarks: the Wikipedia Dataset (2,866 pairs, 10 classes) and NUS-WIDE-10k (10,000 pairs, 10 classes). Performance was measured using Mean Average Precision (MAP).

Comparison of MAP scores for CDMLMR against state-of-the-art methods on Wikipedia and NUS-WIDE-10k datasets.

As shown in the results, CDMLMR consistently outperformed eight state-of-the-art methods, including CCA, JRL, and CMDN. On the Wikipedia dataset, it achieved an average MAP of 0.377, surpassing the previous best of 0.359.

Ablation Success

Ablation studies further confirmed the synergy of the multi-task approach. The full CDMLMR model performed significantly better than versions using only the quadruplet loss or only the semi-supervised loss. For instance, on the NUS-WIDE-10k dataset, the full model (0.392 MAP) significantly outperformed the "Quad-only" version (0.319 MAP), demonstrating that the ranking loss and contrastive loss are complementary.

Conclusion

CDMLMR demonstrates that ranking information and unlabeled data are critical for robust cross-modal retrieval. By combining quadruplet ranking with semi-supervised contrastive learning, the model learns a more discriminative semantic space. Future work will explore extending this framework to handle more than two modalities simultaneously, potentially creating a "universal" semantic space for all media types.

Summary updated

BibTeX
@inproceedings{huang2017cross,
  author = {Xin Huang and Yuxin Peng},
  title = {{Cross-modal Deep Metric Learning with Multi-task Regularization}},
  booktitle = {ICME},
  year = {2017},
  doi = {10.1109/icme.2017.8019340},
}
Figure