Query2Label: A Simple Transformer Way to Multi-Label Classification

Shilong Liu, Lei Zhang, Xiao Yang, Hang Su, Jun Zhu
7/22/2021
289 citations
cs.CV
transformer-attention

Official code: SlongLiu/query2labels (471 stars, Python, MIT, last commit 2022-03-18).

Abstract

This paper presents a simple and effective approach to solving the multi-label classification problem. The proposed approach leverages Transformer decoders to query the existence of a class label.

Show full abstract

The use of Transformer is rooted in the need of extracting local discriminative features adaptively for different labels, which is a strongly desired property due to the existence of multiple objects in one image. The built-in cross-attention module in the Transformer decoder offers an effective way to use label embeddings as queries to probe and pool class-related features from a feature map computed by a vision backbone for subsequent binary classifications. Compared with prior works, the new framework is simple, using standard Transformers and vision backbones, and effective, consistently outperforming all previous works on five multi-label classification data sets, including MS-COCO, PASCAL VOC, NUS-WIDE, and Visual Genome. Particularly, we establish $91.3\%$ mAP on MS-COCO. We hope its compact structure, simple implementation, and superior performance serve as a strong baseline for multi-label classification tasks and future studies. The code will be available soon at https://github.com/SlongLiu/query2labels.

View on arXivView PDF

Code Implementations(1)

MIT

Official implementation of paper "Query2Label: A Simple Transformer Way to Multi-Label Classification".

47168PythonJul 18, 20214 years agoMIT

Similar Papers

Cite this paper

@article{liu2021querylabel,
  title  = {Query2Label: A Simple Transformer Way to Multi-Label Classification},
  author = {Shilong Liu and Lei Zhang and Xiao Yang and Hang Su and Jun Zhu},
  year   = {2021},
  eprint = {2107.10834},
  archivePrefix = {arXiv},
  url    = {https://arxiv.org/abs/2107.10834}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2107.10834.svg)](https://codeofpaper.com/paper/2107.10834)

Discussion