A Two-Head Loss Function for Deep Average-K Classification

Average- K classification is an alternative to top- K clas-sification in which the number of labels returned varies with the ambiguity of the input image but must average to K over all the samples. A simple method to solve this task is to threshold the softmax output of a model trained with the cross-entropy loss. This approach is theoretically proven to be asymptotically consistent, but it is not guaranteed to be optimal for a finite set of samples. In this paper, we pro-pose a new loss function based on a multi-label classification head in addition to the classical softmax. This second head is trained using pseudo-labels generated by thresholding the softmax head while guaranteeing that K classes are returned on average. We show that this approach allows the model to better capture ambiguities between classes and, as a result, to return more consistent sets of possible classes. Experiments on two datasets from the literature demon-strate that our approach outperforms the softmax baseline, as well as several other loss functions more generally de-signed for weakly supervised multi-label classification. The gains are larger the higher the uncertainty, especially for classes with few samples.

Authors

Institutions

Publication Details

Published
2025-02-26
DOI
https://doi.org/10.1109/wacv61041.2025.00715
Citations
2
Primary Topic
Fault Detection and Control Systems
Type
article
Field-Weighted Citation Impact
2.43

Funders

Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
article

A Two-Head Loss Function for Deep Average-K Classification

Maximilien Servajean, Joseph Salmon, C. Garcin, Alexis Joly
2 citations
Fault Detection and Control Systems
2.43
article

A Two-Head Loss Function for Deep Average-K Classification

Maximilien Servajean, Joseph Salmon, C. Garcin, Alexis Joly
article en
2 citations

Abstract

Average- K classification is an alternative to top- K clas-sification in which the number of labels returned varies with the ambiguity of the input image but must average to K over all the samples. A simple method to solve this task is to threshold the softmax output of a model trained with the cross-entropy loss. This approach is theoretically proven to be asymptotically consistent, but it is not guaranteed to be optimal for a finite set of samples. In this paper, we pro-pose a new loss function based on a multi-label classification head in addition to the classical softmax. This second head is trained using pseudo-labels generated by thresholding the softmax head while guaranteeing that K classes are returned on average. We show that this approach allows the model to better capture ambiguities between classes and, as a result, to return more consistent sets of possible classes. Experiments on two datasets from the literature demon-strate that our approach outperforms the softmax baseline, as well as several other loss functions more generally de-signed for weakly supervised multi-label classification. The gains are larger the higher the uncertainty, especially for classes with few samples.

Centre National de la Recherche Scientifique (FR), Université de Montpellier (FR), Laboratoire d'Informatique, de Robotique et de Microélectronique de Montpellier (FR)
Agence Nationale de la Recherche
Climate action
Openalex Percentile: Top 12%
Fault Detection and Control Systems
2.43
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.