Calibrating Deep Neural Networks using Focal Loss
- URL: http://arxiv.org/abs/2002.09437v2
- Date: Mon, 26 Oct 2020 14:22:17 GMT
- Title: Calibrating Deep Neural Networks using Focal Loss
- Authors: Jishnu Mukhoti, Viveka Kulharia, Amartya Sanyal, Stuart Golodetz,
Philip H.S. Torr, Puneet K. Dokania
- Abstract summary: Miscalibration is a mismatch between a model's confidence and its correctness.
We show that focal loss allows us to learn models that are already very well calibrated.
We show that our approach achieves state-of-the-art calibration without compromising on accuracy in almost all cases.
- Score: 77.92765139898906
- License: http://arxiv.org/licenses/nonexclusive-distrib/1.0/
- Abstract: Miscalibration - a mismatch between a model's confidence and its correctness
- of Deep Neural Networks (DNNs) makes their predictions hard to rely on.
Ideally, we want networks to be accurate, calibrated and confident. We show
that, as opposed to the standard cross-entropy loss, focal loss [Lin et. al.,
2017] allows us to learn models that are already very well calibrated. When
combined with temperature scaling, whilst preserving accuracy, it yields
state-of-the-art calibrated models. We provide a thorough analysis of the
factors causing miscalibration, and use the insights we glean from this to
justify the empirically excellent performance of focal loss. To facilitate the
use of focal loss in practice, we also provide a principled approach to
automatically select the hyperparameter involved in the loss function. We
perform extensive experiments on a variety of computer vision and NLP datasets,
and with a wide variety of network architectures, and show that our approach
achieves state-of-the-art calibration without compromising on accuracy in
almost all cases. Code is available at
https://github.com/torrvision/focal_calibration.
Related papers
- Calibrating Deep Neural Network using Euclidean Distance [5.675312975435121]
In machine learning, Focal Loss is commonly used to reduce misclassification rates by emphasizing hard-to-classify samples.
High calibration error indicates a misalignment between predicted probabilities and actual outcomes, affecting model reliability.
This research introduces a novel loss function called Focal Loss (FCL), designed to improve probability calibration while retaining the advantages of Focal Loss in handling difficult samples.
arXiv Detail & Related papers (2024-10-23T23:06:50Z) - Proximity-Informed Calibration for Deep Neural Networks [49.330703634912915]
ProCal is a plug-and-play algorithm with a theoretical guarantee to adjust sample confidence based on proximity.
We show that ProCal is effective in addressing proximity bias and improving calibration on balanced, long-tail, and distribution-shift settings.
arXiv Detail & Related papers (2023-06-07T16:40:51Z) - Bridging Precision and Confidence: A Train-Time Loss for Calibrating
Object Detection [58.789823426981044]
We propose a novel auxiliary loss formulation that aims to align the class confidence of bounding boxes with the accurateness of predictions.
Our results reveal that our train-time loss surpasses strong calibration baselines in reducing calibration error for both in and out-domain scenarios.
arXiv Detail & Related papers (2023-03-25T08:56:21Z) - AdaFocal: Calibration-aware Adaptive Focal Loss [8.998525155518836]
Training with focal loss leads to better calibration than cross-entropy.
We propose a calibration-aware adaptive focal loss called AdaFocal.
arXiv Detail & Related papers (2022-11-21T20:19:24Z) - DOMINO: Domain-aware Model Calibration in Medical Image Segmentation [51.346121016559024]
Modern deep neural networks are poorly calibrated, compromising trustworthiness and reliability.
We propose DOMINO, a domain-aware model calibration method that leverages the semantic confusability and hierarchical similarity between class labels.
Our results show that DOMINO-calibrated deep neural networks outperform non-calibrated models and state-of-the-art morphometric methods in head image segmentation.
arXiv Detail & Related papers (2022-09-13T15:31:52Z) - Sample-dependent Adaptive Temperature Scaling for Improved Calibration [95.7477042886242]
Post-hoc approach to compensate for neural networks being wrong is to perform temperature scaling.
We propose to predict a different temperature value for each input, allowing us to adjust the mismatch between confidence and accuracy.
We test our method on the ResNet50 and WideResNet28-10 architectures using the CIFAR10/100 and Tiny-ImageNet datasets.
arXiv Detail & Related papers (2022-07-13T14:13:49Z) - Deep Calibration of Interest Rates Model [0.0]
Despite the growing use of Deep Learning, classic rate models such as CIR and the Gaussian family are still widely used.
In this paper, we propose to calibrate the five parameters of the G2++ model using Neural Networks.
arXiv Detail & Related papers (2021-10-28T14:08:45Z) - On the Dark Side of Calibration for Modern Neural Networks [65.83956184145477]
We show the breakdown of expected calibration error (ECE) into predicted confidence and refinement.
We highlight that regularisation based calibration only focuses on naively reducing a model's confidence.
We find that many calibration approaches with the likes of label smoothing, mixup etc. lower the utility of a DNN by degrading its refinement.
arXiv Detail & Related papers (2021-06-17T11:04:14Z) - On Calibration of Mixup Training for Deep Neural Networks [1.6242924916178283]
We argue and provide empirical evidence that, due to its fundamentals, Mixup does not necessarily improve calibration.
Our loss is inspired by Bayes decision theory and introduces a new training framework for designing losses for probabilistic modelling.
We provide state-of-the-art accuracy with consistent improvements in calibration performance.
arXiv Detail & Related papers (2020-03-22T16:54:31Z)
This list is automatically generated from the titles and abstracts of the papers in this site.
This site does not guarantee the quality of this site (including all information) and is not responsible for any consequences.