What Makes Data Suitable for a Locally Connected Neural Network? A Necessary and Sufficient Condition Based on Quantum Entanglement.

Yotam Alexander, Nimrod De La Vega, Noam Razin, Nadav Cohen

Why do Convolutional Neural Networks (CNNs) excel at image recognition but often struggle with tabular data? Historically, we've relied on the intuition that images possess a "local nature"—pixels near each other are inherently related. However, "local nature" remains a fuzzy, informal concept. A recent NeurIPS paper from Tel Aviv University provides a rigorous mathematical answer by borrowing a surprising tool from quantum physics: Quantum Entanglement.

The Core Discovery

The paper proves that a locally connected neural network (such as a CNN, RNN, or local self-attention model) can accurately model a data distribution if and only if that data exhibits low "quantum entanglement" across specific feature partitions.

Beyond establishing this theoretical baseline, the authors leverage this insight to develop a practical preprocessing algorithm. By rearranging data features to minimize entanglement, they significantly boost model performance on "unstructured" or tabular datasets.

The Missing "Litmus Test" for Neural Networks

Deep learning is notoriously picky. It works wonders on "natural" data like images, audio, and text, but frequently fails on distributions where features are shuffled or lack clear spatial relationships.

While empirical evidence abounds regarding which architectures suit specific data types, the field has lacked a formal mathematical "litmus test." Until now, there hasn't been a necessary and sufficient condition to guarantee that a specific network architecture is capable of learning a given data distribution. The authors aim to fill this gap specifically for locally connected neural networks, a broad family encompassing CNNs, Recurrent Neural Networks (RNNs), and local self-attention models.

Methods: Physics Meets Machine Learning

The researchers bridge the gap between machine learning and physics using two key pillars:

  1. Tensor Networks: In quantum physics, complex multi-particle systems are described using tensors, and computational models for these systems are called "tensor networks." The authors demonstrate that locally connected neural networks are mathematically equivalent to a specific type of tensor network characterized by a tree-like hierarchical structure.
Tree Tensor Network Structure
  1. Quantum Entanglement Entropy: In physics, entanglement measures how much one part of a system depends on another. The authors apply this concept to data. If you split input features into two sets (e.g., the left half of an image versus the right half), the "entanglement" of the data distribution quantifies how much information is shared between those halves.

The Theoretical Breakthrough: The authors prove that for a network to successfully fit a data distribution, the distribution must admit low entanglement under "canonical partitions"—essentially, contiguous blocks of features that align with the network's hierarchical structure.

The Practical Algorithm: Because calculating true quantum entanglement is computationally intractable for large datasets, the authors utilize Multivariate Pearson Correlation as a practical surrogate. They frame the task of "making data suitable for a neural network" as a feature-rearrangement problem: finding a permutation of features that minimizes correlation across partitions. They solve this using a "minimum balanced cut" graph algorithm.

Key Insights and Results

The authors validated their theory and algorithm across several modalities, including 1D audio (Speech Commands), 2D images (CIFAR-10), and standard tabular benchmarks (semeion, isolet, dna).

  • Locality is Quantifiable: The "local nature" of data is not just an intuitive feeling; it is the absence of complex, long-range dependencies. Low entanglement entropy serves as the formal mathematical language for "locality."
  • The Architecture is a Filter: A locally connected neural network acts as a bottleneck that can only "see" low-entanglement patterns. If data has high entanglement (like a scrambled image), the information literally cannot flow through the network's structure to produce an accurate prediction.
  • The Inverse Correlation: The authors demonstrated a striking inverse relationship: artificially increasing the number of random feature swaps in a dataset raises its average entanglement, causing the test accuracy of CNNs, modern RNNs (S4), and local attention models to drop precipitously.
  • Fixing Tabular Data: By applying their rearrangement algorithm to tabular data—where feature order is usually arbitrary—they achieved significant performance gains. On the "dna" dataset, a CNN’s accuracy jumped from 82.5% to 91.2% simply by reordering the features prior to training.
  • Scalability: The preprocessing method was successfully applied to audio data with 50,000 features, proving it is not just a theoretical toy but a scalable tool for high-dimensional real-world data.

Limitations and Future Work

While groundbreaking, the work has boundaries:

  • Non-Linearity Gaps: The theoretical proof relies on networks with polynomial non-linearities. While empirical results hold for standard ReLU networks, a formal proof for ReLU remains an open challenge.
  • Beyond Locality: The current theory doesn't fully account for "global" architectures like standard Transformers (global self-attention) or ResNets with extensive skip-connections, which might support higher entanglement.
  • Generalization vs. Expressiveness: The paper focuses primarily on expressiveness (whether the network can represent the solution) rather than generalization (whether it will learn the right solution from limited samples), though the authors suspect low entanglement is key to both.

Ultimately, this research suggests that the future of AutoML might involve a heavy dose of physics—analyzing the "quantum" structure of our data before we even select an architecture.

Summary updated

BibTeX
@inproceedings{alexander2023what,
  author = {Yotam Alexander and Nimrod De La Vega and Noam Razin and Nadav Cohen},
  title = {{What Makes Data Suitable for a Locally Connected Neural Network? A Necessary and Sufficient Condition Based on Quantum Entanglement.}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2023},
  url = {https://openreview.net/forum?id=4aIpgq1nuI},
}
Figure