Abstract
Adversarial training and adversarial purification are two effective and practical defense methods to enhance a model's robustness against adversarial attacks. However, adversarial training necessitates additional training, while adversarial purification suffers from low time efficiency. More critically, current defenses are designed under the perturbation-based adversarial threat model, which is ineffective against the recently proposed unrestricted adversarial attacks. In this paper, we propose an effective and efficient adversarial defense method that counters both perturbation-based and unrestricted adversarial attacks. Our defense is inspired by the observation that adversarial attacks are typically located near the decision boundary and are sensitive to pixel changes. To address this, we introduce adversarial anti-aliasing to mitigate adversarial modifications. Additionally, we propose adversarial super-resolution, which leverages prior knowledge from clean datasets to benignly recover images. These approaches do not require additional training and are computationally efficient without calculating gradients. Extensive experiments against both perturbation-based and unrestricted adversarial attacks demonstrate that our defense method outperforms state-of-the-art adversarial purification methods.
Introduction
Deep learning models are notoriously vulnerable to adversarial attacks—inputs specifically crafted to fool a classifier. These threats generally fall into two categories:
- Perturbation-based attacks: Adding tiny, imperceptible noise to a clean image (e.g., AutoAttack).
- Unrestricted Adversarial Examples (UAEs): Entirely new images generated by AI (like GANs or Diffusion models) that look natural to humans but are classified incorrectly by machines.
Existing defenses like Adversarial Training (AT) are computationally expensive and often fail to generalize to new types of attacks. Adversarial Purification, which tries to "clean" the image before it reaches the classifier, is more flexible but often relies on slow, gradient-heavy diffusion processes. This paper introduces a gradient-free framework that treats purification as an image restoration task, achieving state-of-the-art robustness with significantly lower computational overhead.
Methodology: A Two-Stage Restoration Pipeline
The proposed framework shifts the perspective from "denoising" to "image restoration." Instead of trying to identify and remove specific noise patterns, it intentionally destroys high-frequency details where adversarial perturbations reside and then reconstructs the image using a clean data prior.
1. Adversarial Anti-Aliasing (AAA)
Adversarial perturbations are highly sensitive to pixel-level changes. The first stage applies a specialized 1D mean-filter convolution to the input image. This "blurs" out high-frequency adversarial noise while preserving the general semantic shape of the object. This step is entirely gradient-free and uses in-place operations, making it extremely fast and difficult for attackers to bypass using gradient-based optimization.
2. Adversarial Super-Resolution (ASR)
To recover the details lost during blurring, the framework uses a pre-trained diffusion model (ResShift) designed for super-resolution. Unlike standard diffusion purification (which might generate a new image from scratch), ASR uses the blurred image as a "prior" to restore high-quality, benign details.
3. Contrastive Learning Fine-Tuning
To further boost performance, the diffusion model is fine-tuned using a contrastive loss (InfoNCE). This teaches the model to pull "clean+noise" pairs closer together in feature space while pushing "adversarial" examples away, effectively teaching the model what "benign" detail looks like versus "adversarial" artifacts.
Experimental Results
The framework was evaluated on benchmark datasets including CIFAR-10 and ImageNet across various architectures such as WideResNet, ResNet50, and Vision Transformers (ViT, Swin).
- Efficiency: The method achieved an average 44x speedup compared to existing state-of-the-art diffusion-based purification methods. This is largely due to the use of the ResShift model, which requires only 15 steps and no gradient guidance.
- Robustness on ImageNet: Against AutoAttack on ResNet50, the method achieved 67.61% robust accuracy, significantly outperforming previous methods (~43%) while maintaining a high 75.28% standard accuracy.
- Unrestricted Attacks: On CIFAR-10, it outperformed the previous best method (MimicDiffusion) by roughly 10% in robust accuracy against UAEs.
- Adaptive Attacks: The defense remained resilient against BPDA (Backward Pass Differentiable Approximation), an attack designed to bypass non-differentiable preprocessing.
Conclusion
By treating adversarial purification as a restoration task rather than a denoising one, this research provides a fast, effective, and gradient-free defense against both traditional and unrestricted adversarial attacks. Future work may involve integrating adversarial training directly into the super-resolution diffusion model's training process to create an even more specialized "defense-aware" restoration engine.
Summary updated