Ensemble-Compression: A New Method for Parallel Training of Deep Neural Networks

Shizhao Sun, Wei Chen, Jiang Bian, Xiaoguang Liu, Tie-Yan Liu

TL;DR

Standard parallel training for deep learning relies on "Model Averaging," which often fails because averaging the weights of non-convex neural networks doesn't guarantee a better model. This paper introduces Ensemble-Compression (EC-DNN), a framework that aggregates models by averaging their outputs (predictions) instead of their parameters, then uses knowledge distillation to compress the resulting ensemble back into a single, efficient model.

What Problem Does This Paper Address?

To train massive Deep Neural Networks (DNNs) on giant datasets, researchers use parallelization: multiple "workers" train on different slices of data and periodically sync up. The industry standard has been Model Averaging (MA-DNN), where workers simply average their weight parameters to create a new global model.

The catch? DNNs are highly non-convex. If two workers find different "valleys" in the loss landscape, the average of their weights might land on a "peak" between them, resulting in a global model that performs worse than the individual local ones. This inconsistency slows down convergence and limits the final accuracy of the model.

Methods

The authors propose a two-stage aggregation process called EC-DNN:

  1. Ensemble: Instead of averaging weights, the global model is defined as the average of the outputs of all local models. Because most common loss functions (like cross-entropy) are convex with respect to the model's output, an ensemble is mathematically guaranteed to perform at least as well as the average of its parts.
  2. Compression: An ensemble of $K$ workers is $K$ times larger than a single model. To prevent the model size from exploding, the authors use Knowledge Distillation. The local workers "mimic" the ensemble’s predictions, effectively compressing the collective knowledge back into a single-sized network.

To make this efficient, they introduce Diversity Driven Local Training, which encourages local models to explore different parts of the feature space (making the eventual ensemble more robust), and they integrate the compression step directly into the local training phase to avoid extra computational overhead.

Datasets

The researchers evaluated EC-DNN against standard benchmarks:

  • CIFAR-10 & CIFAR-100: Small-scale image classification using the "Network in Network" (NiN) architecture.
  • ImageNet (ILSVRC 2015): Large-scale classification using the 22-layer GoogLeNet architecture to test the method's scalability.

Key Insights and Ideas

  • The Convexity Loophole: While we can't easily average weights due to non-convexity, we can average outputs because the loss function is convex relative to those outputs. This provides a theoretical safety net that Model Averaging lacks.
  • Diversity is a Feature, Not a Bug: In Model Averaging, workers drifting apart is a problem. In EC-DNN, diversity among workers actually makes the ensemble stronger. This allows workers to communicate less frequently, significantly reducing network traffic.
  • Seamless Compression: By using a "combination loss" (training on both true labels and the ensemble's "pseudo-labels"), the model compresses itself during its normal training iterations, meaning the "global model" never actually needs to be fully materialized in GPU memory.

Key Results

  • Superior Accuracy: EC-DNN consistently achieved lower test errors than MA-DNN and sequential training across all datasets. On CIFAR-100, the improvement was roughly 5% over MA-DNN.
  • Significant Speedup: Because EC-DNN requires much less frequent communication between workers, it reached target accuracy levels significantly faster. On average, EC-DNN ran 2.24x faster than MA-DNN.
  • Communication Efficiency: EC-DNN performed best with very high synchronization intervals (e.g., every 4000 iterations), whereas MA-DNN's performance often degraded if it wasn't synchronized every 16 iterations.

Limitations and Future Work

  • Relabeling Overhead: While the authors minimized it, the process still requires "relabeling" a portion of the local data with the ensemble's predictions, which adds a small amount of feed-forward computation time.
  • Hyperparameter Tuning: The framework introduces four new hyperparameters (related to diversity regularization and compression weighting) that require tuning for optimal performance.
  • Future Directions: The authors suggest exploring different compression techniques beyond distillation and investigating the theoretical properties of the ensemble-compression loop more deeply.

Summary updated

BibTeX
@inproceedings{sun2017ensemble,
  author = {Shizhao Sun and Wei Chen and Jiang Bian and Xiaoguang Liu and Tie-Yan Liu},
  title = {{Ensemble-Compression: A New Method for Parallel Training of Deep Neural Networks}},
  booktitle = {ECML/PKDD},
  year = {2017},
  doi = {10.1007/978-3-319-71249-9\_12},
}
Figure