L0-ARM: Network Sparsification via Stochastic Binary Optimization

Yang Li, Shihao Ji · DOI

Abstract

We consider network sparsification as an $L_0$-norm regularized binary optimization problem, where each unit of a neural network (e.g., weight, neuron, or channel, etc.) is attached with a stochastic binary gate, whose parameters are jointly optimized with original network parameters. The Augment-Reinforce-Merge (ARM), a recently proposed unbiased gradient estimator, is investigated for this binary optimization problem. Compared to the hard concrete gradient estimator from Louizos et al., ARM demonstrates superior performance of pruning network architectures while retaining almost the same accuracies of baseline methods. Similar to the hard concrete estimator, ARM also enables conditional computation during model training but with improved effectiveness due to the exact binary stochasticity. Thanks to the flexibility of ARM, many smooth or non-smooth parametric functions, such as scaled sigmoid or hard sigmoid, can be used to parameterize this binary optimization problem and the unbiasness of the ARM estimator is retained, while the hard concrete estimator has to rely on the hard sigmoid function to achieve conditional computation and thus accelerated training. Extensive experiments on multiple public datasets demonstrate state-of-the-art pruning rates with almost the same accuracies of baseline methods. The resulting algorithm $L_0$-ARM sparsifies the Wide-ResNet models on CIFAR-10 and CIFAR-100 while the hard concrete estimator cannot. The code is public available at https://github.com/leo-yangli/l0-arm.

Introduction

Modern Deep Neural Networks (DNNs) are notoriously over-parameterized. While this redundancy aids in achieving high accuracy, it imposes significant computational and memory costs, limiting deployment on edge devices like smartphones or IoT sensors. Pruning, or sparsification, aims to remove redundant weights to mitigate these issues.

The ideal objective for pruning is minimizing the $L_0$-norm, which directly counts non-zero parameters. However, the $L_0$-norm is non-differentiable and discontinuous, making it incompatible with standard gradient-based optimization. Previous approaches, such as the "hard concrete" relaxation, attempt to make the problem differentiable but introduce bias. This bias often leads to sub-optimal pruning or complete failure on complex, modern architectures.

Methodology: Stochastic Binary Optimization with ARM

The proposed $L_0$-ARM framework attaches a stochastic binary gate $z \in \{0, 1\}$ to every network unit (weight, neuron, or channel). A gate value of 0 indicates the unit is pruned, while 1 indicates it is retained.

The core innovation lies in applying the Augment-Reinforce-Merge (ARM) estimator to this discrete optimization problem. Unlike previous methods that smooth binary gates into continuous values, ARM provides an unbiased gradient for the discrete gates. This allows the model to learn optimal gate configurations without the mathematical "drift" inherent in biased estimators.

Flexibility in Parameterization

A key advantage of ARM is its flexibility. Because it does not require a specific differentiable relaxation, various parametric functions can be used to define the gate probabilities. As shown in Figure 1, functions like the scaled sigmoid or hard sigmoid can be employed to create sharper transitions between "on" and "off" states, further refining the pruning process.

Comparison of different parametric functions for binary gates, including sigmoid and hard sigmoid variants.

The authors also introduce $L_0$-AR, a faster variant that requires only a single forward pass during training, offering a trade-off between gradient accuracy and computational speed.

Key Insights and Results

The research highlights that the bias in previous estimators was a primary bottleneck for pruning complex models. By utilizing an unbiased estimator, $L_0$-ARM successfully sparsifies architectures that were previously considered "un-prunable" by $L_0$ methods.

The "Two-Spike" Convergence

During training, the probability of a gate being open or closed naturally migrates toward the extremes of 0 or 1. This behavior is visualized in Figure 2, where the histogram of gate parameters evolves into two distinct "spikes." This clear separation makes the final pruning decision at inference time highly robust.

Evolution of the gate parameter distribution over training epochs, showing the emergence of a "two-spike" histogram.

Performance Benchmarks

  • MNIST: On LeNet-5-Caffe, $L_0$-ARM achieved a 99.49% prune rate with 98.7% accuracy, surpassing the previous state-of-the-art $L_0$-HC (98.6% prune rate).
  • Wide-ResNet (CIFAR-10/100): In a significant breakthrough, $L_0$-ARM successfully pruned ~50% of parameters on Wide-ResNet (WRN-28-10) with negligible accuracy loss. In contrast, previous $L_0$ methods failed to remove any parameters without destroying performance.

Discussion and Conclusion

$L_0$-ARM represents a significant step forward in neural network sparsification. By treating pruning as a stochastic binary optimization problem and leveraging the unbiased ARM estimator, it achieves state-of-the-art results on both simple and complex architectures.

While the method introduces some training overhead due to multiple forward passes, the resulting gains in inference efficiency and model compression make it a powerful tool for deploying deep learning on resource-constrained hardware. Future work may explore more sophisticated parametric functions to further enhance sparsity and investigate histogram-dependent thresholds for even more robust pruning decisions.

Summary updated

BibTeX
@inproceedings{li2019l,
  author = {Yang Li and Shihao Ji},
  title = {{L0-ARM: Network Sparsification via Stochastic Binary Optimization}},
  booktitle = {ECML/PKDD},
  year = {2019},
  doi = {10.1007/978-3-030-46147-8\_26},
}
Figure