TkML-AP: Adversarial Attacks to Top-k Multi-Label Learning

Shu Hu, Lipeng Ke, Xin Wang, Siwei Lyu

Abstract

Adversarial attack research has predominantly focused on multi-class classification, leaving a gap in multi-label learning systems that output a ranked set of Top-$k$ labels. We present TkML-AP, a framework that overcomes the non-differentiable nature of ranking operations through a convex relaxation of the top-$k$ sum. Our approach enables efficient untargeted, targeted, and universal attacks. Experimental results on PASCAL VOC and MS COCO demonstrate that TkML-AP achieves significantly higher attack success rates with lower perturbation intensity compared to existing adaptations of multi-class attacks.

Introduction

Most adversarial attack research focuses on multi-class classification, where a model identifies a single label for an input. However, real-world systems—such as image tagging, web search engines, and document analysis—typically perform multi-label learning, returning a set of the Top-$k$ most relevant labels.

Attacking these systems is mathematically challenging. In standard classification, an attack only needs to make the ground-truth score lower than one other score. In a Top-$k$ multi-label setting, the attacker must manipulate the ranking of an entire set of labels. Because the ranking operation is discrete and non-differentiable, standard gradient descent cannot be directly applied. Previous attempts to bridge this gap often relied on sub-optimal heuristics or geometric approximations, resulting in large, visible distortions.

Methodology: The TkML-AP Framework

The core innovation of this work is TkML-AP (Top-$k$ Multi-Label Adversarial Perturbation). The framework tackles the "ranking hurdle" by introducing a continuous reformulation of the top-$k$ sum.

Convex Relaxation

Instead of optimizing against a hard, non-differentiable ranking, the authors utilize the "average of top-$k$" function. This acts as a tight, convex upper bound for the actual top-$k$ ranking, making the loss function differentiable and easier to optimize using iterative gradient descent.

Overview of the TkML-AP framework for untargeted and targeted attacks on a Top-3 multi-label classifier.

Attack Variants

  1. Untargeted Attacks (TkML-AP-U): The goal is to minimize perturbation while ensuring ground-truth labels are pushed out of the top-$k$ set. This is formulated as a Lagrangian optimization where the "least action" moves ground-truth labels just below the $(k+1)$-th ranked label.
  2. Targeted Attacks (TkML-AP-T): The attacker aims to "plant" a specific set of $k$ labels into the top results, forcing their scores to occupy the top $k$ ranks.
  3. Universal Attacks (TkML-AP-Uv): The framework can also identify a single, image-independent perturbation that disrupts top-$k$ predictions across any input image.

Experimental Evaluation

The methods were evaluated on two major computer vision benchmarks: PASCAL VOC 2012 (20 classes) and MS COCO 2014 (80 classes), using state-of-the-art architectures like Inception-v3 and ResNet50.

Key Results

Quantitative results demonstrate a significant advantage for TkML-AP over adapted baselines like kFool:

  • Efficiency and Stealth: In untargeted attacks on MS COCO ($k=3$), TkML-AP-U achieved a 100% Attack Success Rate (ASR) with a perturbation intensity nearly 11x lower than the kFool baseline. As shown in visual comparisons, TkML-AP perturbations are often invisible to the human eye.
  • Targeted Effectiveness: Even in "Worst Case" targeted scenarios—where the attacker forces the model to predict labels that originally had the lowest scores—the method maintained high success rates (e.g., ~73% ASR on MS COCO with $k=10$).
  • Dataset Complexity: Attacks were often more successful on the larger MS COCO dataset. The presence of more "distractor" labels (80 vs 20) provides more optimization "room" to displace ground-truth labels.
Comparison between kFool and TkML-AP-U across different k values, demonstrating that TkML-AP-U achieves successful ranking shifts with significantly lower noise.

Conclusion

TkML-AP demonstrates that Top-$k$ multi-label systems possess structural vulnerabilities that can be exploited with high precision. By focusing on the ranking boundary rather than just individual scores, the "least action" principle allows for highly effective, nearly invisible attacks. Future work should focus on extending these attacks to black-box settings and developing robust training methods specifically designed to protect the Top-$k$ ranking boundary.

Summary updated

BibTeX
@inproceedings{hu2021tkml,
  author = {Shu Hu and Lipeng Ke and Xin Wang and Siwei Lyu},
  title = {{TkML-AP: Adversarial Attacks to Top-k Multi-Label Learning}},
  booktitle = {IEEE/CVF International Conference on Computer Vision},
  year = {2021},
  doi = {10.1109/iccv48922.2021.00755},
}
Figure