Learning Aligned Cross-Modal Representations from Weakly Aligned Data

Lluís Castrejón, Yusuf Aytar, Carl Vondrick, Hamed Pirsiavash, Antonio Torralba

Abstract

Humans possess a remarkable ability to recognize scenes across diverse modalities, from natural photographs to abstract sketches or even textual descriptions. This paper investigates the learning of cross-modal scene representations that facilitate transfer across these formats. We introduce CMPlaces, a new cross-modal scene dataset, and propose methods to regularize convolutional neural networks (CNNs) to develop a shared, modality-agnostic representation. Our experiments demonstrate that these aligned representations significantly improve cross-modal retrieval and lead to the emergence of semantic units that activate on consistent concepts regardless of the input modality.

The Challenge of Cross-Modal Alignment

While standard deep learning models excel at categorizing natural images, they are often "modality-bound." A model trained on photos typically fails when presented with a sketch or clip-art version of the same scene because it overfits to low-level visual features like textures and colors.

The fundamental hurdle is alignment. Traditional approaches often rely on "strong alignment"—perfectly paired data (e.g., a specific photo matched with its exact sketch). Such data is scarce and expensive to produce. This research focuses on weak alignment, where modalities are linked only by a shared global category label (e.g., "bedroom"), even if the specific objects and viewpoints differ significantly between examples.

Methodology: Building a Shared Representation

The authors propose a "Scene Network" architecture designed to bridge the gap between modalities. The architecture employs modality-specific early layers to handle unique low-level features (pixels vs. text) while transitioning into shared high-level layers.

The proposed architecture uses modality-specific CNNs that converge into a shared cross-modal representation at the pool5 layer.

To ensure these shared layers learn truly modality-agnostic concepts, three strategies were evaluated:

  1. Modality Tuning: A curriculum-based approach starting with a pre-trained natural-image model (Places-CNN). When introducing a new modality, high-level layers are frozen, forcing the new modality-specific layers to align with existing high-level concepts.
  2. Statistical Regularization: This method enforces similarity in the distribution of activations across modalities. By using activations from the natural-image model as a statistical "prior," the network is penalized if activations for other modalities (like sketches) deviate significantly from this distribution.
  3. Joint Method: Combining both tuning and statistical regularization proved most effective for cross-modal transfer.

The CMPlaces Dataset

To benchmark these methods, the authors introduced CMPlaces, an expansion of the Places database. It spans 205 scene categories across five distinct modalities:

  • Natural Images: 2.5 million photographs.
  • Sketches: 6,644 line drawings.
  • Clip Art: 11,372 stylized images.
  • Spatial Text: 456,300 images where object names are placed in their corresponding spatial locations.
  • Descriptions: 4,307 detailed paragraphs describing scenes.
Examples from the CMPlaces dataset across five modalities for 'Bedroom' and 'Kindergarten classroom' categories.

Key Insights and Results

Emergent Object Detectors

A striking finding is that training on global scene labels causes specific object detectors to emerge in the shared layers. A single neuron might learn to fire for "fountains" whether they appear as pixels in a photo, strokes in a sketch, or words in a description. Human validation confirmed that units in the proposed model were significantly more consistent (33%) across modalities than baseline models (25%).

Cross-Modal Retrieval

The proposed joint regularization method achieved a 14.2 mAP (mean Average Precision) in cross-modal retrieval tasks (e.g., finding a photo given a sketch), more than doubling the performance of standard fine-tuning baselines (~6.4 mAP).

Visualizing the "Mental Image"

By inverting the shared features, the researchers could visualize the network's internal representation. For instance, when the model "reads" a description of a kitchen, the inverted features produce a spatial layout with colors and shapes characteristic of a kitchen, effectively demonstrating a cross-modal "mental image."

Conclusion and Future Work

This work demonstrates that weak alignment is sufficient to learn powerful, modality-agnostic representations. While the gap between text and visual modalities remains challenging and reconstructions are currently low-resolution, the emergence of shared semantic units suggests a promising path toward more robust, human-like scene understanding in AI.

Summary updated

BibTeX
@inproceedings{castrejon2016learning,
  author = {Lluís Castrejón and Yusuf Aytar and Carl Vondrick and Hamed Pirsiavash and Antonio Torralba},
  title = {{Learning Aligned Cross-Modal Representations from Weakly Aligned Data}},
  booktitle = {IEEE/CVF Conference on Computer Vision and Pattern Recognition},
  year = {2016},
  url = {https://openreview.net/forum?id=HJ-_Kp-dZr},
}
Figure