[Paper Review] SuperNeurons: Dynamic GPU Memory Management for Training Deep Neural Networks
SuperNeurons introduces a dynamic GPU memory scheduling runtime that enables training deep neural networks beyond the physical limits of GPU DRAM. By combining Liveness Analysis, Unified Tensor Pool, and Cost-Aware Recomputation, it reduces peak memory usage to the maximum layer memory, allowing training of ResNet2500 (10⁴ layers) on a 12GB K40c GPU—achieving up to 3.24x deeper models than TensorFlow, with leading performance across frameworks.
Going deeper and wider in neural architectures improves the accuracy, while the limited GPU DRAM places an undesired restriction on the network design domain. Deep Learning (DL) practitioners either need change to less desired network architectures, or nontrivially dissect a network across multiGPUs. These distract DL practitioners from concentrating on their original machine learning tasks. We present SuperNeurons: a dynamic GPU memory scheduling runtime to enable the network training far beyond the GPU DRAM capacity. SuperNeurons features 3 memory optimizations, extit{Liveness Analysis}, extit{Unified Tensor Pool}, and extit{Cost-Aware Recomputation}, all together they effectively reduce the network-wide peak memory usage down to the maximal memory usage among layers. We also address the performance issues in those memory saving techniques. Given the limited GPU DRAM, SuperNeurons not only provisions the necessary memory for the training, but also dynamically allocates the memory for convolution workspaces to achieve the high performance. Evaluations against Caffe, Torch, MXNet and TensorFlow have demonstrated that SuperNeurons trains at least 3.2432 deeper network than current ones with the leading performance. Particularly, SuperNeurons can train ResNet2500 that has $10^4$ basic network layers on a 12GB K40c.
Motivation & Objective
- Address the growing memory bottleneck in training deeper and wider deep neural networks due to limited GPU DRAM capacity.
- Overcome the limitations of static memory reduction techniques in existing frameworks like Caffe, Torch, MXNet, and TensorFlow, which fail to adapt to dynamic data and dependency variations in nonlinear architectures.
- Enable end-to-end training of extremely deep networks—beyond the physical memory capacity of modern GPUs—without requiring manual model partitioning or multi-GPU dissection.
- Maintain high training performance despite aggressive memory optimization by integrating performance-aware scheduling and communication overlap.
- Provide a transparent, user-transparent runtime that dynamically manages tensor allocation, deallocation, and offloading while guaranteeing minimal peak memory usage at the layer level.
Proposed method
- Liveness Analysis identifies and reclaims tensors no longer needed during forward and backward passes, reducing peak memory from ∑(l_i^f + l_i^b) to ∑(l_i^f) + l_N^b.
- Unified Tensor Pool (UTP) offloads high-computation, memory-intensive layers (checkpoints) to external memory, further reducing peak memory to ∑(l_i^f ∉ checkpoints) + l_N^b.
- Cost-Aware Recomputation selectively drops forward results of cheap or non-checkpoint layers and reconstructs them during backpropagation, minimizing peak memory to max(l_i), the maximum memory usage among any single layer.
- A pre-allocated GPU memory pool with a heap-based allocator amortizes allocation/deallocation overhead by reusing memory segments, reducing runtime cost of frequent tensor operations.
- A GPU DRAM-based LRU tensor cache overlaps communication and computation by reusing frequently accessed tensors, minimizing data movement between CPU and GPU during UTP operations.
- The runtime integrates seamlessly with deep learning frameworks by using tensors as scheduling units, aligning with cuDNN’s layer-wise computation model and remaining transparent to users.
Experimental results
Research questions
- RQ1How can dynamic memory scheduling reduce peak memory usage in deep neural network training beyond the constraints of GPU DRAM capacity?
- RQ2To what extent can liveness analysis and tensor reuse reduce memory pressure in nonlinear, deep architectures with variable memory access patterns?
- RQ3Can offloading tensors from GPU DRAM to external memory while overlapping communication with computation maintain high training throughput in data-parallel training?
- RQ4How effective is cost-aware recomputation in trading computation for memory savings without degrading training performance?
- RQ5Can a unified, dynamic memory management system outperform static memory reduction techniques in both memory efficiency and training speed across diverse deep learning frameworks?
Key findings
- SuperNeurons enables training of ResNet2500 with approximately 10⁴ basic layers on a 12GB K40c GPU, a model that exceeds the memory capacity of current frameworks.
- It achieves at least 3.2432x deeper network training than TensorFlow, 4.0000x deeper than MXNet, 12.6316x deeper than Torch, and 12.9730x deeper than Caffe.
- The peak memory usage is reduced to max(l_i), the maximum memory required by any single layer, achieving the theoretical minimum at the layer-wise granularity.
- SuperNeurons maintains leading training performance across frameworks, with end-to-end evaluations showing consistent speed advantages on both linear (AlexNet, VGG16) and nonlinear (ResNet50→152, Inception V4) networks.
- The performance degradation with increasing batch size is minimal due to efficient communication overlap and caching, though it increases when GPU memory can only hold one layer.
- The system supports models up to 19.8x larger than those supported by Caffe, demonstrating significant scalability beyond current state-of-the-art frameworks.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.