Neural Fourier Transform: A General Approach to Equivariant Representation Learning

Masanori Koyama, Kenji Fukumizu, Kohei Hayashi, Takeru Miyato

Symmetry is everywhere in machine learning, from the translational invariance of CNNs to the rotational equivariance needed for molecular modeling. However, most current methods require us to know exactly how a group (like rotations or shifts) acts on our data beforehand. But what if the action is hidden, implicit, or messy and nonlinear?

TL;DR

The Neural Fourier Transform (NFT) is a novel framework that learns to map complex, nonlinearly transformed data into a latent space where group actions become simple linear transformations. By extending classical Fourier analysis to an autoencoder setting, NFT can discover and disentangle hidden symmetries in data—such as 3D rotations or warped time series—without requiring explicit knowledge of the observation process.

What Problem Does This Paper Address?

Traditional equivariant representation learning relies on a major assumption: we know the group action. For example, in a standard CNN, we know that shifting an image means shifting pixels.

However, real-world data is rarely that clean. Consider an image sequence captured through a fisheye lens or 2D renderings of a rotating 3D object. In these cases, the "action" (shifting or rotating) is not a simple linear operation in pixel space; it's a complex, nonlinear deformation.

Figure 1: Left: An image sequence produced by applying fisheye transformation after horizontal shifting. Right: 2D renderings of a spinning chair.

Standard Fourier Transforms (FT) and Group Convolutions (GC) struggle here because they assume the group acts linearly on the input units. The authors propose NFT to bridge this gap, allowing models to learn these hidden, nonlinear equivariance relations directly from data.

Methods

The NFT framework uses an autoencoder-style architecture to "linearize" the data. It consists of three main components:

  1. Encoder ($\Phi$): Maps the input data $x$ to a latent space.
  2. Linear Action ($M(g)$): In the latent space, the group action $g$ is represented by a linear map (a matrix multiplication).
  3. Decoder ($\Psi$): Maps the transformed latent representation back to the original data space.
The NFT framework pipeline

The goal is to satisfy the relation $\Phi(g \circ x) = M(g)\Phi(x)$. The authors further decompose the latent space into irreducible representations (essentially different "frequency" blocks), mirroring how a classical Fourier Transform decomposes a signal into different sine and cosine frequencies.

The paper explores three scenarios based on how much we know about the group:

  • Unsupervised (U-NFT): Neither the group nor the specific action is known. The model learns everything from sequences of data.
  • G-supervised (G-NFT): The group (e.g., "rotations") is known, but the specific amount of rotation for each sample is unknown.
  • g-supervised (g-NFT): Both the group and the specific action (e.g., "rotated by 30 degrees") are known.

Datasets

The authors evaluated NFT across several domains:

  • 1D Time-Warped Signals: Synthetic signals where shifts are applied after a nonlinear time-warping transformation ($t \mapsto t^3$).
  • Rotated MNIST Variants: Standard MNIST, plus out-of-domain (OOD) tests on rotated Fashion-MNIST and Kuzushiji-MNIST.
  • 3D Object Renderings: 2D images of objects from the ModelNet10-SO3, BRDFs, and ABO-Material datasets, where the group action is 3D rotation in $SO(3)$.

Key Insights and Ideas

  • Theoretical Foundation: The authors prove that finding a linear equivariant feature is mathematically equivalent to the existence of a group-invariant kernel on the data space. This provides a solid theoretical footing for why NFT works.
  • Data-Dependent Filtering: Unlike a standard FT that uses fixed frequencies, NFT acts as a "nonlinear Fourier filter." It automatically selects the frequencies (irreducible representations) that are most dominant in describing the symmetry present in the specific dataset.
  • Latent Linearization: NFT successfully moves the "heavy lifting" of dealing with nonlinearities (like fisheye distortion) into the encoder and decoder, leaving the core symmetry to be handled by simple, interpretable linear algebra in the latent space.

Key Results

  • Frequency Recovery: In 1D experiments, NFT successfully recovered the true underlying frequencies of warped signals where classical DFT failed completely. NFT recovers true frequencies from nonlinearly warped signals
  • OOD Generalization: On rotated MNIST, the g-NFT-norm feature (using the norm of frequency components) significantly outperformed standard autoencoders and even specialized models like Steerable CNNs when generalizing to unseen datasets (Fashion-MNIST/KMNIST).
  • 3D Structure from 2D: NFT could accurately predict novel views of 3D objects from a single 2D image. Interestingly, it decomposed the features into meaningful parts: the 0-th frequency captured rotation-invariant features like color, while higher frequencies captured the geometric orientation and shape.
NFT recovers true frequencies from nonlinearly warped signals

Limitations and Future Work

  • Data Requirements: NFT currently requires "tuples" or sequences of data (e.g., two consecutive frames) to observe the transition and learn the action.
  • Scale and Norms: While NFT identifies frequencies, it doesn't yet have a way to identifiably preserve the "norms" or coefficients of those frequencies, as the scale of the encoder is somewhat arbitrary.
  • Optimization: While the theory is robust, the authors note that proving the autoencoder loss will always find the optimal solution remains an open challenge for future research.

Summary updated

BibTeX
@inproceedings{koyama2024neural,
  author = {Masanori Koyama and Kenji Fukumizu and Kohei Hayashi and Takeru Miyato},
  title = {{Neural Fourier Transform: A General Approach to Equivariant Representation Learning}},
  booktitle = {International Conference on Learning Representations},
  year = {2024},
  url = {https://openreview.net/forum?id=eOCvA8iwXH},
}
Figure