Our new X account is live! Follow @wizwand_team for updates
WorkDL logo mark

Jaccard Metric Losses: Optimizing the Jaccard Index with Soft Labels

About

Intersection over Union (IoU) losses are surrogates that directly optimize the Jaccard index. Leveraging IoU losses as part of the loss function have demonstrated superior performance in semantic segmentation tasks compared to optimizing pixel-wise losses such as the cross-entropy loss alone. However, we identify a lack of flexibility in these losses to support vital training techniques like label smoothing, knowledge distillation, and semi-supervised learning, mainly due to their inability to process soft labels. To address this, we introduce Jaccard Metric Losses (JMLs), which are identical to the soft Jaccard loss in standard settings with hard labels but are fully compatible with soft labels. We apply JMLs to three prominent use cases of soft labels: label smoothing, knowledge distillation and semi-supervised learning, and demonstrate their potential to enhance model accuracy and calibration. Our experiments show consistent improvements over the cross-entropy loss across 4 semantic segmentation datasets (Cityscapes, PASCAL VOC, ADE20K, DeepGlobe Land) and 13 architectures, including classic CNNs and recent vision transformers. Remarkably, our straightforward approach significantly outperforms state-of-the-art knowledge distillation and semi-supervised learning methods. The code is available at \href{https://github.com/zifuwanggg/JDTLosses}{https://github.com/zifuwanggg/JDTLosses}.

Zifu Wang, Xuefei Ning, Matthew B. Blaschko• 2023

Related benchmarks

TaskDatasetResultRank
Semantic segmentationPASCAL VOC (val)
mIoU75.89
338
Semantic segmentationPascal VOC Original protocol 92 labeled images
mIoU76.43
48
Semantic segmentationPascal VOC Original protocol 1464 labeled images
mIoU82.27
36
Semantic segmentationPascal VOC 366 labels
mIoU79.16
19
Semantic segmentationPASCAL VOC 183 labeled images
mIoU78.47
6
Semantic segmentationPASCAL VOC (732 labeled images)
mIoU81.21
6
Showing 6 of 6 rows

Other info

Code

Follow for update