Gist: Efficient Data Encoding for Deep Neural Network Training
By Animesh Jain, Amar Phanishayee, Jason Mars, Lingjia Tang, Gennady Pekhimenko. 2018
155 citations recorded by the source corpus.
Modern deep neural networks (DNNs) training typically relies on GPUs to train complex hundred-layer deep networks. A significant problem facing both researchers and industry practitioners is that, as the networks get deeper, the available GPU main memory becomes a primary bottleneck, limiting the size of networks it can train. In this paper, we investigate widely used DNNs and find that the major contributors to memory footprint are intermediate layer outputs (feature maps). We then introduce a framework for DNN-layer-specific optimizations (e.g., convolution, ReLU, pool) that significantly reduce this source of main memory pressure on GPUs. We find that a feature map typically has two uses that are spread far apart temporally. Our key approach is to store an encoded representation of feature maps for this temporal gap and decode this data for use in the backward pass; the full-fidelity feature maps are used in the forward pass and relinquished immediately. Based on this approach, we present Gist, our system that employs two classes of layer-specific encoding schemes – lossless and lossy – to exploit existing value redundancy in DNN training to significantly reduce the memory consumption of targeted feature maps. For example, one insight is by taking advantage of the computational nature of back propagation from pool to ReLU layer, we can store the intermediate feature map using just 1 bit instead of 32 bits per value. We deploy these mechanisms in a state-of-the-art DNN framework (CNTK) and observe that Gist reduces the memory footprint to upto 2x across 5 state-of-the-art image classification DNNs, with an average of 1.8x with only 4% performance overhead. We also show that further software (e.g., CuDNN) and hardware (e.g., dynamic allocation) optimizations can result in even larger footprint reduction (upto 4.1x).
Subfields: Artificial Intelligence, Computer Vision and Pattern Recognition, Efficiency & Compression
How researchers see this paper
The researchers whose trusted networks rank it highest, strongest advocate first. Every researcher gets a different order.
In Artificial Intelligence
- Kurt Keutzer
- Song Han
- Quoc V. Le
- A. Gholami
- Yoshua Bengio
- Matei A. Zaharia
- Sergey Levine
- Joseph E. Gonzalez
In Computer Vision and Pattern Recognition
- Luc Van Gool
- Dacheng Tao
- Yi Yang
- Trevor Darrell
- Song Han
- Kurt Keutzer
- Jitendra Malik
- Ming-Hsuan Yang
In Efficiency & Compression
Citations in the corpus
- ZeRO: Memory optimizations Toward Training Trillion Parameter Models (2019, background): “1) Reducing Activation Memory: Multiple efforts have focused on reducing the memory footprint of activations through compression [15], activation checkpointing [8], [16], or live analysis [17].”
- ZeRO-Infinity: Breaking the GPU Memory Wall for Extreme Scale Deep learning (2021, background): “Multiple efforts have focused on reducing the memory required by activations through compression [28], activation checkpointing [29, 30], or live analysis [31].”
- Memory-Efficient Pipeline-Parallel DNN Training (2020, methodology): “Gist [13] employs lossless and lossy layer-specific encoding schemes to compress stashed activations.”
- Checkmate: Breaking the Memory Wall with Optimal Tensor Rematerialization (2019, background): “Rematerialization is more appropriate than copying values out of core as the cost of spilling values from global GPU memory to main memory (RAM) is substantial (Micikevicius, 2011; Jain et al., 2018), though possible (Meng et al.”
- AccPar: Tensor Partitioning for Heterogeneous Deep Learning Accelerators (2020, background): “vlutin [99], TIE [137], Laconic [138], ADM-NN [139], Gist [140]”
- Buddy Compression: Enabling Larger Memory for Deep Learning and HPC Workloads on GPUs (2019, background): “Many domain-specific solutions have been proposed across the stack to address the DL memory capacity challenge, including DL-specific footprint reduction schemes [45], [46], [25] and asynchronous offloading of data during each training iteration [47], [14], [12], [48], [15], [49], [50].”
- Low-Memory Neural Network Training: A Technical Report (2019, methodology): “Some others, such as ReLU, only require 1 bit per input element [Jain et al., 2018], and so on.”
- AntMan: Dynamic Scaling on GPU Clusters for Deep Learning (2020, methodology): “Gist: Efficient data encoding for deep neural network training.”
- Capuchin: Tensor-based GPU Memory Management for Deep Learning (2020, methodology): “CDMA [25] and Gist [13] compress the data by leveraging the sparsity in particular neural network architecture, such as ReLU-Pool, which are all lossless compressing methods.”
- Model Compression and Hardware Acceleration for Neural Networks: A Comprehensive Survey (2020, background): “Although the use of on-GPU compression such as [201], [233], [250], and [251] can improve the performance, there is still a big gap far from our expectation due to the redundant design of general-purpose processors for flexible programmability and general applicability.”
- RecNMP: Accelerating Personalized Recommendation with Near-Memory Processing (2019, unknown): “patterns found in fully-connected (FC), convolution (CNN), and recurrent (RNN) neural networks [3], [6]–[8], [11], [12], [15], [17], [18], [24], [33], [36], [40], [47], [53]–[55], [57], [60], [68], [71]–[74], [76], [79], [82].”
- Machine Learning at Facebook: Understanding Inference at the Edge (2019, background): “Recent work on hardware for machine learning and efficient training and inference has substantially advanced the state-of-the-art [41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66].”
- MnnFast: A Fast and Scalable System Architecture for Memory-Augmented Neural Networks (2019, background): “[36] propose layer-specific lossy and lossless encoding schemes for intermediate layer outputs.”
- OLLA: Optimizing the Lifetime and Location of Arrays to Reduce the Memory Usage of Neural Networks (2022, background): “These techniques encompass: • In-memory tensor compression, which can result in minimal accuracy loss in many DNN applications [11, 42].”
- PipeDream: generalized pipeline parallelism for DNN training (2019, methodology): “PipeDream’s memory footprint can be further reduced by using existing techniques: efficient encoding or compression of intermediate data [30], gradient aggregation where weight gradients are added to a single buffer at a stage for m minibatches before performing a weight update, and trading…”
- Zico: Efficient GPU Memory Sharing for Concurrent DNN Training (2021, methodology): “During the training procedure, intermediate outputs from model layers called feature maps dominate memory footprint [18,32].”