Adaptive Cross-Modal Embeddings for Image-Text Alignment

Jonatas Wehrmann, Camila Kolling, Rodrigo C. Barros

Abstract

Cross-modal retrieval between images and text traditionally faces a trade-off between simple, fast embedding models and complex, slow attention-based models. We present ADAPT (Adaptive Cross-Modal Embeddings), which uses global features of one modality to dynamically "filter" and "shape" the local features of another. ADAPT achieves significant improvements in retrieval accuracy—notably a 24% relative gain on Flickr30k—while operating up to 25x faster than previous attention-based state-of-the-art models like SCAN.

Introduction

In cross-modal retrieval, the goal is to find the most relevant image for a text query or the best caption for an image. Historically, models have fallen into two camps: simple embedding models that are fast but lack granularity, and attention-based models that are accurate but computationally heavy due to exhaustive word-region comparisons. ADAPT introduces a "third way" that captures fine-grained correlations through global-to-local guidance, maintaining the speed of simpler methods while exceeding the accuracy of complex ones.

Methodology

The core of the ADAPT framework is a modality-guided filtering process. Instead of word-by-word attention, ADAPT utilizes a global summary of one modality to modulate the local features of the other.

Feature Adaptation

A global vector from the guiding modality is used to predict scaling ($\gamma$) and shifting ($\beta$) parameters. These parameters are applied to the intermediate features of the target modality, highlighting relevant information and suppressing noise.

The Fovea Module

Following adaptation, the Fovea Module applies a channel-wise attention mask using a smoothed Softmax. This allows the model to "zero in" on the most important spatial regions in images or time-steps in text. Ablation studies indicate that the Fovea module is critical, contributing a 4-5% boost to Recall@1.

The ADAPT architecture overview, illustrating the flow from feature extraction (Faster R-CNN/Bi-GRU) through the adaptation and Fovea modules to the final similarity score.

Experimental Results

ADAPT was evaluated on the Flickr30k and MS COCO benchmarks. On Flickr30k, the ADAPT ensemble achieved a Recall@1 of 60.7% for Image Retrieval, a substantial improvement over the previous state-of-the-art (48.6%). Similar gains were observed on MS COCO.

Efficiency and Scalability

A key advantage of ADAPT is its computational efficiency. Because adaptation relies on simple linear projections, the overhead is minimal. As shown in the figure below, even ADAPT models with small latent dimensions (128 or 256) outperform previous state-of-the-art results while remaining significantly faster. Overall, ADAPT provides a 25x speedup over attention-based models when constructing similarity matrices for retrieval.

Performance comparison of ADAPT across different latent sizes (128 to 1024) showing Recall@1 versus inference time. ADAPT consistently outperforms previous state-of-the-art results (dashed line) with superior efficiency.

Conclusion

ADAPT demonstrates that global-to-local guidance is a highly effective strategy for cross-modal alignment. By dynamically shaping features based on context, it achieves state-of-the-art performance with production-ready efficiency. Future research may extend this adaptive mechanism to video-text retrieval and end-to-end visual feature learning.

Summary updated

BibTeX
@inproceedings{wehrmann2020adaptive,
  author = {Jonatas Wehrmann and Camila Kolling and Rodrigo C. Barros},
  title = {{Adaptive Cross-Modal Embeddings for Image-Text Alignment}},
  booktitle = {AAAI Conference on Artificial Intelligence},
  year = {2020},
  doi = {10.1609/aaai.v34i07.6915},
}
Figure