TL;DR
This paper introduces ViT-EnsembleAttack, a novel method for generating adversarial examples that are more effective at fooling unseen Vision Transformer (ViT) models. By adversarially augmenting individual ViT surrogate models before ensembling them, the approach significantly boosts the transferability of attacks, outperforming existing methods.
What Problem Does This Paper Address?
Deep neural networks, particularly in computer vision, are vulnerable to adversarial attacks. Adversarial examples are inputs with small, imperceptible perturbations designed to cause misclassification. A key challenge is transferability: adversarial examples generated on one model (surrogate) often successfully fool other models, even those with different architectures. Ensemble-based attacks leverage multiple surrogate models to improve this transferability. However, existing methods primarily focus on optimizing how the outputs of these ensembles are combined, neglecting the potential to improve the surrogate models themselves. This paper addresses this gap by proposing a method to adversarially augment the surrogate ViT models to increase their diversity and, consequently, enhance the transferability of the resulting adversarial examples.
Methods
The core of ViT-EnsembleAttack lies in its novel "Model Augmentation" strategy applied to surrogate ViT models. Instead of using standard ViTs as surrogates, the authors propose generating augmented versions. This is achieved through three ViT-specific strategies inspired by data augmentation:
- Multi-head Dropping (MHD): Randomly drops some attention heads within the Multi-Head Self-Attention (MHA) modules.
- Attention Score Scaling (ASS): Scales attention scores with random factors.
- MLP Feature Mixing (MFM): Randomly permutes and mixes features within the Multi-Layer Perceptron (MLP) blocks.
These augmentation strategies are parameterized, and their optimal values are found using Bayesian optimization. The objective function for this optimization is the attack success rate of the augmented surrogate against other target models, aiming to maximize transferability.
In addition to model augmentation, ViT-EnsembleAttack incorporates two other modules:
- Automatic Reweighting: Dynamically adjusts the weights of each surrogate model in the ensemble based on their loss magnitudes during the attack. This prevents models with larger losses from dominating the gradient updates and causing overfitting.
- Step Size Enlargement: Increases the step size used in iterative adversarial attacks, accelerating convergence and enhancing attack strength.
Datasets
- ILSVRC 2012 validation set: 1000 images were used for attacking target models.
- Additional 4000 images: Used for Bayesian optimization to find optimal augmentation parameters.
The paper does not introduce new benchmark datasets.
Key Insights and Ideas
- Augmenting the Augmenters: The most significant insight is that improving the surrogate models themselves, rather than just their combination, is crucial for boosting adversarial transferability. Adversarially augmenting ViTs increases their diversity, leading to more robust adversarial examples.
- ViT-Specific Augmentations: The proposed MHD, ASS, and MFM strategies are tailored to the unique architecture of Vision Transformers, leveraging their attention mechanisms and MLP blocks.
- Bayesian Optimization for Hyperparameter Tuning: Using Bayesian optimization to find optimal augmentation parameters is an effective way to explore the complex parameter space and maximize transferability.
- Complementary Modules: The combination of Model Augmentation, Automatic Reweighting, and Step Size Enlargement modules synergistically enhances attack performance, with each module contributing uniquely.
Key Results
ViT-EnsembleAttack significantly outperforms existing state-of-the-art ensemble-based adversarial attacks.
- Against ViTs: The method achieves an average improvement of 4.6% in attack success rate (ASR) on normally trained, robust, and adversarially trained ViTs. For instance, it reaches nearly 100% ASR on LeViT-256 when integrated with I-FGSM.
- Against CNNs (Cross-Structure Transferability): The approach demonstrates superior cross-structure transferability, outperforming the best baseline (SMER) by an average margin of 15.3%. It achieves an average ASR of 88.3% against CNNs.
- Module Contributions: Model Augmentation is shown to be the most impactful module, with Automatic Reweighting and Step Size Enlargement further boosting performance when combined.
Limitations and Future Work
- Computational Cost: While the method achieves superior results, the model augmentation phase (Phase 1) can be computationally intensive. The authors note that this phase is performed only once, and the subsequent attack phase (Phase 2) is more efficient. They also provide a trade-off analysis between computational cost and performance for the
loopparameter. - Future Work: The authors suggest exploring new augmentation techniques for ViTs and other model architectures to further enhance ensemble-based adversarial transferability. They also highlight the potential for applying their adversarial augmentation concept to other types of models beyond ViTs.
Summary updated