Geodesics of learned representations

Olivier J. Hénaff, Eero P. Simoncelli

TL;DR

This paper introduces a novel method using "representational geodesics" to visualize and diagnose the invariance properties of learned image representations. They demonstrate that standard deep networks fail to adequately linearize basic geometric transformations, but propose a simple modification (replacing max-pooling with L2-pooling) that significantly improves these invariances, leading to more robust representations.

What Problem Does This Paper Address?

Understanding what learned representations actually capture is a major challenge in deep learning. While networks like VGG achieve impressive performance, it's unclear if their learned invariances (e.g., to translation, rotation) truly align with human perception or are simply artifacts of the training process. Existing methods for testing invariances often fall short: synthesis tests can reveal excessive invariance (e.g., Fourier magnitudes are invariant to phase shifts, leading to nonsensical images), but don't easily reveal insufficient invariance. The authors aim to bridge this gap by developing a diagnostic tool that can reveal both too much and too little invariance, providing a more nuanced understanding of representation properties.

Methods

The core contribution is the concept of a representational geodesic. Given two images, the authors synthesize a sequence of intermediate images that lie on a "straightest" path in the representation space of a neural network. This path is found by minimizing the distance between consecutive representations in the network's output space. To ensure this path is also visually meaningful, they further constrain it to be a minimal-length path in the image space itself (a conditional geodesic).

The process involves:

  1. Initialization: Linearly interpolating images between the start and end points.
  2. Representational Geodesic Optimization: Minimizing the sum of squared differences between consecutive representations in the network's output. This is done using the Adam optimizer.
  3. Image-Domain Geodesic Optimization: Further refining the path to minimize the sum of squared differences between consecutive images, while staying close to the representational geodesic. This involves projecting gradients to ensure the path remains a valid representational geodesic.

This method is used to test how well a representation "linearizes" a transformation. If a representation linearizes a transformation (like translation), then applying that transformation to an image should result in a straight line in the representation space. The synthesized geodesic should then closely follow the original transformation's path.

Datasets

The paper uses standard image datasets implicitly through the VGG network, which is trained on ImageNet. For evaluation, they use pairs of images that are parametrically transformed (translation, rotation, dilation) and also extract sequences from a natural movie ("Melancholia"). No new benchmarks are introduced; rather, the method is applied to existing network architectures.

Key Insights and Ideas

  • Geodesics as a Diagnostic Tool: Representational geodesics offer a powerful way to visualize and quantify the invariances of a learned representation. They reveal how transformations are "untangled" or "linearized" by the network.
  • Max-Pooling's Downside: The standard VGG network, using max-pooling, fails to linearize basic geometric transformations. The authors attribute this to the subsampling nature of max-pooling, which can lead to aliasing artifacts and insufficient invariance.
  • L2-Pooling as a Solution: Replacing max-pooling with L2-pooling (a smooth, quadratic pooling operator) significantly improves the representation's ability to linearize transformations. This suggests that smooth pooling mechanisms are crucial for building robust invariances.
  • Complexity vs. Receptive Field: The paper investigates whether deeper representations are better due to increased complexity or larger receptive fields. They find that even when receptive field sizes are matched, deeper layers with more complex non-linearities produce better geodesics, indicating that representation complexity plays a key role.
  • Hierarchical Representations and Temporal Aliasing: The geodesic framework can be extended hierarchically, potentially addressing issues like temporal aliasing in video sequences by applying constraints at each layer.

Key Results

  • The original VGG network (with max-pooling) produces geodesics that significantly deviate from the ground truth for translations, rotations, and dilations, showing aliasing artifacts.
  • Modifying the VGG network to use L2-pooling instead of max-pooling results in geodesics that closely follow the ground truth transformations, demonstrating successful linearization.
  • Experiments with shallower layers of the VGG network, even when their receptive fields were artificially enlarged to match deeper layers, still showed poorer linearization compared to deeper layers. This highlights the importance of representation depth and complexity.
  • The L2-pooled VGG network generates a smooth geodesic for a natural movie sequence, closely matching the temporal evolution, unlike a simple pixel-intensity interpolation.

Limitations and Future Work

  • Non-convexity: The optimization problem for finding geodesics is non-convex, meaning the algorithm might find local minima. While they use Adam to mitigate this, it's not guaranteed to find the global optimum.
  • Computational Cost: Synthesizing geodesics can be computationally intensive, especially for high-dimensional representations or long sequences.
  • Future Work:
    • Applying the method to other network architectures and tasks.
  • Developing more efficient optimization algorithms.
  • Extending the hierarchical application of geodesics to better handle complex natural transformations and temporal aliasing.
  • Using the method to guide the design of new network architectures for improved invariance.
  • Investigating the "untangling hypothesis" more rigorously by testing if linear decoders can effectively extract object identity from these linearized representations.

Summary updated

Abstract

We develop a new method for visualizing and refining the invariances of learned representations. Specifically, we test for a general form of invariance, linearization, in which the action of a transformation is confined to a low-dimensional subspace. Given two reference images (typically, differing by some transformation), we synthesize a sequence of images lying on a path between them that is of minimal length in the space of the representation (a "representational geodesic"). If the transformation relating the two reference images is linearized by the representation, this sequence should follow the gradual evolution of this transformation. We use this method to assess the invariance properties of a state-of-the-art image classification network and find that geodesics generated for image pairs differing by translation, rotation, and dilation do not evolve according to their associated transformations. Our method also suggests a remedy for these failures, and following this prescription, we show that the modified representation is able to linearize a variety of geometric image transformations.
BibTeX
@inproceedings{henaff2016geodesics,
  author = {Olivier J. Hénaff and Eero P. Simoncelli},
  title = {{Geodesics of learned representations}},
  booktitle = {International Conference on Learning Representations},
  year = {2016},
  url = {http://arxiv.org/abs/1511.06394},
}
Figure