TL;DR
HARP (Holistic Adversarially Robust Pruning) is a framework that allows neural networks to be compressed by up to 99.9% while maintaining significantly higher adversarial robustness than previous methods. By treating compression as a global optimization problem—learning exactly how much to prune from each layer individually—HARP prevents the "model collapse" typically seen in highly compressed, robust models.
The Problem: Pruning vs. Robustness
Deep Neural Networks (DNNs) are notoriously oversized and vulnerable to adversarial attacks (small, intentional perturbations that flip a model's prediction). We generally rely on two main tools to fix these issues: Pruning (removing redundant weights to save memory) and Adversarial Training (training on "attacked" images to build immunity).
The catch is that these two goals are fundamentally at odds. Research suggests that adversarial robustness requires more parameters, not fewer. When you try to prune a robust model aggressively (e.g., removing 99% of weights), the model's accuracy and robustness usually fall off a cliff. Existing methods typically use a "uniform" strategy—pruning every layer by the same percentage—which leads to "model collapse" at high compression rates because critical layers (like the input layer) become too thin to function.
The HARP Method
The authors introduce HARP, which moves away from uniform pruning. Its "holistic" approach involves three key components:
- Learnable Compression Quotas ($r$): Instead of a human deciding that every layer should be 99% sparse, HARP treats the compression rate of each layer as a trainable parameter.
- Importance Scores ($S$): Simultaneously, the model learns which specific connections within those layers are most important for robustness.
- Dynamic Regularization ($\gamma$): The authors use a step-wise "scheduler" for the pruning process. It starts by focusing purely on robustness, then shifts focus to hitting the target compression rate, and finally balances both objectives to "heal" the pruned network.
To handle the fact that pruning (a binary "keep or drop" decision) isn't naturally differentiable, they use a Straight-Through Estimator (STE) to allow gradients to flow through the pruning masks during training.
Key Insights and Ideas
- The "U-Shaped" Strategy: HARP naturally learns a non-uniform strategy. It tends to keep more parameters in the very first and very last layers while aggressively thinning out the middle. This preserves the "information bottleneck" and prevents the model from losing its ability to process raw input.
- Uniform Pruning is the Enemy of Sparsity: The paper demonstrates that at 99.9% sparsity, uniform pruning often leaves only 1 or 2 parameters in the input layer, effectively "blinding" the model. By allowing non-uniform rates, HARP keeps these vital layers functional.
- Robustness is a Compactness Challenge: The authors find that while robustness usually requires over-parameterization, a smartly pruned small model can outperform a dumbly pruned larger model.
Key Results
HARP sets a new state-of-the-art for aggressive, robust pruning across multiple datasets (CIFAR-10, SVHN, ImageNet) and against rigorous attacks like AutoAttack.
- Extreme Sparsity (99.9%): On CIFAR-10 (VGG16), HARP maintained a natural accuracy of ~60% and robustness of ~37%. In comparison, previous leaders like HYDRA and Robust-ADMM saw their accuracy drop to near-random (10%) due to model collapse.
- ImageNet Performance: At 90% sparsity, HARP outperformed Robust-ADMM by 20 percentage points in natural accuracy and 10 percentage points in adversarial robustness.
- Stability: Unlike other methods that require complex manual tuning for different architectures, HARP’s automated layer-wise rate learning makes it highly adaptable to different network types (e.g., VGG vs. ResNet).
Limitations and Future Work
- Computational Cost: HARP is an optimization-based approach. While it produces excellent results, it requires a multi-stage training process (pre-training, pruning/searching, and fine-tuning), which is more computationally expensive than "one-shot" pruning methods.
- Theoretical Grounding: The current work is largely empirical. The authors note that while their learned strategies align with some theoretical frameworks, a rigorous mathematical proof of why these specific non-uniform rates are optimal for robustness remains an open question.
- Hardware Realities: The paper focuses on "unstructured" weight pruning. While this is great for theoretical compression, unstructured sparsity is often hard to accelerate on standard GPUs without specialized hardware. More work is needed to make these robust models "plug-and-play" for edge devices using structured channel pruning.
Summary updated