Semantic Diversity Learning for Zero-Shot Multi-label Classification

Avi Ben-Cohen, Nadav Zamir, Emanuel Ben Baruch, Itamar Friedman, Lihi Zelnik-ManorICCV 2021

Abstract

Training a neural network model for recognizing multiple labels associated with an image, including identifying unseen labels, is challenging, especially for images that portray numerous semantically diverse labels. As challenging as this task is, it is an essential task to tackle since it represents many real-world cases, such as image retrieval of natural images. We argue that using a single embedding vector to represent an image, as commonly practiced, is not sufficient to rank both relevant seen and unseen labels accurately. This study introduces an end-to-end model training for multi-label zero-shot learning that supports semantic diversity of the images and labels. We propose to use an embedding matrix having principal embedding vectors trained using a tailored loss function. In addition, during training, we suggest up-weighting in the loss function image samples presenting higher semantic diversity to encourage the diversity of the embedding matrix. Extensive experiments show that our proposed method improves the zero-shot model's quality in tag-based image retrieval achieving SoTA results on several common datasets (NUS-Wide, COCO, Open Images).

1. Introduction

In standard multi-label classification, models are trained to recognize a fixed set of "seen" labels. Zero-shot learning (ZSL) extends this by requiring the model to identify "unseen" labels—categories never encountered during training—by leveraging semantic relationships via word embeddings.

A major bottleneck in current Zero-Shot Multi-label Classification (ZS-MLC) is Semantic Diversity. Most existing models compress an entire image into a single vector in the word-embedding space. While this works for simple images, it fails for complex scenes containing multiple unrelated concepts (e.g., "dog" and "rice"). A single vector often ends up in a semantic "middle ground," failing to accurately represent any specific concept. This research addresses this "semantic bottleneck" by moving beyond single-vector representations.

2. Proposed Method

The framework introduces three key innovations to handle semantic diversity within an end-to-end learning pipeline:

2.1 Principal Embedding Matrix ($A_i$)

Instead of a single vector, the vision backbone (TResNet-M) outputs a matrix of $M$ principal directions. Each row in this matrix acts as a different "ranking specialist" for distinct semantic concepts within the image.

2.2 Max-Ranking Loss and Regularization

To encourage specialization, the loss function uses a max operation over the matrix rows. When comparing a positive label to a negative one, only the row that best represents the positive label is updated. This allows different rows to focus on different objects or contexts. To ensure stability, a variance regularization term ($\mathcal{L}_{reg}$) constrains the rows to remain semantically coherent.

The end-to-end architecture showing the transformation of image features into a principal embedding matrix, followed by ranking and regularization losses.

2.3 Semantic Diversity Weighting (SDW)

Images with high semantic diversity (many different types of objects) are considered "harder" examples. The authors introduce a weighting factor in the loss function that up-weights these diverse images during training, forcing the model to better utilize its multi-row embedding matrix.

3. Experiments and Results

The model was evaluated on three major benchmarks: NUS-WIDE, MS COCO, and Open Images (v4).

3.1 Quantitative Performance

The proposed method achieved State-of-the-Art (SoTA) results across all datasets:

  • NUS-WIDE: Achieved a mean Average Precision (mAP) of 25.9, a significant jump from the previous best of 19.4 (LESA).
  • Open Images: Reached an mAP of 62.9 compared to the previous 41.7.
  • Generalized Zero-Shot Learning (GZSL): The model showed robust gains in the more difficult GZSL setting, where it must rank both seen and unseen labels simultaneously.

3.2 Qualitative Analysis

Qualitative results demonstrate the model's ability to delegate different rows of the embedding matrix to different concepts. For instance, in a complex scene, one row might identify "animals" while another focuses on "landscapes," maintaining high recall for labels that are far apart in word-vector space.

Qualitative examples comparing the proposed method against a single-vector baseline. The proposed method successfully identifies a broader range of semantically diverse tags.

4. Conclusion

By replacing the traditional single-vector embedding with a principal embedding matrix and introducing semantic diversity weighting, this framework effectively overcomes the semantic bottleneck in ZS-MLC. The model achieves significant performance gains without requiring expensive bounding-box annotations or complex attention clusters. Future work will focus on improving robustness to label noise in partially annotated datasets like Open Images.

Summary updated

BibTeX
@inproceedings{bencohen2021semantic,
  author = {Avi Ben-Cohen and Nadav Zamir and Emanuel Ben Baruch and Itamar Friedman and Lihi Zelnik-Manor},
  title = {{Semantic Diversity Learning for Zero-Shot Multi-label Classification}},
  booktitle = {IEEE/CVF International Conference on Computer Vision},
  year = {2021},
  url = {https://openreview.net/forum?id=Xvu1gUkx-aM},
}
Figure