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

Universally Slimmable Networks and Improved Training Techniques

Jiahui Yu, Thomas S. Huang

Introduction

In mobile and edge computing, hardware constraints vary significantly across devices. Traditionally, engineers had to train and deploy multiple versions of the same architecture (e.g., MobileNet 0.25x, 0.5x, 1.0x) to meet different latency budgets. While previous "slimmable networks" allowed switching between a few predefined widths, they were limited to discrete choices. This paper introduces Universally Slimmable Networks (US-Nets), which allow a single neural network to execute at any arbitrary width at runtime, providing a continuous trade-off between accuracy and efficiency.

Methods

The core innovation of US-Nets is the ability to adjust the number of active channels dynamically without retraining. The authors argue that a wider network should conceptually never perform worse than a slim one because it can learn to "zero out" extra connections, effectively treating feature aggregation as a sum of residuals.

Conceptual diagram of adjusting runtime width in a Universally Slimmable Network.

To achieve high accuracy across all possible widths, the authors introduce three key training techniques:

  1. The Sandwich Rule: Instead of sampling widths randomly, the model is trained at the smallest width, the largest width, and $n-2$ random intermediate widths in every iteration. This ensures that the performance of all intermediate widths is "sandwiched" and stabilized between the optimized lower and upper bounds.
  2. Inplace Distillation: This technique uses the predicted output of the largest width (the "full" model) as the label for smaller sub-networks. The full model acts as an internal teacher, transferring knowledge to slimmer versions without requiring extra memory or a separate teacher model.
  3. Post-Statistics for Batch Normalization (BN): Since different widths have different feature statistics, US-Nets freeze weights after training and perform a quick "calibration" pass on a small data subset (e.g., 1,024 images) to calculate correct BN statistics for a specific width before deployment.

Key Results

The researchers evaluated US-Nets across image classification (ImageNet), super-resolution (DIV2K), and reinforcement learning (Atari).

Performance comparison of US-MobileNet v1 vs. individually trained MobileNet models on ImageNet.

On ImageNet, a single US-MobileNet v1 achieved better average accuracy across various widths than four separate, individually trained MobileNet models. As shown in the figure above, the US-Net (blue curve) provides a continuous efficiency spectrum. Notably, at the 0.25x width, the US-Net achieved 55.7% top-1 accuracy, significantly outperforming the 49.8% achieved by the standalone model.

Beyond classification, US-Nets showed success in Reinforcement Learning, where they consistently outperformed individually trained networks in the Atari Breakout environment. This demonstrates that universal slimmability is a robust property applicable across diverse domains.

Conclusion

Universally Slimmable Networks represent a significant step forward in efficient deep learning. By employing the sandwich rule and inplace distillation, the authors demonstrate that a single model can be more effective and versatile than a suite of specialized ones. While future work may explore non-uniform scaling across layers, US-Nets provide a powerful framework for deploying adaptive AI across a diverse hardware landscape.

Summary updated

BibTeX
@inproceedings{yu2019universally,
  author = {Jiahui Yu and Thomas S. Huang},
  title = {{Universally Slimmable Networks and Improved Training Techniques}},
  booktitle = {IEEE/CVF International Conference on Computer Vision},
  year = {2019},
  doi = {10.1109/iccv.2019.00189},
}
Figure