Staircase Sign Method for Boosting Adversarial Attacks

Qilong Zhang, Xiaosu Zhu, Jingkuan Song, Lianli Gao

Abstract

Transfer-based adversarial attacks often suffer from low success rates against black-box models, particularly those with robust defenses. Traditional methods like the Fast Gradient Sign Method (FGSM) discard gradient magnitude information, leading to perturbations that overfit the substitute model. This paper introduces the Staircase Sign Method ($S^2M$), a plug-and-play modification that re-incorporates gradient magnitude through a staircase weighting function. Empirical results demonstrate that $S^2M$ significantly enhances attack transferability, improving success rates by up to 12.8% on defended models while maintaining computational efficiency.

Introduction

Deep Neural Networks (DNNs) are notoriously vulnerable to adversarial examples—images with tiny, invisible perturbations that cause the model to misclassify them. In a "black-box" attack scenario, the attacker lacks knowledge of the victim model's architecture or weights. Instead, they employ transfer-based attacks, crafting perturbations on a known "substitute" model with the expectation that these will "transfer" to the unknown victim.

Most current transfer attacks rely on the Sign Method (SM), popularized by algorithms like FGSM. SM utilizes only the direction (sign) of the gradient for each pixel, discarding the magnitude. This "coarse" approach often causes the attack to deviate from the optimal path, essentially "overfitting" the perturbation to the specific quirks of the substitute model. This lack of nuance reduces the likelihood of the attack working on a different victim model, especially one with robust defenses.

The Staircase Sign Method ($S^2M$)

The authors propose the Staircase Sign Method ($S^2M$) to address this information loss. It is a "plug-and-play" modification that can be integrated into almost any iterative FGSM-style attack. The process involves four key steps:

  1. Gradient Calculation: The gradient of the loss function is calculated with respect to the input image.
  2. Staircase Partitioning: Instead of a binary sign operation, $S^2M$ divides the gradient units into $K$ segments based on their absolute values (using percentiles).
  3. Weight Assignment: A "staircase weight" is assigned to each segment. Pixels with larger gradient magnitudes receive higher weights, reflecting their greater importance in the adversarial direction.
  4. Perturbation: The final perturbation is the element-wise product of the gradient sign and these staircase weights: $sign(G) \odot W$.
Geometric comparison of gradient directions showing how $S^2M$ reduces deviation from the true gradient.

This approach preserves the efficiency of the Sign Method while capturing the relative importance of different pixels. It effectively bridges the gap between raw gradients—which are often too small to use directly—and the binary Sign Method, which is often too blunt.

Key Insights

  • Magnitude is Information: Gradient magnitude represents the "confidence" of the direction. By ignoring it, traditional attacks lose the nuance needed to find the "global optimal attack region" that exists across different model architectures.
  • Reducing Deviation: The authors demonstrate that $S^2M$ perturbations maintain a significantly higher cosine similarity to the raw gradients of an ensemble of models (0.84) compared to the standard Sign Method (0.64). This geometric alignment ensures the attack stays truer to the "real" adversarial direction.
  • Computational Efficiency: Unlike some transfer-boosting methods that require complex transformations or extra training, $S^2M$ adds negligible computational overhead, requiring only simple sorting and weighting steps.

Experimental Results

The researchers evaluated $S^2M$ using an ImageNet-compatible dataset across 16 different models, including six normally trained models (e.g., ResNet-152, Inception-v4) and ten models with advanced defenses (e.g., HGD, Feature Denoising).

The $S^2M$ variants consistently outperformed their vanilla counterparts:

  • Enhanced Transferability: On average, success rates improved by 5.1% for normally trained models and 12.8% for models with adversarial defenses.
  • Targeted Attack Performance: In challenging targeted attacks, the method improved success rates by up to 17.1% in ensemble settings.
  • Non-targeted Attack Performance: For simpler attacks, $S^2M$ variants outperformed vanilla FGSM by up to 19.1%.
Visual comparison of adversarial attacks: I-FGS$^2$M successfully misclassifies images where I-FGSM fails to transfer effectively.

Conclusion

The Staircase Sign Method ($S^2M$) provides a simple yet effective way to boost the transferability of adversarial attacks by re-introducing gradient magnitude information. While the method introduces a new hyperparameter $K$ (with $K=64$ found to be robust), its computational efficiency and significant performance gains make it a valuable tool for evaluating the robustness of DNNs. Future work may explore deeper theoretical justifications for the "staircase" function and the method's effectiveness in physical-world attack scenarios.

Summary updated

BibTeX
@misc{zhang2021staircase,
  author = {Qilong Zhang and Xiaosu Zhu and Jingkuan Song and Lianli Gao},
  title = {{Staircase Sign Method for Boosting Adversarial Attacks}},
  year = {2021},
  eprint = {2104.09722},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2104.09722},
}
Figure