Rethinking Calibration of Deep Neural Networks: Do Not Be Afraid of Overconfidence
Authors: Deng-Bao Wang
Lei Feng
Min-Ling Zhang
Venue: NeurIPS 2021 Poster (2021)
Keywords: Deep Neural Networks
Calibration
Regularization

Abstract: Capturing accurate uncertainty quantification of the prediction from deep neural networks is important in many real-world decision-making applications. A reliable predictor is expected to be accurate when it is confident about its predictions and indicate high uncertainty when it is likely to be inaccurate. However, modern neural networks have been found to be poorly calibrated, primarily in the direction of overconfidence. In recent years, there is a surge of research on model calibration by leveraging implicit or explicit regularization techniques during training, which obtain well calibration by avoiding overconfident outputs. In our study, we empirically found that despite the predictions obtained from these regularized models are better calibrated, they suffer from not being as calibratable, namely, it is harder to further calibrate their predictions with post-hoc calibration methods like temperature scaling and histogram binning. We conduct a series of empirical studies showing that overconfidence may not hurt final calibration performance if post-hoc calibration is allowed, rather, the penalty of confident outputs will compress the room of potential improvements in post-hoc calibration phase. Our experimental findings point out a new direction to improve calibration of DNNs by considering main training and post-hoc calibration as a unified framework. 

Rethinking Calibration of Deep Neural Networks: Do Not Be Afraid of Overconfidence
Deng-Bao Wang." Lei Feng,' Min-Ling Zhang
School of Computer Science and Engineering, Southeast University, Nanjing 210096, China Keey Laboratory of Computer Network and Information Integration (Southeast University), Ministry of Education, China
Coolleee of Computer Science, Chongqing University, Chongqing, 400044, China mangdb@seu.edu.cm Ifeng @cq..uu..cuun... zhangml @eu.eduu.cn
Abstract
Capturing accurate uncertainty quantification of the predictions from deep neural networks is important in many real-world decision-making applications. A reliable predictor expected to be accurate when is confident about its predictions and indicate high uncertainty when it is likely neural networks have been found to be poorly calibrated, primarily in the direction of overconfidence. In recent years, there is surge of research model calibration by leveraging implicit or explicit regularization techniques during training, which achieve well calibration performance by avoiding overconfident outputs. In study, we empirically found that despite the predictions obtained from these regular- ized models are better calibrated, they suffer from not being as calibratable, namely, it is harder to further calibrate these predictions with post-hoc calibration methods like temperature scaling and histogram binning. We conduct series of empirical studies showing that overconfidence may not hurt final calibration performance if post-hoc calibration is allowed, rather, the penalty of confident outputs will compress the room of potential improvement in post-hoc hoc calibration phase. Our experimental findings point out a new direction to improve calibration of DNNs by considering main training and post-hoc calibration as a unified framework.
be inaccurate. However, modern
Introduction
Modern over-parameterized deep neural networks (DNNs) have been shown to be very powerful modeling tools for many prediction tasks involving complex input patterns (37). In addition to obtaining accurate predictions, is also important to capture accurate quantification of prediction uncertainty from deep neural networks in many real-world decision decision-making applications. A reliable predictive model should be accurate when it is confident about its predictions and indicate high uncertainty when it is likely be inaccurate. However, modern DNNs trained with cross-entropy (CE) loss, despite being highly accurate, have been recently found to predict poorly calibrated probabilities, unlike traditional models trained with the same objective 4.. The overconfident predictions of DNNs could cause undesired consequences in safety-critical applications such as medical diagnosis and autonomous driving. Bayesian DNNs, which indirectly infer prediction uncertainty through weight uncertainties, have innate abilities to represent the model uncertainty 16.. But training and inferring those bayesian models computationally more expensive and conceptually more complicated than non-bayesian models, and their performance depends on the form of approximation made due computational constraints. Therefore, the study on uncertainty calibration of deterministic DNNs is important for both development practice and the perspective of understanding DNNs.
Post-hoc calibration addresses the miscalibration problem by equipping given neural network with an additional parameterized calibration component, which can be tuned with hold-out validation
Conresponding author
35th Conference on Neural Information Processing Systems (NcurIPS 2021).

---

dataset. Guo et al. 4 experimented with several classical calibration fixes and found that simple post-hoc methods like Temperature Scaling (TS)
25 and Histogram Bimning (HB) [33] are signif-
icantly effective for DNNs. The authors of [T0 and 27 proposed to learn linear and non-linear transformation functions to rescale the original output logits respectively, Gupta et al. [ proposed to obtain a calibration function by approximating the empirical cumulative distribution of output probabilities via splines. Kumar et al. [I] proposed to integrate TS with HB to achieve more stable calibration performance. Patel et al. (24] proposed a mutual information strategy to solve the severe sample-inefficiency issue in HB.
catiiiitttoonbaseeee binning
Recently, there is another line of research which presents a possibility of improving the calibration quality of deterministic DNNs via regularization during training. Guo al. [4] found that training DNNs with strong weight decay, which used to be the predominant regularization mechanism for training neural networks, has a positive impact on calibration. Müller et al. [19] showed that training models using the standard CE loss with label smoothing (28). instead of one-hot labels, has a very favourable effect on model calibration. Mukhoti et al. [8] proposed to improve uncertainty calibration by replacing the conventionally used CE loss with the focal loss proposed in [1] when training DNNs. It is important to note that CE loss with label smoothing and focal loss can be considered as standard CE with an additional maximum-ent minimizing these losses is equivalent to minimizing CE loss and maximizing the entropy of the predicted distribution simultancouslyy [18 [7]. Following these studies, recent work (7] explored several explicit regularization techniques for improving the predictive uncertainty calibration directly.
regularizer, which means
In this paper, we conduct an empirical study showing that despite the predictions obtained from the regularized models are well calibrated, they suffer from worse calibratable, namely, is harder to further improve the calibrate performance with post-hoe calibration methods like temperature scaling and histogram binning. We found that the regularization works by simply aligning the average confidence of the whole dataset to the accuracy with some specific regularization strengths, and cannot achieve fine-grained calibration. The comparison results show that when post-hoc calibration methods are allowed, the standard CE loss yields better calibration performance than those regularization methods. The extended experiments demonstrate that regularization will make DNNs lose the important information about the hardness of samples, which results in compressing the room of potential improvement by post-hoc calibration. Based on the experimental findings, we raise a natural question: can we design new loss functions in the opposite direction of these regularization methods to further improve the calibration performance? To this end, we propose inverse focal loss, and empirically found that it can learn more calibratable models in some cases compared with the CE loss, though it causes severer overconfidence problem without post-hoc calibration. Most importantly, our findings show that overconfidence of DNNs is not the nightmare in uncertainty qualification and point out a new direction to improve the calibration of DNNs by considering main training and post-hoc calibration as a unified framework.
2 Preliminaries
Let y {1,.... K} denote the label space and X Rd denote the feature space. Given sample (ar y) X' y sampled from an unknown distribution, learned neural network classifier f X' - A can produce a probability distribution for x on K classes, where A denotes the K - dimensional unit simplex. Here assume fo
composition of probabibaii K-way classifier gd and a softmax function a, i.c. fo = g" a. For a query instance æ, fo gives its ex (w))
probability of assigning it to label as Σ (x]])"([]]]' where g (x) denotes the i-th element of the logit vector produced by gº. Then, y = arg max, S (x) can be returned as the predicted label and I = max; f (z) can be treated as the associated confidence score.
Expected Calibration Error (ECE) For well-calibrated model, f is expected to represent the true probability of correctness. Formally, perfectly calibrated model satisfies Pp v/p- = p) = p for any p [0. 1]. In practice, ECE [20] is a commonly used calibration metric from finite samples. It works by firstly grouping all samples (let denote the number of samples) into A equally interval bins {mm) MM with respect to their confidence scores, then calculating the expected difference (acc(B..) avgCon((B..,
between the accuracy and average confidence: ECE = >M Bmll
Temperature Scaling By scaling the logits produced by 9d with temperature T, the sharpness
2

---

of output probabilities can be changed. Formally, after adding TS, the new prediction confidence (x)/T)
can be expressed as: & = max; Σ explo] (T) The temperature softens the output probability with T and sharpens the probability with T < 1. As T' + O, the output probability collapses to one-hot vector. As T - oo, the output probability approaches to a uniform distribution. After training of the model, T can be tuned on a hold-out validation set by optimization methods.
Histogram Binning is a non-parametric calibration approach. Given an uncalibrated model, all the prediction confidences of validation samples can be divided into mutually exclusive N bins [B,) according to a set of intervals (Tn, |= which partitions [0, 1]. Each bin is assigned confidence score 7), which can be simply set to corresponding accuracy of samples in each bin. the uncalibrated confidence ş of query instance falls into bin B,, then the calibrated confidence is '/n- The bins can be chosen by two simple schemes: equal size binning (uniformly partitioning the probability interval in [0, 1J) and equal mass binning (uniformly distributing samples over bins). Note that although the HB scheme is simple to implement and was demonstrated to achieve good calibration results in some datasets, it makes the predictor only produce very sparse confidence distribution, and compromises the many legitimately confident predictions.
3 Regularization in Neural Networks for Calibration
In recent years, there is surge of research on model calibration by leveraging implicit explicit regularization techniques during training of DNNs, which makes better calibrated predictions by avoiding the overconfident outputs. In this section, we firstly review three representative regularization methods and then empirically show their improvements on ECE compared with the baseline.
Label Smoothing is widely used as means to reduce overfitting of DNNs. The mechanism of LS simple: when training with CE loss, the oot label vector y is replaced with soft label vector y. whose elements can be formally denoted as Y5 (1 c)ы + +//K, K, Vi E {1, K}. where c > 0 is a strength coefficient. Müller et al. [19] demonstrated that label smoothing implicitly calibrates DNNs by preventing the networks from becoming overconfident. Let Lee denote the CE loss, then the following equation holds:
Lee U. fo) (1 co (y. fa) + (u,
This can be simply proved. Therefore, minimizing CE loss between smoothed labels and the model outputs is equivalent to adding a confidence penalty term, i.e., a weighted CE loss between the uniform distribution u and the model outputs, to the original CE loss.
Lp Norm in the Function Space is one of the explicit regularization methods for calibration investi- gated by the recent work 7 For a real number p 2 1, the L, Norm of a vector z with dimension n can be expressed as: || = C 1/2,) By adding Lp Norm of logits g" with a weighting coefficient a into final objective function, i.e. Li, fu) = Lee (y, fa) a ||g") I|, the function complexity of neural networks can be directly penalized during training.
Focal Loss is originally proposed to address the class imbalance problem in object detection. By reshaping the standard CE loss through weighting loss components of all samples according to how well the model fits them, focal loss focuses on fitting hard samples and prevents the easy samples from overwhelming the training procedure. Formally, for classification tasks where the target distribution is one-hot encoding, it is defined as: L,- = - - ",")" log Jo where y is a predefined coefficient. Mukhoti et al. [18] found that the models learned by focal loss produce output probabilities which are already very well calibrated. Interestingly, they also showed that focal loss is an upper bound of the regularized KL-divergence, which can be expressed formally as follows:
C Z (L(y) (H(
where Hpp) denotes the entropy of distribution p. This upper bound property shows that replacing the CE loss with focal loss has the effect of adding maximum-entropy regularizer.
3.1 Empirical Comparison
We conduct a comparison study of the above regularization methods on four commonly used datasets. We train ResNet-32 [6] models on SVHN 211, 10/1R-10/100 [9] and train 8-layer ID-CNN
3

---

Table 1: Comparison results (sea of ECE (%) with M = 15 and predictive accuracy (%) over random runs. The values with underline in first row represent the chosen coefficients of each regularization method on four datasets according to the ECE on test data.
Label Smoothing 0.01/0.05000000M
L1 Norm
Focal Loss 1/3/S/
Cross-Entropy
0.0110055000000000
ECE
3.03:00116
0.84
1.85
1.01
SVHN
Accuracy
95.00==0.27
95.21=0.23
95.29=0.13
94.77=0.19
ECE
6.43:10.22
2.72:10.32
0.93
3.00:10.26
CIFAR-10
Accuracy
90,46+0.233
90.09=0.41
90.06=0.500 0.99
87.84+0.17
ECE
19.53:10.36
2.27=00448
8.07
2.34
CIFAR-100
Accuracy
64.64+0.43
63.73+0067
63.07=0.299
60.36+0.44
ECE
20.82:t0.93
5.85=00644
13.31
3.82+:051
20 Newsgroups
Accuracy
72.85+0.89
72.81
73.61+00880
59.17+1.81
model on 20Newsgroups 13, using the standard CE loss and the above regularized losses respec- tively, with state-of-the-an learning policy settings (see implementation details in Appendix). For Norm regularization, we use L1 Norm, which has been shown effective for calibration despite its simple form 77. Table shows the comparison of these methods. Note that for each of the above three regularization methods, there is a coefficient, i.e., a and 7, controlling the strength of regularization, We conduct experiments using these methods with the following coefficient set- tings: {0.01, 0.03, 0.05, 0.07, 0.09} } for label smoothing, {0.001, 0.005, 0.01, 0.05, 0.1} for L1 Norm and {1. 3, 5, 7, 9} for focal loss. And we choose the best coefficient for each method and dataset, according to their ECE directly on test data.
From the results of Table 1, it is obvious that the regularization methods significantly decrease the ECE on all datasets, compared with the standard CE loss. The prediction accuracy results are also reported. When the strength coefficients of L, Norm and focal loss are large, their predictive performances are harmed. Especially, L1 Norm fails on CIFAR-100 and 20Newsgroups when 0.05, thus is chosen from (0.001,0.005,0000) on these two datasets.
4 Does Regularization Really Help Calibration?
As shown by the above empirical results, the regularization methods do help the calibration of DNNs during training, especially alleviate the overconfidence issue caused by the standard CE loss. In this section, we empirically investigate their calibration performance when integrating them with post-hoc calibration. After training, we use the post-hoc methods TS and HB to further calibrate the output probabilities. For TS, we simply search the best temperature in the temperature pool (0.01,0.02...,100 10) on the validation set (see data splits Appendix). For HB, we use equal size binning scheme on the t prediction of all classes with bin number set as 15. The experimental details used in this section are the same with those in Section 3.
Comparison Results Table 2 shows the comparison results of ECE with the help of TS and HB. We can see that: (1) The standard CE loss achieves the best calibration performance on most cases. (2) The searched temperatures of models trained with the CE loss are significantly higher than those of other losses, which indicates that CE loss causes higher predictive confidences. These results demonstrate that despite the regularized models can produce better calibrated predictions, is harder to further improve them with post-hoc calibration methods after main training. In other words, the penalty of confident predictions will compress the room of potential improvement by post-hoc methods. We also conduct experiments on CIFAR-10 and CIFAR- 100 using deeper model ResNet- 10 and similar comparison results are obtained (see Appendix Table A).
Coefficient Sensitivity Figure I(a), 1(b) and (c)) illustrate the ECEs of these three regularization methods with varied coefficient strengths. As we can see, since the complexity of the used datasets are different, the best coefficients of these methods markedly vary across the datasets, and small change on these coefficients may cause large ECE increase. This means that we need to carefully choose the coefficient of each method when employing them on new datasets, to achieve good calibration. We can also observe that for SVHN on which the accuracy highest among four datasets, the regularization methods obtain lowest ECE with small coefficients. For CIFAR- 100 and 20Newsgroups, on which the

---

Table 2: Comparison results (mean=std) of ECE (%) with M = 15 over 5 random runs. The
coefficients of the regularization methods on each dataset are same with those in Table 1. a/a and v/v indicate that the average ECE of regularization methods are higher and lower than standard CE, where and are based on two-sample t-test at 0.05 significance level.
Label Smoothing 10110.05/0000000
La Norm 0010005000100000
Focal Loss 1/3///5
Cross-Entropy
with TS Temperature
0.72
0.1 1.11
1.22:40.88 1.12
0.80:10,22
1.82
1.10
SVHN
with HB
0.68++0.22
0.70
0.73++.220
0.
with TS Temperature
0,95-+0.19
0.54+0.111
2.71+0.364
1.39-+0.28
2.51
0.96
0.95
0.76
CIFAR-10
with HB 0.74=00.15
0.94
1.16+0.54
1.65++031
with TS Temperature
0.3
0.37:0.27
3.92+0.211 1.24
2.14:t0.44 A
2.19
1.04
0.97
CIFAR-100
with HI
1.27.10.27
2.022
1.56.10.444
1.83.00300
with TS Temperature
3.11::033 4.18
5,22:10.60.
2.71=0.255
3.77:10.44
1.06
1.48
0.89
20 Newsgroups
with HB
2.52++0.47
2.67-
2.61
3.16:H0.97
Sith
34
u0 Nermir
CPAN300
G'AN330
200
0.1
0.00
0.05
1.00
0.01
0.00
0.01
0.00
0.1
ao you iie alr nos (d) Best cocflicients
(a) LS with varied
(b) L, with variod cz
(c) FL with varied
Figure 1: (a-c): ECE (%) with M 15 of regularization methods with controlled regularization strength. (d): Best coefficients of regularization methods with respect to ECE with controlled training data size.
accuracy relatively lower, the regularization methods need larger coefficients for better calibration. Based on this observation, we conduct another experiment for investigating the correlation between the regularization coefficients and accuracy. We learn networks on CIFAR- 10 by controlling training data size, which leads to varied predictive accuracies, and choose the best coefficient for each case. Here, 6, a and y are chosen from (0.01, 0.02, ..., 0.25], J. (0.01, 0.02. ..., 0.1} and {1,3, 7,93 respectively. Figure 2(d) shows that with the increase of training data size, which results in increase of predictive accuracy, the best coefficients of the regularization methods keep decreasing.
We use reliability diagram to visually represent the gap between predictive confidence and accuracy of each method. Due to the space limitation, here we only present the diagrams of CIFAR-10, 10, and the rest figures are presented in Appendix. We can see that these visual results are similar with the comparison results of ECE reported in Table 2. Although the gap between confidence and accuracy is large when using the standard CE loss, it can be significantly diminished after using TS. However, the improvements of TS for the regularization methods are not obvious. Most importantly, no matter whether TS is used or not, the regularization methods suffer from overeonfidence on samples which have high predictive uncertainty, especially on label smoothing and L1 Norm, which contradicts the traditional view. Combining with the observation in Figure 2(d), it is indicated that the regularization methods work by simply aligning the average predictive confidence of the whole dataset to the accuracy with some specific regularization strengths, and does not produce fine-grained calibration with respect to the difference of samples.
Reliability Diagram
Impact of Validation Size We also wonder how does the validation data size impact the post-hoc calibration. Figure 3 shows the ECE results with controlled validation data size. We
that quite low ECE can be obtained with only a small size of validation data when using TS, which offers high efficiency for practice development. Relatively, HB needs more validation samples to obtain better calibration performance. Nevertheless, the standard CE loss stably achieves better calibration across varied validation data size with both TS and HB.
5

---

T-2.58
T-0.94
T-0 94
T-0.78
AA
Cherlon Prerirnlsleer
Aocurary
Accuracy
Aspuracy
EG
+.5
455
Contidence
Confidence
Contidence
Comteence
(a) CE
(b) L.S, 0.05
(c) L1 Norm, 0.05
(d) FL, m
Figure 2: Reliability diagrams of each methods (after TS calibration) on CIFAR-10. The results are chosen from one of the 5 random runs of Table 1. Darker color of bars indicates that more samples are assigned with the corresponding confidence intervals.
Pecil Loos
Paoeitess y
Pocaltess
Pacelass
Harn 6.42
tomm 85
Horn a.
14
200 Siriion
dosiinn
A
Szc Valdation
vee
(a) SVHN, TS
(b) CIFAR-10, TS
(c) CIFAR-1O0, TS
(d) 20Newsgroups, TS
Nare 6.0
Karr 8.
Li Horn 2.12
Li Nas
1800
Volidstinn set
set
(c) SVHN, HR
(f) CIFAR-10, 10, HB
(g) CIFAR- 100, HR
(h) 20Newsgrups, HB
Figure 3: ECE (%) (after post-hoc calibration) with of regularization methods with controlled validation data size.
5 From Calibrated to Calibratable: A Closer Look
The results reported in above section show the degradation of regularization methods when integrating them with post-hoc calibration methods, which indicates that though regularization helps DNNs obtain well-calibrated predictions, it makes these predictions worse calibratable, In this Section, we further investigate this phenomenon by a series of illustrative experiments. We firstly attempt to empirically understand the reason of the calibration degradation from the view of information loss. Then, we propose an inverse form of focal loss to give closer look at the correlation between the loss functions used in training and the calibration performance. The implementation details used in this section are also the same with those in Section 3.
5.1 Information Loss of Regularized Models
ECE among Epochs We start by investigating the ECES of temperature-scaled outputs over epochs during model training. To avoid the impact of the bias of validation data, we directly search the best temperature on test data in each training epoch. We denote the corresponding ECE with this searched temperature as optimal ECE, which is the lower bound of ECE with temperatures searched on validation data. Figure 4 shows the curves of optimal ECE during epochs using label smoothing with different smoothing coefficients. We can observe that the optimal ECE rises after some learning epochs: On SVHN and CIFAR-10, it starts to significantly rise around the 10th epoch, and on CIF and 20Newsgroups, tends to rise after 100 and 50 epochs, where the learning rate drops by a factor of 10. Another observation is that larger smoothing strength results in worse calibration performance and more remarkable (also earlier) ECE rising. According to the memorization effect
[35), DNNs usually learn casy samples at the early stage of training and tend to fit the hard ones later.

---

ECE
14
15
15 36
Epoch
(a) SVHN
(b) CIFAR-10
(c) CIFAR-I00
(d) 20Newsgroups
Figure 4: Curves of optimal ECE (%) during learning epochs using label smoothing with different coefficients. Dark colors show the mean results of random runs and light colors show the ranges between minimal and maximum results of runs.
Densky
(a) CE
(b) LSS c= 0.05
(c) L1, a=0.05
(d) FL, 7
Denety
(c)
(1) LS, 0.09
g Lg =00.1
(h) FL. 5
Figure 5: Histograms of maximum logits produced from models trained with different methods. Different colors of bars represent distributions of samples with different learned epochs. The first row and second row results of CIFAR-IO and CIFAR-100 respectively.
Therefore, simple conjecture for the ECE rising is that after some learning epochs, DNNs start to fit hard samples, at the same time the regularizer would penalize the confidences of casy samples, which makes the predictive confidences of those easy and hard samples difficult to be distinguished. Similar phenomenon is also observed when using T,, Norm (see Appendix Figure A(a-d)) except 20Newsgroups dataset, on which large norm coefficient will hurt the calibration. For focal loss (see Appendix Figure A(e-h)), the optimal ECEs trained with large regularization strengths keep high without the remarkable rising.
We use histograms to visualize what the patterns of model outputs learned with different methods look like. Before that, we define learned epoch of an individual training sample as the epoch, since which the sample can be correctly classified till the final learning epoch. As we mentioned above, DNNs usually learn hard samples after easy ones, hence the learned epoch of sample can be used to indicate its corresponding hardness degree to be learned. Based on this, we want to investigate if the samples with different hardness degrees can be distinguished by model itself after training. To this end, record the learned epochs of all training samples of CIFAR-10 and CIFAR- 100 during training and statistic the distributions of their maximum logit outputs (i.c. max, of (z)). As shown in Figure 5, the logits of models trained with the standard CE loss cover much larger ranges, and the regularization methods compress the distributions too tight without distinction between samples with different learned epochs, especially in label smoothing and L, Norm. This visual observation further confirms that the regularization confidence of the whole dataset low level with specific regularization strength. This will result in loss of the important information about the hardness of samples as an undesirable side effects, and compress the room of potential improvement by post-hoc calibration. On the contrary, models trained
Histogram of Logits
DNNs works by only penalizing the
"This concept is inspired by the related work (30]. in which the authors qualify a sample unforgettable if it is learned some epoch and experience forgetting events during training.
7

---

Hour
Peafford
Confidence
SYHK
JD
2ihengrouds
SVHN
CF
20Nowproups
(a) Loss functions
(b) Predictive accuracy
(c) ECE without post-hoc calibration
M
THeSA fook
10
Teeits Food
y-t 1-00
Synn
CIFAR-ID
SPAR-100
20hemgroupa
SWINN
DIARR13
CIFAR 100
2chongrruus
(d) Best temperatures
(c) ECE after TS
(f) ECE after HB
Figure 6: (a): Visual representation of focal loss, CE loss and inverse focal loss. (b): Predictive accuracies (%) of different methods. (c): ECEs (%) with M 15 of different methods without post-hoc calibration. (d): Searched temperatures on validation data. (e-f): ECEs (%) with M = 15 of different methods with the help of post-hoe calibration.
with the standard CE loss manage preserve this information to certain extent during training, hence achieve better results after post-hoc calibration.
5.2 Is Cross-Entropy the Best for Calibration?
Based experimental findings, natural question is that can design some loss functions in the opposite direction of these regularization methods to further improve the calibration? For label smoothing and Lp Norm, negative values. However, we empirically found this will cause extremely low predictive accuracies failures of training using only very small weighting coefficients. Fortunately, can design inverse version of focal loss without prediction degradation by mimicking the original focal loss Recall the form of focal loss, see that it works by assigning larger weights the samples with smaller confidences. This makes the optimizer pay more attention to those hard samples when updating model parameters. Actually, this weighting scheme also implicitly exists in the standard CE loss, and this can be expressed by the gradients of CE loss function w.r.t. model parameters 0:
simply set the regularization coefficients of these methods as
@Lee (x))
Vofg(z))
(3)
00
f((x)
where the factor term Tyaa indicates that samples with smaller confidences are weighted larger in gradient calculation. Opposite the principle of focal loss, we propose inverse focal loss as follows:
C
f log f
(4)
By a simple modification on the weighting term original focal loss, the inverse focal loss assigns larger weights the samples with larger output confidences. Similar with original focal loss, the choice of coefficient 7 has a huge impact on the property of this loss. In Figure 6(a). we plot the curves of inverse focal loss with varied and also plot the standard CE loss and focal loss for comparison. We can see that different from the original focal loss, the curves of inverse focal loss are steeper when confidence is large. and larger gives steeper curves.
We conduct another experiment to evaluate the inverse focal loss, and also investigate what will happen when increase its coefficient 7. Figure 6(C) shows the ECE results without post-hoc calibration. The ECEs of inverse focal loss are larger than CE and focal loss in most cases. This is consistent to expectation since inverse focal loss aggravates the overconfidence issue of DNNs by weighting larger on the easy samples. Figure 6(e) and 6(f) show the ECE results with the help of
As the reviewer suggested, there already exists "inverse focal loss" in the literature, which was introduced totally different context and using a different mathematical expression, but similar motivation [15]

---

post-hoc calibration. When using HB, the ECEs of inverse focal loss are worse than CE on SVHN and CIFAR-10, 10, while better than CE on CIFAR- 100. Generally speaking, there is no clear trend when we increase 7. More interesting results appear when using TS: (1) On CIFAR-16 10 and CIFAR-100, the ECE results of inverse focal loss are better than that of the standard CE loss; and (2) there bescend-then-asceme
trend from focal loss with 7 3 to inverse focal loss with = 3. From these observations, we may say that the best loss function for calibration is varied across different tasks according to the characteristics of datasets. On SVHN, which is a relatively easy dataset, standard CE loss yields pretty good results; on CIFAR-I0 and CIFAR-100, 100, which is more complex and difficult, the best results are obtained using inverse focal loss: on 20Newsgroups, which has fewest training samples among four datasets, the best result is obtained when using focal loss with y y= 1. The searched temperatures when using TS are presented in Figure 6(d). The increasing of best temperatures indicates that the overconfidence problem is severer when using inverse focal loss with larger 7. The predictive accuracies presented in Figure 6(a). As is shown that inverse focal loss yields highly competitive results compared with the standard CE loss on SVHN, CIFAR- 10 and CIFAR-100. On 20Newsgroups, when using large 5, the predictive performance of inverse focal loss is worse than the CE loss.
Related Work
In machine learning, calibration has long been studied 25| 33 34 22 and many classical methods, like Platt Scaling (25] and Histogram Binning [333. have been proposed in the literature. In recent years, deep neural networks trained with commonly used CE loss, have been empirically found to predict poorly calibrated probabilities. The early researches for this problem focus on bayesian models 22 16 D. which indirectly infer prediction uncertainty through weight uncertainties. But training and inferring the bayesian DNNs are computationally more expensive and conceptually more complicated than deterministic DNNs. Therefore, the uncertainty qualification of the non- bayesian models has always been an important topic, which also attracts lot of researchers from the perspective of understanding DNNs.
Guo et al. 4 systematically investigated the miscalibration problem of the deterministic DNNs and empirically compared several conventional post-hoc calibration fixes. Two key findings are suggested in their paper: (1) Increasing model capacity and regularization strength negatively affect the calibration. (2) Simple post-hoc methods like TS 25 and HB [3] can reduce the calibration error to a quite low level. Following their work, there is surge of research that proposed new post-hoc calibration methods [10] 27 [T 24 [36 (6). Different from post-hoe calibration methods,
another line of research aims to learn calibrated networks during training by modifying the training process (29 12 8. Thulasidasan er al. (29] found that DNNs trained with mixup are significantly better calibrated than DNNs trained in the regular fashion. Kumar et al. [12) proposed a RKHS kernel based measure of calibration that is efficiently trainable alongside the standard CE loss, which can minimize an explicit calibration error during training. Krishnan and Tichoo (8) introduced differentiable accuracy versus uncertainty calibration loss function that allows a model to learn to provide well-calibrated uncertainties, in addition to improved accuracy. Recently, inspired by the findings in [4, several studies were proposed to leverage the regularization of DNNs to improve calibration performance during training [19 18 77 As we described in Section 3, these implicit or explicit regularization techniques can improve calibration by penalizing the predictive confidences of DNNs. It is worth nothing that besides the studies on improving calibration performance, there are also several studies that focus on the measure of calibration performance 23 31
7 Conclusion
In this work, we investigate the uncertainty calibration problem of DNNs by series of experiments. The empirical study shows that despite the predictions obtained from the regularized models are better calibrated, worse results would be obtained if we employ post-hoc calibration methods on these regularized models. Extended experiments demonstrate that the regularized DNNs will lose the important information about the hardness of samples, which results in the harm of post-hoc calibration. Based on the experimental observations, we design a new loss function in the opposite direction of previous regularization methods, and empirically show the superiority of this loss in calibration with the help of host-hoc methods, even though it causes severer overconfidence issue in
9

---

the main training phase. Our findings suggest that overconfidence of DNNs is not the nightmare in model calibration and point out a new direction to improve the calibration performance of DNNs by unified framework. Moreover, the study of
considering main training and post-hoc calibration the phenomena of deep learning uncertainty under distribution shift is very interesting as one of the future work, since the behaviour with distribution shifts might be most important in practice.
8 Acknowledgments
The authors wish to thank the anonymous reviewers for their helpful comments and suggestions. This work was supported by the National Science Foundation China (62176055). the Postgraduate Research & Practice Innovation Program of Jiangsu Province (KYCX21 0151) and the China University S&T Innovation Plan Guided by the Ministry of Education. We thank the Big Data Center of Southeast University for providing the facility support the numerical calculations in this paper.
References
[1] Charles Blundell, Julien Cornebise, Koray Kavukcuoglu, and Daan Wierstra. Weight uncertainty in neural network. In International Conference on Machine Learning, pages 1613-1622, 2015.
[2] Yarin Gal and Zoubin Ghahramani. Dropout as bayesian approximation: Representing model uncertainty in deep learning. In International Conference on Machine Learning, pages 1050-1059, 2016.
[3] Alex Graves. Practical variational inference for neural networks. In Advances in Neural Information Processing Systems, pages 2348-2356, 2011.
[4] Chuan Guo, Geoff Pleiss, Yu Sun, and Kilian Q Weinherger. On calibration of modern neural networks. In International Conference on Machine Learning, pages 1321-1330, 2017.
[5) Kartik Gupta, Amir Rahimi, Thalaiyasingam Ajanthan, Thomas Mensink, Cristian Sminchis- escu, and Richard Hartley. Calibration of neural networks using splines. In International Conference on Representation Learning, 2021.
[6] Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Deep residual learning for image recognition. In IEEE Conference on Computer Vision and Pattern Recognition, pages 770-778. 2016.
[7] Taejong Joo and Uijung Chung. Revisiting explicit regularization neural networks for well-calibrated predictive uncertainty. arXiv:2006.06399, 2021.
[8] Ranganath Krishnan and Omesh Tickoo. Improving model calibration with accuracy versus uncertainty optimization. In Advances in Neural Information Processing Systems, pages 18237- 18248, 2020.
[9] Alex Krizhevsky. Learning multiple layers of features from tiny images. In Tech Report, 2009.
[10] Meelis Kull, Miquel Perello Nieto, Markus Kängsepp. Telmo Silva Filho, Hao Song, and Peter Flach. Beyond temperature scaling: Obtaining well-calibrated multi-class probabilities with dirichlet calibration. In Advances in Neural Information Processing Systems, pages 12295-12305. 2019.
[11] Ananya Kumar, Percy S Liang, and Tengyu Ma. Verified uncertainty calibration. In Advances in Neural Information Processing Systems, pages 3787-3798, 2019.
[12] Aviral Kumar. Sunita Sarawagi. and Ujjwal Jain. Trainable calibration measures for neural networks from kernel mean embeddings. International Conference on Machine Learning, pages 2805-2814 2018.
[13] Ken Lang. Newsweeder: Learning to filter netnews. In International Conference on Machine Learning, pages 331-339, 1995.
10

---

[14] Tsung- Yi Lin, Priya Goyal, Ross Girshick, Kaiming He, and Piotr Dollár. Focal loss for dense object detection. In IEEE International Conference on Computer Vision, pages 2980-29888 2988. 2017.
[15] Mingsheng Long, Zhangjie Cao, Jianmin Wang, and Michael I Jordan. Conditional adversarial domain adaptation. In International Conference on Neural Information Processing Systems, pages 1647-1657, 2018
[16] Wesley Maddox, Pavel Izmailov, Timur Garipov, Dmitry Vetrov, and Andrew Gordon Wilson. A simple baseline for bayesian uncertainty in deep learning. In Advances in Neural Information Processing Systems, pages 13153-13164, 2019.
[17] Clara Meister, Elizabeth Salesky, and Ryan Cotterell. Generalized entropy regularization or: There's nothing special about label smoothing. In Annual Meeting of the Association for Computational Linguistics, pages 6870-6886, 2020.
[18] Jishnu Mukhoti, Viveka Kulharia, Amartya Sanyal, Stuart Golodetz, Philipp Torr and Puneet Dokania. Calibrating deep neural networks using focal loss. In Advances in Neural Information Processing Systems, pages 15288-15299, 2020.
[19] Rafael Müller, Simon Kornblith, and Geoffrey Hinton. When does label smoothing help? In Advances in Neural Information Processing Systems, pages 4696-4705, 2019.
[20] Mahdi Pakdaman Nacini, Gregory Cooper, and Milos Hauskrecht. Obtaining well calibrated probabilities using bayesian binning. In AAAI Conference on Artificial Intelligence, pages 2901-2901 2015.
[21] Yuval Netzer, Tao Wang, Adam Coates, Alessandro Bissacco, Bo Wu, and Andrew Y. Ng. Reading digits in natural images with unsupervised feature learning. In Advances in Neural Information Processing Systems Workshops, 2011.
[22] Alexandru Niculescu-Mizil and Rich Caruana. Predicting good probabilities with supervised learning. In International Conference on Machine learning, pages 625-632, 2005.
[23] Jeremy Nixon, Michael W. Dusenberry, Linchuan Zhang, Ghassen Jerfel, and Dustin Tran. Measuring calibration in deep learning. In IEEE Conference on Computer Vision and Pattern Recognition Workshops, pages 38-41, 2019.
[24] Kanil Patel, William Beluch, Bin Yang. Michael Pfeiffer, and Dan Zhang. Multi-class uncertainty calibration via mutual information maximization-ban binning. In International Conference on Representation Learning, 2021.
[25] John Platt et al. Probabilistic outputs for support vector machines and comparisons to regularized likelihood methods. Advances in Large Margin Classifiers, 10(3):61 1999.
[26] Amir Rahimi, Kartik Gupta, Thalaiyasingam Ajanthan, Thomas Mensink, Cristian Sminchis- escu, and Richard Hartley. Post-hoc calibration of neural networks. arXiv:2006. 2280, 2020.
[27] Amir Rahimi, Amirreza Shaban, Ching-An Cheng, Richard Hartley, and Byron Boots. Intra order-preserving functions for calibration of multi-class neural networks. In Advances in Neural Information Processing Systems, 2020.
[28] Christian Szegedy, Vincent Vanhoucke, Sergey loffe, Jon Shlens, and Zbigniew Wojna. Rethink- ing the inception architecture for computer vision. In IEEE Conference on Computer Vision and Pattern Recognition, pages 2818-2826 2016.
[29] Sunil Thulasidasan, Gopinath Chennupati. Jeff A. Bilmes, Tanmoy Bhattacharya, and Sarah Michalak. On mixup training: Improved calibration and predictive uncertainty for deep neural networks. In Advances in Neural Information Processing Systems, pages 13888-13899, 2019.
[30] Mariya Toneva, Alessandro Sordoni, Remi Tachet des Combes, Adam Trischler, Yoshua Bengio, and Geoffrey J. Gordon. An empirical study of example forgetting during deep neural network learning. In International Conference on Representation Learning, 2019.
11

---

[31] Juozas Vaicenavicius, David Widmann, Carl R. Andersson, Fredrik Lindsten, Jacob Roll, and Thomas B. Schön. Evaluating model calibration classification. In International Conference on Artificial Intelligence and Statistics, pages 3459-3467, 2019.
[32] David Widmann, Fredrik Lindsten, and Dave Zachariah. Calibration tests in multi-class classification: A unifying framework. In Advances in Neural Information Processing Systems, pages 12236-1221 12246, 2019.
[33] Bianca Zadrozny and Charles Elkan. Obtaining calibrated probability estimates from decision trees and naive bayesian classifiers. In International Conference on Machine Learning, pages 609-616, 2001.
[34] Bianca Zadrozny and Charles Elkan. Transforming classitier scores into accurate multiclass probability estimates. In ACM SIGKDD International Conference on Knowledge Discovery and Data Mining, pages 694-699, 2002.
[35] Chiyuan Zhang, Samy Bengio, Moritz Hardt, Benjamin Recht, and Oriol Vinyals. Understanding deep learning requires rethinking generalization. In International Conference on Representation Learning, 2017.
[36] Jize Zhang, Bhavya Kailkhura, and T Yong-Jin Han. Mix-n-match: Ensemble and compositional methods for uncertainty calibration in deep learning. In International Conference Machine Learning, pages 11117-11128, 2020.
[37] Zhi-Hua Zhou. Why over-paramettrizzaion of deep neural networks does not overfit? Science China Information Sciences, 64(1):1-3, 2021.
12


Reviews:
[{"review_id": "6XYspH75iwg", "reviewer": "Reviewer_cRRY", "summary": "The paper is insufficient and wasn't able to support its main claims. Needs more work.", "questions": "", "limitations": "", "rating": 6, "confidence": 4, "soundness": null, "presentation": null, "contribution": null, "strengths": "", "weaknesses": "", "quality": null, "clarity": null, "significance": null, "originality": null, "strengths_and_weaknesses": "", "was_revised": false, "final_justification": "", "rebuttal": "", "claims_and_evidence": "", "methods_and_evaluation_criteria": "", "theoretical_claims": "", "experimental_designs_or_analyses": "", "relation_to_broader_scientific_literature": "", "essential_references_not_discussed": "", "other_strengths_and_weaknesses": "", "other_comments_or_suggestions": "", "questions_for_authors": "", "summary_of_paper": "", "summary_of_recommendation": "", "technical_quality": "", "clarity_of_presentation": "", "potential_impact": "", "robotics_focus": "", "quality_of_limitations": "", "questions_for_rebuttal": "", "reasons_to_accept": "", "reasons_to_reject": "", "questions_to_authors": "", "main_review": "## Review\nThis paper made three main points.\n1. learning calibrated predictions during training via regularization (e.g., focal loss) improves calibration, but if we are allowed to use post-hoc techniques on top, this approach performs worse than standard cross-entropy training in terms of final calibration performance.\n2. those regularization methods align the average confidence to accuracy without achieving fine-grained calibration, which the authors argue is the reason of the underperformance.\n3. based on the point 2, they propose inverse focal loss which *de-regularize* that should improve calibration performance when adding post-hoc techniques.\n\n##  Questions and Comments\n- First of all, I don't see very strong signal in supporting point 1 especially when looking at the Appendix tables. Pick table C as an example, focal loss with gamma = 1 and L1 norm with alpha=0.001 are actually better than CE with TS.\n- I suspected the search space for each regularization method could also be flawed. For instance in table C, L1 Norm would probably have better calibration performance if the alpha is allowed to be smaller than the current range, according to the trend.\n- The reasoning behind point 2 is not  very clear - the authors showed the regularization methods compress to much the histogram of logits but it seems not clear that the observation leads to the conclusion that the regularization methods are simply aligning the average confidence of whole dataset to accuracy (after all, the corresponding reliability diagrams didn't seem to suggest that is the case)\n- suppose the point 2 is valid, the proposed inverse focal loss should open more room for post-hoc to improve - however as the authors also admitted, that wasn't the case. Would be interesting to see if the new loss actually widen the histogram of logits.", "summary_of_the_paper": "", "summary_of_the_review": "", "strength_and_weaknesses": "", "limitations_and_societal_impact": "yes in the appendix", "review_text": "", "extra_scores": {"needs_ethics_review": "No", "ethics_review_area": "", "time_spent_reviewing": "5"}, "extra_text": {}}, {"review_id": "5RxllL8-dKr", "reviewer": "Reviewer_hfRt", "summary": "The work studies methods that improve calibration during training e.g., label smoothing, logits regularization. Work shows that while these methods improve calibration compared with conventional training, they are less liable to improve from post-hoc calibration, such as temperature scaling e.g., TS >> label smoothing/etc. + TS. The work suggests some explanations of this effect and proposes an inverse focal loss that based on the proposed intuition might promote the quality of a post-hoc calibration.  ", "questions": "", "limitations": "", "rating": 7, "confidence": 4, "soundness": null, "presentation": null, "contribution": null, "strengths": "", "weaknesses": "", "quality": null, "clarity": null, "significance": null, "originality": null, "strengths_and_weaknesses": "", "was_revised": false, "final_justification": "", "rebuttal": "", "claims_and_evidence": "", "methods_and_evaluation_criteria": "", "theoretical_claims": "", "experimental_designs_or_analyses": "", "relation_to_broader_scientific_literature": "", "essential_references_not_discussed": "", "other_strengths_and_weaknesses": "", "other_comments_or_suggestions": "", "questions_for_authors": "", "summary_of_paper": "", "summary_of_recommendation": "", "technical_quality": "", "clarity_of_presentation": "", "potential_impact": "", "robotics_focus": "", "quality_of_limitations": "", "questions_for_rebuttal": "", "reasons_to_accept": "", "reasons_to_reject": "", "questions_to_authors": "", "main_review": "More detailed discussion:\n\n1. The main effect (Tables 1,2). The work noticed that techniques like label smoothing benefit less from post-hoc calibration. In the end, it is likely more beneficial, to use conventional training with post-hok calibration instead.\n\nComment 1: No question asked, the effect is interesting, and it needs to see the light of the community.\n\n2.  Explanations (lines 228-244). To the best of my understanding, the hypothesis is the following: conventional training preserves more information about the relative complexity of examples compared to label smoothing and other regularization-based methods. This might be the key factor behind the main effect. Fig 5 presents histograms of max logits(x_i) to confirm that.\n\nComment 2: There is no clear evidence that \"preserve information\" leads to better calibration. We do observe both, but there is no indication of a casual relationship in any direction. Thus, I find the finding of this part unjustified e.g., \"try to preserve this information, ... hence achieve better results after post-hoc calibration\". They are fine as hypotheses, but hypotheses should be clearly marked in the text. \n\nComment 3: I want to suggest an alternative hypothesis. From Table 2, we can notice that difference in ECE is much less pronounced with more expressive histogram binning (HB) post hock calibration (TS: 0.72 vs 1.35, HB: 0.68 vs 0.70). This makes me hypothesize that after conventional training all predictions are \"equally uncalibrated\" meaning that, they are all overconfident and can be easily corrected by TS. After label smoothing it might be the case that the \"equally uncalibrated\" property fails, and more complex object-dependent calibration is needed. \n\n3. Inverse focal loss (lines 245-284). The \"inverse focal loss assigns larger weights to the samples with larger output confidences\" (line 258). To the best of my understanding the intuition is the following: if overconfident predictions fit better for post-hoc calibration, can we push this even further?\n\nComment 4: The results loos inconsistent to me. My conclusion is that CE is a good default choice of loss, and using IFL is likely (unsure) to make results worse. It is worth adding global statistics to see the whole picture.\n\nTechnical drawbacks:\n1. Classification models are significantly undertrained. ResNet-32 on CIFAR-10 has 90.5-ish accuracy, but it should be 92.5-ish. ResNet-110 on CIFAR-10 has 89.10-ish accuracy, but it should be 93.7-ish. The same for CIFAR-100 ResNet-110 (Table G, Appendix) has 62.6-ish but it should be 77.3-ish. This unfortunately might be important to findings as ECE is heavily used accuracy, and should be corrected. Or is it due to a 45000/5000/10000 data split? It looks like in this case a drop is too intense at least for CIFAR-100. Maybe that be a consequence of fewer updates due to fewer objects?\n\n2. ECE is a biased measure of calibration, with a model-specific basis [https://arxiv.org/abs/1902.06977]. Thus the results presented in the paper might benefit from using additional metrics. It is unclear, how the bias influences ECE in practice, however, I'm suggesting verifying the findings with other metrics. There is the squared kernel calibration error (SKCE) proposed in [https://arxiv.org/abs/1910.11385] that, also it might worth to report calibrated log-likelihood [https://arxiv.org/abs/2002.06470]. \n\n3. Table 1. \"The values with underline in first row represent the chosen coefficients of each\nregularization method on four datasets according to the ECE on test data.\" Is there any specific reason to choose hyperparameters on test data? \n\nOverall: \n\nThe paper is most clearly written. The main effect is interesting and deserves to be published. However, these results are obtained on undertrained networks, which can influence results. The explanation part has a weak justification, and the new loss function performs not consistent.  My score at the moment is \"6: Marginally above the acceptance threshold\". However, it is possible that I will change my score after the discussion.", "summary_of_the_paper": "", "summary_of_the_review": "", "strength_and_weaknesses": "", "limitations_and_societal_impact": "No.", "review_text": "", "extra_scores": {"needs_ethics_review": "No", "ethics_review_area": "", "time_spent_reviewing": "6"}, "extra_text": {}}, {"review_id": "-GLDyY4QIoJ", "reviewer": "Reviewer_3ZFb", "summary": "The paper analyzes the effect of regularizers that improve calibration and find that these regularizers diminish the effects of post-training calibration, such that models trained with simple cross-entropy and after-training temperature scaling exhibit better (lower) ECE.\n\nMoreover, the paper shows that inverse focal loss during training can improve post-training calibration's effect by separating high-confidence samples more strongly from low-confidence ones.", "questions": "", "limitations": "", "rating": 7, "confidence": 4, "soundness": null, "presentation": null, "contribution": null, "strengths": "", "weaknesses": "", "quality": null, "clarity": null, "significance": null, "originality": null, "strengths_and_weaknesses": "", "was_revised": false, "final_justification": "", "rebuttal": "", "claims_and_evidence": "", "methods_and_evaluation_criteria": "", "theoretical_claims": "", "experimental_designs_or_analyses": "", "relation_to_broader_scientific_literature": "", "essential_references_not_discussed": "", "other_strengths_and_weaknesses": "", "other_comments_or_suggestions": "", "questions_for_authors": "", "summary_of_paper": "", "summary_of_recommendation": "", "technical_quality": "", "clarity_of_presentation": "", "potential_impact": "", "robotics_focus": "", "quality_of_limitations": "", "questions_for_rebuttal": "", "reasons_to_accept": "", "reasons_to_reject": "", "questions_to_authors": "", "main_review": "### Originality\n\nThe examination of calibration through regularization and post-training calibration is novel as is the formulation of the inverse focal loss which is examined in the second half of the paper.\n\nI think the examinations and observations are of high quality and the paper is a very interesting insightful read. Especially the histogram of logits that shows that regularizers that improve calibration lead to \"squared together\" logits which makes post-training calibration more difficult and the concept of \"learned epoch\" is beautiful (even if inspired by [29]).\n\nPS: There already exists an \"inverse focal loss\" in the literature it seems, which was introduced in a totally different context and using a different mathematical expression, but similar motivation:\n[\"Conditional Adversarial Domain Adaptation\",Long et al, 2017 (https://arxiv.org/abs/1705.10667)](https://arxiv.org/abs/1705.10667).\n\n### Quality\n\nOverall, the paper's arguments seem sound and are supported by empirical evidence and thoughtful observations, see above. \n\nThe work is honest about strengths and weaknesses within its reported results.\n\nConcerns:\n1. The paper mentions it has been calibrating using the test set. This leads to overfitting and reduces my confidence in the reported results.\n2. The shared code used LBFGS to find the best temperature. Anecdotal evidence suggests that LBFGS is not the right choice and a grid search gives different & better results usually. This also reduces my confidence in the reported results. Sadly, the temperature scaling code that is most commonly used online does not do this (https://github.com/gpleiss/temperature_scaling/blob/master/temperature_scaling.py, which seems to be the code that was used by the authors of this paper---the source should be marked btw if the code was to be shared widely!)\n3. [\"Can You Trust Your Model's Uncertainty? Evaluating Predictive Uncertainty Under Dataset Shift\", Ovadia et al, 2019 (https://arxiv.org/abs/1906.02530)](https://arxiv.org/abs/1906.02530) shows that post-training calibration does not necessarily work well under distribution shifts. I am uncertain about whether the regularized objectives cope better or worse with distribution shifts.\n\n#3 in particular is important because the behaviour under distribution shift might be most important for practioners.\n\nRe 2.: See [\"Calibrating Deep Neural Networks using Focal Loss\", Mukhoti, 2020 (https://arxiv.org/abs/2002.09437)](https://arxiv.org/abs/2002.09437) for details: validation NLL is not a convex function of the temperature necessarily and grid searches provide better results.\n\n### Clarity\n\nThe submission is clearly written and well organized. The empirical section (together with the appendix) clearly states everything that is needed for reproducing the results.\n\n### Significance\n\nThe observations and results are significant. Researchers and practitioners will find them insightful and it will help guide future research. Personally, I would prefer training with regularizers over post-training calibration, and thus paper was surprising and might influence how I train models.\n\n### Summary\n\nAn insightful and well-written paper. Given that the temperatures were computed using LBFGS, I have minor doubts about the reliability of the results, however.\n\n### Questions\n\n1. Could you update results with a separate validation set? Or explain why calibration and evaluation on the test set is alright?\n2. Could you update results using a grid search to verify that the observations are not artefacts of using LBFGS?\n3. Could you comment on distribution shift?\n\nI will adjust my score depending on how any or all of the above questions are answered.\n\nI really like the paper very much, but I'm unsure given my concerns (see above & questions). \n\n### Typos\n\n1. l. 57: \"from worse calibratable\" -> \"from not being as calibratable\" (eg)\n2. l. 145: \"degrade the ECE\" -> \"decrease the ECE\"\n3. l. 148: \"would be harmed\" -> \"are harmed\"\n4. l. 180: \"Figure 2(d)\" -> \"Figure 2\"? not sure about the (d)\n5. Figure 2.: export plots as pdf and not rasterized images\n6. l. 243: \"with the standard CE try to\" -> \"with the standard CE manage to\"\n7. Figure 6: \"Tempture\" -> \"Temperature\" (y axis label)\n", "summary_of_the_paper": "", "summary_of_the_review": "", "strength_and_weaknesses": "", "limitations_and_societal_impact": "In the appendix.", "review_text": "", "extra_scores": {"ethical_concerns": "None.", "needs_ethics_review": "No", "ethics_review_area": "", "time_spent_reviewing": "5"}, "extra_text": {}}]

Author rebuttal:

Meta-review: This paper makes the claim that although deep neural networks tend to be overconfident and poorly calibrated after training, they are “calibratable” in that post-hoc calibration methods like Platt or temperature scaling can recover good calibration.  The authors argue that many regularization methods that have been proposed to improve calibration during training actually result in less calibratable classifiers.  Experiments are run using a ResNet-32 on SVHN, CIFAR10/100 and a FCNN on 20 newsgroups.  

Weaknesses
- All evaluation is done using the standard in-distribution validation and test sets.  
- The only metric that is evaluated is expected calibration error, which is not a proper scoring rule.  It’s well established that ECE can be gamed and should not be used as the sole metric for comparison of models.  
- This paper would be much stronger if it included more difficult / modern datasets and models.  A start would be imagenet with corresponding shifted / OOD variants like imagenet A, C, V2.  In cases where the data distribution changes we know, TS doesn’t perform well.  Thus is this going to provide the right recommendation under those circumstances?  The claims are quite broad given the scope of the experiments.  
- Can we expect to make general claims over all of deep learning given results of a specific ResNet architecture on 32x32 images and a FCNN on 20-newsgroups?
- There are some concerns about showing results that were calibrated using the test data

Strengths
- The reviewers found that the paper was interesting to read and well written.
- They found some of the analysis especially insightful (e.g. "Especially the histogram of logits that shows that regularizers that improve calibration lead to "squared together" logits which makes post-training calibration more difficult and the concept of "learned epoch" is beautiful").
- The arguments were found to be sound and validated by the empirical results.

Overall, this paper presents an interesting observation, but the claims seem somewhat too broad and sweeping given the content of the empirical evaluation.  One might expect to see some evaluation of these models on cases with changes to the data distribution, more rigorous metrics (e.g. NLL),  more varied architectures, some analysis of epistemic vs aleatoric uncertainty. Nevertheless, the reviewers consensus is that the strengths outweigh the weaknesses of the paper and that these results will be useful and interesting to the community.  Thus the recommendation is to accept.

Nit: Bayesian DNNs “which indirectly infer prediction uncertainty through weight uncertainties” is a mischaracterization of BNNs.  They directly infer prediction uncertainty by marginalizing over models, producing a distribution of predictions.

Decision: Accept (Poster)