Abstract
Deep neural networks (DNNs) are notoriously susceptible to adversarial attacks, prompting the development of various defense mechanisms. However, most existing defenses are designed for a static, one-shot setting. In real-world deployments, models face a sequence of evolving attacks, leading to the challenge of "continual adversarial defense." This paper introduces Anisotropic & Isotropic Replay (AIR), a framework designed to adapt to new adversarial threats without suffering from catastrophic forgetting of previous ones. By utilizing pseudo-replay and consistency regularization, AIR maintains robustness across attack sequences, often approaching the performance of joint training models that have simultaneous access to all data.
Introduction
Adversarial defense research typically operates under the assumption that the threat landscape is stationary. A model is trained to resist a specific set of perturbations (e.g., PGD or FGSM) and is then deployed. However, attackers are adaptive; as new methods emerge, a deployed model must be updated.
The primary obstacle in this scenario is catastrophic forgetting. When a model is fine-tuned to defend against a new "Attack B," it frequently loses its hard-won robustness against the original "Attack A." While "Joint Training"—retraining the model on all previous and new attack types—can mitigate this, it is often impractical due to data privacy regulations, storage constraints, or the prohibitive computational cost of frequent retraining. This paper proposes a life-long defense strategy that is both privacy-preserving and efficient.
The AIR Framework: Anisotropic & Isotropic Replay
To address the stability-plasticity trade-off in adversarial settings, the authors propose the Anisotropic & Isotropic Replay (AIR) baseline. This method utilizes a self-distillation pseudo-replay paradigm, where the model's previous iteration acts as a "teacher" to guide the current "student" model, eliminating the need to store original training samples.
1. Isotropic Pseudo Replay (IR)
Isotropic replay focuses on maintaining model consistency within the neighborhood distribution of new data. By applying stochastic Gaussian noise and random augmentations (such as rotation and cropping) to new adversarial samples, the model "breaks" the specific high-frequency patterns of the current attack. This creates a proxy dataset that retains the original semantics, indirectly aligning the output preferences between the old and new tasks.
2. Anisotropic Pseudo Replay (AR)
Anisotropic replay employs a variation of the "mixup" technique, blending different adversarial samples and their corresponding labels. This allows the model to learn a smoother, compromise data manifold that connects the disparate "islands" of different attack styles. This manifold helps the model generalize better to future, unseen attacks by creating a more continuous representation of robust features.
3. Consistency Regularization and Self-Distillation
To balance the need to learn new attacks (plasticity) with the need to retain old knowledge (stability), AIR incorporates R-Drop. This regularizer forces the model to produce consistent outputs even when different subsets of neurons are active via Dropout. Furthermore, the model minimizes the KL-divergence between the current model’s predictions and the previous model’s predictions on the replayed samples, ensuring that the decision boundaries for previous tasks remain intact.
Experimental Evaluation
The researchers evaluated AIR using three standard benchmarks: MNIST, CIFAR-10, and CIFAR-100. They tested the model across various attack sequences, including transitions from "easy" attacks (like FGSM) to "hard" ones (like PGD), and vice versa.
Key Performance Metrics
AIR significantly outperformed traditional continual learning methods such as Elastic Weight Consolidation (EWC) and Less-Forgetting Learning (LFL):
- MNIST: After learning a second task, AIR maintained 99.37% robustness on the first task, compared to only 95.18% for a standard vanilla fine-tuning approach.
- CIFAR-10: In a PGD-to-FGSM sequence, AIR maintained 43.00% robustness on the initial PGD task, whereas a standard fine-tuned model's performance plummeted to 17.14%.
- Upper Bound Proximity: In several experiments, AIR's performance approached or even exceeded the empirical upper bounds established by Joint Training, demonstrating the effectiveness of the pseudo-replay strategy.
Insights and Discussion
The "Easy-to-Hard" Trap
A surprising finding of the study is that models suffer more from catastrophic forgetting when moving from a "difficult" attack (PGD) to an "easy" one (FGSM). The authors suggest that simple attacks allow the model to overfit to local optima, which effectively erases the complex, robust features learned from more sophisticated attacks. AIR mitigates this by enforcing a smoother manifold through AR.
Feature Isomerization
Using t-SNE visualizations, the authors observed that standard training often clusters different attacks of the same class into separate, disjoint groups. AIR successfully "homogenizes" these features, forcing different attack styles for the same class (e.g., a "dog") into a single, shared feature cluster. This alignment is crucial for maintaining cross-attack robustness.
The Accuracy-Robustness Trade-off
The paper links the classic stability-plasticity trade-off in continual learning to the accuracy-robustness trade-off in security. By aligning the model's preferences across old and new attacks, AIR indirectly improves the model's performance on clean (benign) data, suggesting that robust feature learning and standard accuracy are not necessarily mutually exclusive in a continual learning context.
Conclusion
AIR provides a robust baseline for the emerging field of continual adversarial defense. By combining isotropic and anisotropic pseudo-replay with consistency regularization, the framework allows DNNs to adapt to evolving security threats without sacrificing previous defenses. Future work will explore how to better leverage "forward transfer"—using knowledge from previous attacks to accelerate the learning of new ones—and addressing the model's sensitivity to the specific order of attack sequences.
Summary updated