AdaDeep: A Usage-Driven, Automated Deep Model Compression Framework for Enabling Ubiquitous Intelligent Mobiles

Sicong Liu, Junzhao Du, Kaiming Nan, Zimu Zhou, Atlas Wang, Yingyan Lin

Abstract

Recent breakthroughs in Deep Neural Networks (DNNs) have fueled a tremendously growing demand for bringing DNN-powered intelligence into mobile platforms. While the potential of deploying DNNs on resource-constrained platforms has been demonstrated by DNN compression techniques, the current practice suffers from two limitations: 1) merely stand-alone compression schemes are investigated even though each compression technique only suit for certain types of DNN layers; and 2) mostly compression techniques are optimized for DNNs' inference accuracy, without explicitly considering other application-driven system performance (e.g., latency and energy cost) and the varying resource availability across platforms (e.g., storage and processing capability). To this end, we propose AdaDeep, a usage-driven, automated DNN compression framework for systematically exploring the desired trade-off between performance and resource constraints, from a holistic system level. Specifically, in a layer-wise manner, AdaDeep automatically selects the most suitable combination of compression techniques and the corresponding compression hyperparameters for a given DNN. Thorough evaluations on six datasets and across twelve devices demonstrate that AdaDeep can achieve up to $18.6\times$ latency reduction, $9.8\times$ energy-efficiency improvement, and $37.3\times$ storage reduction in DNNs while incurring negligible accuracy loss. Furthermore, AdaDeep also uncovers multiple novel combinations of compression techniques.

Introduction

Deploying powerful Deep Neural Networks (DNNs) on mobile and IoT devices, such as smartwatches or budget smartphones, remains a significant challenge due to their heavy requirements for storage, computation, and battery power. While various compression techniques like pruning and weight factorization exist, they are often applied manually and globally. This approach ignores the fact that different layers (e.g., convolutional vs. fully-connected) react differently to specific techniques. Furthermore, most existing tools focus solely on maximizing accuracy, neglecting real-world "usage-driven" constraints like specific latency budgets or energy limits.

AdaDeep addresses these gaps by providing an automated, holistic system that balances performance requirements against the varying resource availability of different mobile platforms.

The AdaDeep Framework

AdaDeep operates as a usage-driven framework that takes user demands—such as latency ($T_{bgt}$) and storage ($S_{bgt}$) budgets—and automatically produces an optimal compressed DNN for the target device.

Overview of the AdaDeep framework showing the interaction between user demands and the automated optimization process.

At its core, AdaDeep utilizes a two-phase Deep Reinforcement Learning (DRL) optimizer to treat model compression as a constrained hyperparameter optimization problem:

  1. Phase 1: DQN for Technique Selection (Coarse-grained): A Deep Q-Network (DQN) agent decides which combination of compression techniques to use for each layer. It employs a "dueling" architecture to separate the objective of maximizing accuracy from the objective of satisfying hardware constraints.
  2. Phase 2: DDPG for Parameter Tuning (Fine-grained): Once techniques are chosen, a Deep Deterministic Policy Gradient (DDPG) agent searches a continuous space to find optimal hyperparameters, such as exact pruning ratios.

Layer-wise Customization

One of AdaDeep's primary innovations is its ability to apply different strategies to different layers. For example, it might prune a fully-connected layer to save storage while using depth-wise separable convolutions on a convolutional layer to reduce computation. This layer-wise approach allows the framework to exploit the unique characteristics of each part of the network.

Example of AdaDeep applying different compression techniques across various layers of a CNN to meet specific performance goals.

The framework uses a reward function based on Lagrangian Multipliers, allowing it to treat accuracy and energy as goals to maximize, while treating latency and storage as hard constraints that must be met.

Key Results and Insights

Thorough evaluations across six diverse datasets (including ImageNet and UbiSound) and twelve different mobile platforms demonstrated AdaDeep's effectiveness:

  • Storage: Achieved up to a 37.3× reduction in model size.
  • Latency: Reduced inference time by up to 18.6×.
  • Energy Efficiency: Improved energy efficiency by up to 9.8×.
  • Accuracy: These gains were achieved with negligible accuracy loss, typically less than 2.1%.

Beyond these metrics, AdaDeep uncovered novel combinations of compression techniques not previously proposed in literature. It also demonstrated high hardware-awareness; because the framework includes latency and energy models, it understands that parameter reduction does not always translate linearly to power savings, adapting the model specifically to the target device's architecture.

Conclusion

AdaDeep represents a significant step toward automated, hardware-aware DNN deployment. By moving away from "one-size-fits-all" compression, it enables high-performance AI on a wide range of resource-constrained devices. Future work will look to extend this framework to Recurrent Neural Networks (RNNs) and further optimize for mobile GPU architectures.

Summary updated

BibTeX
@article{liu2021adadeep,
  author = {Sicong Liu and Junzhao Du and Kaiming Nan and Zimu Zhou and Atlas Wang and Yingyan Lin},
  title = {{AdaDeep: A Usage-Driven, Automated Deep Model Compression Framework for Enabling Ubiquitous Intelligent Mobiles}},
  journal = {IEEE Trans. Mobile Computing},
  year = {2021},
  url = {https://openreview.net/forum?id=11zbCEiAtOS},
}
Figure