Hessian-Aware Pruning and Optimal Neural Implant
arXiv:2101.08940
Abstract
Pruning is an effective method to reduce the memory footprint and FLOPs associated with neural network models. However, existing structured-pruning methods often result in significant accuracy degradation for moderate pruning levels. To address this problem, we introduce a new Hessian Aware Pruning (HAP) method coupled with a Neural Implant approach that uses second-order sensitivity as a metric for structured pruning. The basic idea is to prune insensitive components and to use a Neural Implant for moderately sensitive components, instead of completely pruning them. For the latter approach, the moderately sensitive components are replaced with with a low rank implant that is smaller and less computationally expensive than the original component. We use the relative Hessian trace to measure sensitivity, as opposed to the magnitude based sensitivity metric commonly used in the literature. We test HAP for both computer vision tasks and natural language tasks, and we achieve new state-of-the-art results. Specifically, HAP achieves less than / degradation on PreResNet29/ResNet50 (CIFAR-10/ImageNet) with more than 70\%/50\% of parameters pruned. Meanwhile, HAP also achieves significantly better performance (up to 0.8\% with 60\% of parameters pruned) as compared to gradient based method for head pruning on transformer-based models. The framework has been open sourced and available online.
References in corpus (20)
- Distilling the Knowledge in a Neural Network
- MobileNets: Efficient Convolutional Neural Networks for Mobile Vision Applications
- Quantized Neural Networks: Training Neural Networks with Low Precision Weights and Activations
- Pruning Convolutional Neural Networks for Resource Efficient Inference
- AMC: AutoML for Model Compression and Acceleration on Mobile Devices
- Rethinking the Value of Network Pruning
- SQuAD: 100,000+ Questions for Machine Comprehension of Text
- Quantizing deep convolutional networks for efficient inference: A whitepaper
- Pruning Filters for Efficient ConvNets
- To prune, or not to prune: exploring the efficacy of pruning for model compression
- SNIP: Single-shot Network Pruning based on Connection Sensitivity
- The State of Sparsity in Deep Neural Networks
- Model compression via distillation and quantization
- Exploring the Regularity of Sparse Structure in Convolutional Neural Networks
- Discrimination-aware Channel Pruning for Deep Neural Networks
- Apprentice: Using Knowledge Distillation Techniques To Improve Low-Precision Network Accuracy
- Randomized algorithms for matrices and data
- Are Sixteen Heads Really Better than One?
- PyHessian: Neural Networks Through the Lens of the Hessian
- Quantized Guided Pruning for Efficient Hardware Implementations of Convolutional Neural Networks