Optimizing Neural Networks in the Equivalent Class Space

Qi Meng, Wei Chen, Shuxin Zheng, Qiwei Ye, Tie-Yan Liu

Abstract

ReLU neural networks are positively scale-invariant, yet standard optimization algorithms like SGD operate in a weight space that lacks this property. This mismatch can hinder optimization. We propose $\mathcal{G}$-SGD, an algorithm that optimizes in a scale-invariant "$\mathcal{G}$-space" of path values. By identifying basis paths and leveraging an Inverse-Chain-Rule, $\mathcal{G}$-SGD achieves superior performance on benchmark datasets with minimal computational overhead.

The Weight Space Trap

In ReLU networks, multiplying incoming weights to a neuron by a scalar and dividing outgoing weights by the same scalar leaves the network's output unchanged. This positive scale-invariance creates a redundancy: many different weight configurations represent the same mathematical function. Standard Stochastic Gradient Descent (SGD) ignores this symmetry, navigating a weight space that is $H$ dimensions larger than necessary (where $H$ is the number of hidden units). This redundancy often leads to a rugged optimization landscape, slowing down convergence.

Methods: Moving to $\mathcal{G}$-space

To resolve this, we propose moving the optimization from the raw weight space to the $\mathcal{G}$-space, a vector space defined by path values.

  1. Path Values and Basis Paths: A path value is the product of weights along a path from input to output. These values are inherently scale-invariant. Since the number of paths grows exponentially with depth, we identify a minimal set of basis paths that are sufficient to represent the network.
  2. The Skeleton Method: We use a "skeleton" of weights to define these basis paths, ensuring the representation is both complete and efficient.
Illustration of basis paths and the skeleton method in a multi-layer network.
  1. $\mathcal{G}$-SGD Algorithm: We implement optimization through two key mechanisms: the Inverse-Chain-Rule (ICR), which converts standard gradients into gradients for the basis paths, and Weight-Allocation (WA), which projects updates back onto the actual weights.

Key Results

Our experiments demonstrate that $\mathcal{G}$-SGD consistently outperforms vanilla SGD across various architectures and datasets like CIFAR-10 and CIFAR-100.

  • Significant Accuracy Gains: On CIFAR-100 using a PlainNet-34, $\mathcal{G}$-SGD reduced the classification error from 36.41% to 30.74%. Even on ResNet-110, where skip connections limit scaling symmetry, $\mathcal{G}$-SGD reached an error of 6.49% compared to 6.83% for SGD.
  • Efficiency: Despite the extra math involved in the ICR and WA steps, $\mathcal{G}$-SGD only adds about 7% computational overhead compared to vanilla SGD, making it a viable alternative for real-world training.
Training loss and test accuracy comparisons between SGD and G-SGD on CIFAR-10 and CIFAR-100.

Conclusion

By aligning the optimization space with the functional properties of ReLU networks, $\mathcal{G}$-SGD effectively removes redundant dimensions from the search space. This theoretically grounded approach offers a practical way to improve deep learning performance on standard computer vision tasks. Future work will explore more robust integrations with Batch Normalization and residual connections.

Summary updated

Abstract

It is well known that neural networks with rectified linear units (ReLU) activation functions are positively scale-invariant. Conventional algorithms like stochastic gradient descent optimize the neural networks in the vector space of weights, which is, however, not positively scale-invariant. This mismatch may lead to problems during the optimization process. Then, a natural question is: \emph{can we construct a new vector space that is positively scale-invariant and sufficient to represent ReLU neural networks so as to better facilitate the optimization process }? In this paper, we provide our positive answer to this question. First, we conduct a formal study on the positive scaling operators which forms a transformation group, denoted as $\mathcal{G}$. We show that the value of a path (i.e. the product of the weights along the path) in the neural network is invariant to positive scaling and prove that the value vector of all the paths is sufficient to represent the neural networks under mild conditions. Second, we show that one can identify some basis paths out of all the paths and prove that the linear span of their value vectors (denoted as $\mathcal{G}$-space) is an invariant space with lower dimension under the positive scaling group. Finally, we design stochastic gradient descent algorithm in $\mathcal{G}$-space (abbreviated as $\mathcal{G}$-SGD) to optimize the value vector of the basis paths of neural networks with little extra cost by leveraging back-propagation. Our experiments show that $\mathcal{G}$-SGD significantly outperforms the conventional SGD algorithm in optimizing ReLU networks on benchmark datasets.
BibTeX
@inproceedings{meng2019optimizing,
  author = {Qi Meng and Wei Chen and Shuxin Zheng and Qiwei Ye and Tie-Yan Liu},
  title = {{Optimizing Neural Networks in the Equivalent Class Space}},
  booktitle = {International Conference on Learning Representations},
  year = {2019},
  url = {https://openreview.net/forum?id=mDE_pOdjR2o},
}

Loading related content...

Figure