NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Notes on the Symmetries of 2-Layer ReLU-Networks

Henning Petzka, Martin Trimmel, Cristian Sminchisescu

Abstract

In deep learning, the mapping from weight space to function space is often many-to-one. This redundancy is driven by equioutput transformations—symmetries that leave a network's output unchanged despite changes in its internal parameters. While these symmetries are well-documented for smooth activation functions, the Rectified Linear Unit (ReLU) presents unique challenges. This paper provides a complete mathematical characterization of symmetries in two-layer ReLU networks and explores the emergence of more complex, non-degenerate symmetries in deeper architectures.

Introduction

If two identical neural networks are trained on the same dataset, they will likely converge to different weight configurations while potentially representing the exact same mathematical function. Understanding these symmetries is not merely a theoretical exercise; it has profound implications for optimization, interpretability, and network compression.

Symmetries create "flat" manifolds in the loss landscape, meaning global minima are rarely isolated points. Furthermore, properties like "flatness" or "generalization" must be invariant under these transformations to be well-defined. While symmetries for odd activation functions (e.g., $\tanh$) were solved decades ago, the non-linear and non-odd nature of ReLU requires a new algebraic framework to map its redundancies.

Methodology

This study employs a formal algebraic approach to analyze fully-connected ReLU networks. A network is defined as irreducible if it contains no "useless" neurons (zero weights) and no redundant neurons (scaled versions of one another). The core of the analysis focuses on activation patterns—the specific regions of the input space where neurons are active.

A central tool in this analysis is the exploitation of a fundamental ReLU identity: $$(x)_+ = x + (-x)_+$$ This identity suggests that a neuron can "flip" its activation region if the network compensates by adding a linear term to the output. This leads to the discovery of a novel transformation, $\psi^J_-$, which complements the traditional permutation and scaling symmetries.

The Symmetries of 2-Layer Networks

For a two-layer ReLU network, the authors prove that there are exactly three ways to modify weights without altering the output function:

  1. Permutation ($\pi$): Reordering neurons within a hidden layer.
  2. Scaling ($\rho_\lambda$): Multiplying a neuron's incoming weights by $\lambda > 0$ and its outgoing weights by $1/\lambda$.
  3. The Linear Flip ($\psi^J_-$): Reversing the sign of a neuron's input weights and adjusting the output weights to compensate for the resulting linear term.
A degenerate 2-layer ReLU network where the output f(x,y) is identically zero due to linear function compensation.

However, the "Linear Flip" is only possible in degenerate cases. In a standard, non-degenerate network, no subset of neurons can sum to a constant or a linear function that cancels out. Consequently, most practical 2-layer networks are only symmetric under permutation and scaling. Figure 1 illustrates a degenerate case where multiple neurons cancel each other out to produce a zero output, demonstrating the functional redundancy possible through linear compensation.

Beyond Two Layers: Deep Network Symmetries

While the 2-layer case is largely constrained by degeneracy, deeper networks harbor a richer landscape of symmetries. In architectures with three or more layers, neurons in later stages may only receive inputs from the "positive quadrant" of the preceding layer.

This allows for neurons to remain in an "always active" regime, where they behave linearly. In these scenarios, the authors demonstrate the existence of continuous symmetries involving invertible matrix transformations (replacing weights $A$ with $BA$ and $C$ with $CB^{-1}$) that are not degenerate. These symmetries do not exist in shallow networks and suggest that the loss landscapes of deep networks are fundamentally different from their 2-layer counterparts.

Conclusion and Future Work

This work provides the first complete characterization of symmetries for 2-layer ReLU networks, identifying the "Linear Flip" as a key theoretical boundary between degenerate and non-degenerate models. While the 2-layer case is now mathematically mapped, the full characterization of $L$-layer networks remains an open challenge.

Future research is needed to determine how these symmetries interact with modern training heuristics like Adam or Batch Normalization. Additionally, while deep symmetries exist theoretically, standard weight initializations (such as He initialization) may naturally avoid the "always active" regimes where these complex symmetries reside, suggesting a gap between theoretical possibility and practical training dynamics.

Summary updated

BibTeX
@inproceedings{petzka2020notes,
  author = {Henning Petzka and Martin Trimmel and Cristian Sminchisescu},
  title = {{Notes on the Symmetries of 2-Layer ReLU-Networks}},
  booktitle = {NLDL},
  year = {2020},
  doi = {10.7557/18.5150},
}
Figure