Evaluating and Calibrating Uncertainty Prediction in Regression Tasks
Authors: Dan Levi
Liran Gispan
Niv Giladi
Ethan Fetaya
Venue:  (2020)
Keywords: Uncertainty Estimation
Regression
Deep learning

Abstract: Predicting not only the target but also an accurate measure of uncertainty is important for many applications and in particular safety-critical ones. In this work we study the calibration of uncertainty prediction for regression tasks which often arise in real-world systems. We show that the existing definition for calibration of a regression uncertainty [Kuleshov et al. 2018] has severe limitations in distinguishing informative from non-informative uncertainty predictions. We propose a new definition that escapes this caveat and an evaluation method using a simple histogram-based approach inspired by reliability diagrams used in classification tasks. Our method clusters examples with similar uncertainty prediction and compares the prediction with the empirical uncertainty on these examples. We also propose a simple scaling-based calibration that preforms well in our experimental tests. We show results on both a synthetic, controlled problem and on the object detection bounding-box regression task using the COCO and KITTI  datasets.

Under review as a conference paper at ICLR 2020
EVALUATING AND CALIBRATING UNCERTAINTY PRE- DICTION IN REGRESSION TASKS
Anonymous authors Paper under double-blind review
ABSTRACT
Predicting not only the target but also an accurate measure of uncertainty is im- portant for many applications and in particular safety-critical we study the calibration of uncertainty prediction for regression tasks which often arise in real-world systems. We show that the existing definition for calibration of a regression uncertainty (Kuleshov et al., 2018) 8) has severe limitations in distin- guishing informative from non-informative uncertainty predictions. We propose a new definition that escapes this caveat and an evaluation method using simple histogram-based approach inspired by reliability diagrams used classification tasks. Our method clusters examples with similar uncertainty prediction and com- pares the prediction with the empirical uncertainty on these examples. We also propose simple scaling- scaling-based calibration that preforms well in experimental tests. We show results on both a synthetic, controlled problem and on the object detection bounding-box regression task using the COCO (Lin al. 2014) and KITTI (Gegger et al. 2012) datasets.
In this work
INTRODUCTION
observed confidence level
0.8
0.6
0.4
0.2
before-calibration - (0.2) after-calibration (0.0003)
0.2
0.4
0.6
0.8
expected confidence level
Figure I: Regression with random uncertainty (independent of actual uncertainty) almost perfectly calibrated by the method proposed in (Kuleshov al. 2018), when the expected and observed confidence level are identical. As anything can be perfectly calibrated, this calibration definition becomes uninformative. The task object bounding box regression, using the KITTI dataset (Geiger al. 2012). See details in Section 4.2
Regression problems arise in many real-world machine learning tasks. To name just a few: Depth from single image (Eigen et al. 2014), Object localization and Acoustic localization (Vera- et al. 2018). Many of these tasks are solved by deep neural networks used within decision making pipelines which require the machine learning block not only to predict the target but to also output its confidence in the prediction. For example, the commonly used Kalman-Filter tracking algorithm (Blackman) 2004) requiring variance estimation for the observed object's location estimation. In addition, may want the system output final uncertainty, reflecting real-world empirical

---

Under review as a conference paper at ICLR 2020
probabilities, to allow a safety-crities system such as a self-driving car agent to take appropriate actions when confidence drops. In practice, using the confidence in the localization of objects has been shown to improve the non-maximal suppression stage and consequently the overall detection performance (He et al.) 2018). Similarly, (Feng et al.) 2018) describe a probabilistic 3D vehicle detector for Lidar point clouds that model both classification and spatial uncertainty.
To provide uncertainty estimation, each prediction produced by the machine learning module during inference should be a distribution over the target domain. There are several approaches for achieving this, most common are Bayesian neural networks (Gal 2016 Gal & Ghahramani, (016), ensembles [Lakshminarayanan et al. 2017) and outputting a parametric distribution directly (Nix Weigend 1994). Bayesian neural networks place probability distribution over the network parameters, which is translated to an uncertainty in the prediction, providing a technically sound approach but with overhead at inference time. In the direct approach, outputs of the network represent the parameters of the output distribution for either discrete (Niculescu- Mizil & Caruana, 2005) or continuous (Nix & Weigend 1994) distributions. Note that the direct approach naturally captures the aleatoric uncertainty (inherent observation noise), but captures less the epistemic uncertainty (uncertainty in the model) test case for calibration method, the direct approach for
(Kendall & Gal, 2017). We chose producing uncertainty: we transform the network output from a single scalar to a Gaussian distribution by taking the scalar the mean and adding branch that predicts the standard deviation (STD) as in [Lakshminarayanan et al. 2017). While this is probably the simplest form, it is commonly used in practice, and our analysis is applicable to more complex distributions as well as other approaches.
Adjusting the output distributions to match the observed empirical ones via post process is called uncertainty calibration. It was shown that modern deep networks tend to be over confident in their predictions (Guo et al. 2017). The same study revealed that for classification, Platt Scaling (Plat) 1999), simple scaling of the pre-activation of the last layer, achieves well calibrated confidence estimates (Guo et al. (017). In this paper we show that similar simple scaling strategy, applied to the standard deviations of the output distributions, can calibrate regression algorithms as well.
One major question is how to define calibration for regression, where the model outputs a continuous distribution over possible predictions. recent work (Kuleshov et al.) 2018) suggested definition based on credible intervals where if we take the p percentiles of each predicted distribution the output should fall below them for exactly p percent of the data. Based on this definition the authors further suggested calibration evaluation metric and re-calibration method. While this seems very sensible and has the advantage of considering the entire distribution, we found serious flaws in this definition. The main problem arises from averaging over the whole dataset. We show, both empirically and analytically, that one can calibrate using this evaluation metric practically any output distribution, even one which is entirely uncorrelated with the empirical uncertainty as can be in Fig. We elaborate on this property of the evaluation method described in (Kuleshov et al. (0088) in Section 2 and show empirical evidence in Section 4
We propose a new simple definition for calibration for regression, which is closer to the standard one for classification. Calibration for classification can be viewed as expecting the output for every single data point to correctly predict its error, in terms of misclassification probability. In similar fashion, we define calibration for regression by simply replacing the misclassification probability with the mean square error. Based on this definition, we propose a new calibration evaluation metric similar to the Expected Calibration Error (ECE) (Nacini et al./ 2015), which groups examples into interval bins with similar uncertainty, and then measures the discrepancy between each bin's parameters and the parameters of the empirical distribution within the bin. An additional dispersion measure completes our set of diagnostic tools by revealing cases where the individual uncertainty outputs uninformative as they all return similar values.
Finally, we propose calibration method where re-adjust the predicted uncertainty, in our case the outputted Gaussian variance, by minimizing the gegative-log-likelinn re-calibration set. We show good calibration results on a real-world dataset using simple parametric model which scales the uncertainty by constant factor. As opposed to (Kuleshov et al. 2018). we show that our approach cannot calibrate predicted uncertainty that is uncorrelated with the real uncertainty, as one would expect.
(NI.L) on a separate
To summarize, our main contributions are:
2

---

Under review as a conference paper at ICLR 2020
Revealing the fundamental flaws in the current definition of calibrated regression uncertainty
Kuleshov et al., 2018)
A new proposed definition for calibrated uncertainty in regression tasks
A simple scaling method that can reduce the calibration enror similar to temperature scaling for classification (Guo et al. 2017). evaluated on large scale real world vision datasets.
1.1 RELATED WORK
While shallow neural networks are typically well-calibrated (Niculescu- Caruana 2005)
modern, deep networks, albeit superior in accuracy, are no-longer calibrated (Guo et al. 2017 Uncertainty calibration for classification is a relatively studied field. Calibrution plots or Reliability diagrams provide visual representation of uncertainty prediction calibration (DeGroot & Fienberg 1983, Niculescu-
Caruana 2005) by plotting expected sample accuracy as a function of confidence. Confidence values grouped into interval bins to allow computing the sample accuracy. A perfect model corresponds to the plot of the identity function. The Expected Calibration Error (ECE) (Naeini et al., 2015) summarizes the reliability diagram by averaging the error (gap between confidence and accuracy) in each bin, producing a single value measure of the calibration. Similarly, the Maximum Calibration Error (MCE) (Neinni et al. 2015) measures the maximal gap. Negative Log Likelihood (NLL) is a standard measure of a model's fit to the data (Hastie et al., (001) but combines both accuracy of the model and its uncertainty estimation in one measure. Based on these measures, several calibration methods were proposed, which transform the network's ' confidence output to one that will produce calibrated prediction. non-paramctric transformations include Histogram Binning (Zadrozny& & Elkan, 2001). Bayesian Binning into Quantiles (Naeini et al. 2015) and Isotonic Regression (Zadrozny Elkan (200T) while parametric transformations include versions of Platt Scaling (Platt 1999) such as Matrix Scaling and Temperature Scaling (Guo et al. 2017). In
(Guo et al. 2017) is demonstrated that the simple Temperature Scaling, consisting of a one scaling- parameter model which multiplies the last layer logits, suffices produce excellent calibration
many classification data-sets.
In comparison with classification, calibration of uncertainty prediction in regression, has received little attention so far. As already described, (Kuleshov et al.] 2018) propose a practical method for evaluation and calibration based confidence intervals and isotonic regression. The proposed method is applied in the context of Bayesian neural networks. In recent work (Phan et al., (018)) the authors follow (Kuleshov et al., 2018) definition and method of calibration for regression, but use standard deviation vs. MSE scatter plot, somewhat similar to our approach, as a sanity check.
CONFIDENCE-INTEERVAL BASED CALIBRATION
We next review the method for regression uncertainty calibration proposed in (Kuleshov al. 2018) which is based on confidence intervals, and highlight its shortcomings. We refer to this method in short as the Sinterval-based' calibration method. We start by introducing basic notations for uncertainty calibration used throughout the paper.
Notations. Let X, Y be two random variables jointly distributed according to and x y their corresponding domains. A dataset {2,, vt) consists of i.i.d samples of X, Y. A forecaster H X + P))) outputs per example I4 a distribution p. = Hxx,) over the label space, where P(Y) is the set of all distributions over )) In classification tasks, y is discrete and pt is multinomial distribution, and in regression tasks in which y is a continuous domain, Pt. is usually a parametric probability density function, e.g. a Gaussian. For regression, we denote by F; y - [0, 1] the CDF corresponding to Pt.
According to (Kuleshov et al. 2018 a forecaster in a regression setting H is calibrated if:
Σ 1==
13 < FT (p)}
T-x p. vp E |0, 1]
(1)
T
3

---

Under review as a conference paper at ICLR 2020
Intuitively this means that the yi is smaller than (p) (p) with probability approximately p. or that the predicted CDF matches the empirical one as the dataset size goes to infinity. This is equivalent to
Px, (Y s [P(X)] (x) Vp E [0.1]
Where F(X) represents the CDF corresponding H(X). This notion is translated by (Kuleshov et al. 2018) to practical evaluation and calibration methodology. A re-calibration dataset S (Tt, V1 used to compute the empirical CDF value for each predicted CDF value p E F3 (yr):
P(p) = Hm Pr (w)) S p. p.t=
T
The calibration consists of fitting a regression function (i.e. isotonic regression). to the set of points {(p, P(p))]== For diagnosis the authors suggest a calibration plot of {p, P(p))} at equally spaced values of p.
We start by intuitively explaining the basic limitation of this methodology. From Eq. P is non- decreasing and therefore isotonic regression finds a perfect fit. Therefore, the modified CDF R Ft will satisfy P(p) on the re-calibration set, and the new forecaster is calibrated up to sampling error. This means that perfect calibration is possible no matter what the CDF output is, even for output CDFs which are statistically independent of the actual empirical uncertainty. We note that this might be acceptable when the uncertainty prediction is degenerate, e.g. all output distributions are Gaussian with the same variance, but this is not the case here. We also note that the issue is with the calibration definition not the re-calibration, as we show with the following analytic example.
We next present a concise analytic example in which the output distribution and the ground truth distribution are independent, yet fully calibrated according to Eq. [2] Consider the case where the target has a normal distribution Y/- ~ (N0,) 1) and the network output (xxe) has Cauchy distribution with zero location parameter and random scale parameter 7r independent x, and ye. defined as:
2x
(O, 1)
(4)
lzel
(mx)) Cauchy Tt)
Following a known equality for Cauchy distributions, the CDF output of the network F( F
where F is the CDF of Cauchy distribution with zero location and scale parameters. First note that de and 2 i.e. with and without the absolute value, have the same distribution due to symmetry. Next we recall the well known fact that the ratio of two independent normal random variables is distributed as Cauchy with zero location and scale parameters (i.e. 2, Cauchy(O, 1)). This means that probability that Fr = ((x) S p is exactly p (recall that F is a Cauchy (0, 1) CDF). In other words, the prediction is perfectly calibrated according to the definition in Eq. even though the scale parameter
random and independent of the distribution of ye-
While the Cauchy distribution is a bit unusual due to the lack mean and variance, the example does not depend on it and it was chosen for simplicity of exposition. It is possible to prove the existence of a distribution whose product of two independent samples is Gaussian (Thorii 1977) and replace the Cauchy with Gaussian, but it is an implicit construction and not a familiar distribution.
3
OUR METHOD
We present new definition for calibration for regression, as well as several evaluation measures and reliability diagram for calibration diagnosis, analogous to the ones used for classification (Guo et al. 2017). The basic idea is that for each value of uncertainty, measured through standard deviation o, the expected mistake, measured in mean square error (MSE), matches the predicted error o?. This is similar to classification with MSE replacing the role of mis- classssssiiictio error. More formally, if (xx) and (ax)² are the predicted mean and variance respectively then we consider a regressor well calibrated if:
4

---

Under review as a conference paper at ICLR 2020
Vo Bxyy [f(x)
(5)
In contrast to to (Kuleshov et al. 2018) this does not average over points with different values of a² (at least in the definition, for practical measures some binning needed), but only considers the mean and variance and not the entire distribution. We claim that this captures the desired meaning of calibration, i.c. for each individual example you can correctly predict the expected mistake.
Since can expect each exact value of o² in dataset to appear exactly once, evaluate eq. 3] eempirically using binning, same as for classification. Formally, let og be the standard deviation of predicted output PDF pa and assume without loss of generality that the examples increasing values of dN We also assume for notation simplicity that the number of bins, N, divides the number of examples, T. We divide the indices of the examples to N bins, {By))=ı> such that:
ordered by
B, = N + .......3 N Each resulting bin therefore represents an interval in the standard deviation axis: [min {or)) max4en, n, {o.}]. The intervals are non-overlapping and their boundary values are increasing.
To evaluate how calibrated the forecaster is, compare per bin j two quantities follows. The root of the mean variance:
1
mV AR()
?
(6)
BB
BE
And the empirical root mean square error:
RMSE
(y/= 01))
BB
IEB;
where Dr is the mean of the predicted PDF (p:)
For diagnosis, we propose a reliability diagram which plots the RMSE as function of the mV mVAR shown in Figure 4 The idea is that for calibrated forecaster per bin the mV mVAR and the observed RMSE should be approximately equal, and hence the plot should be close to the identity function. Apart from this diagnosis tool which additional scores for evaluation.
will show is valuable for assessing calibration, we propose
Expected Normalized Calibration Error (ENCE). For summarizing the error in the calibration propose the following measure:
1 N
mvAR(() RMSEO)
ENCE
AV
This score averages the calibration error in each bin, normalized by the bin's mean predicted variance, since for larger variance expect naturally larger errors. This measure is analogous to the expected calibration error (ECE) used in classification.
STDs Coefficient of variation (Cv.). In addition to the calibration error we would like to measure the dispersion of the predicted uncertainties. If for example the forecaster predicts a single homogeneous uncertainty measure for each example, which matches the empirical uncertainty of the predictor for the entire population, then the ENCE would be zero, but the uncertainty estimation per example would be uninformative. Therefore, complement the ENCF measure with the Coefficient of Variation (c,) for the predicted STDs which measures their dispersion:
(or (oL-Aa)
T-1
C.
Pa
where Mo = ΣT 1 o,, Ideally the c, should be high indicating disperse uncertainty estimation over the dataset. We propose using the ENCE as the primary calibration measure and the c, as a secondary diagnostic tool.
5

---

Under review as a conference paper at ICLR 2020
3.1 CALIBRATION
To understand the need for calibration, let us start by considering a trained neural network for regression, which has very low squared error (MSE) on the train data. We now add separate branch that predicts uncertainty as standard deviation, which together with the original network output interpreted as the mean, defines Gaussian distribution per example. In this case, the NLL loss on the train data can be minimized by lowering the standard deviation of the predictions, without changing the MSE on train or test data. test data however, MSE will be naturally higher. Since the predicted STDs remain low on test examples, this will result in higher NLL and ENCE values for the test data. This type miss-calibration is defined as over-confidence, but opposite or mixed cases can occur depending how the model is trained.
Negative log-likelihood. NLL a standard measure for a probabilistic model's quality (Hastie et al., 2001}. When training the network to output classification confidence regression distribution, is commonly used as the objective function to minimize. It is defined as:
T Σ log ((H()))(()))
NLL --
(10)
We propose using the NLL on the re-calibration set objective for calibration, and the reliability diagram, together with its summary measures (ENCE. c.) for diagnosis of the calibration. In the most general setting calibration function maps predicted PDFs to calibrated PDFs: R(O): P()) P(Y)) where 9 is the set of parameters defining the mapping.
Optimizing calibration the re-calibration set is obtained by finding 0 yielding minimal NLL:
arg mjn
Σ log ([R(pe: θ) (v.))
(11)
To ensure the calibration generalization. the diagnosis should be made on a separate validation set. Multiple choices exist for the family of functions R belongs to. We propose using STD Scaling, (in analogy to Temperature Scaling (Guo et al., 2017)), which essentially multiplies the STD of each predieted distribution by constant scaling factor If the predicted PDF is that of a Gaussian distribution, (V d²), then the re-calibrated PDF is M(,, (s-o)²). Hence, in this case the calibration objective (Eq. is:
[ 12 20
))=
T
(yt mt)
arg min
Σ log 2
aarg arg min
2 log(s)
Σ
(12)
2
If the original predictions are overeonfident, common neural networks, then the calibration should set s > I. This is analogous to Temperature Scaling in classification: single multiplicative parameter tuned fix over or under-confidence of the model, and it does not modify the model's final prediction since μ4 remains unchanged.
More complex calibration methods. Histogram binning and Isotonic Regression applied to the STDs can be also used as calibration methods. We chose STD scaling since: (a) it is less prone to overfit the validation set, (b) it does not enforce minimal and maximal STD values, (c) easy to implement and (d) empirically, it produced good calibration results.
4 EXPERIMENTAL RESULTS
We next show empirical results of our approach on two tasks: a controlled synthetic regression problem and object detection bounding box regression. In both tasks examine the effect of outputting trained and random uncertainty on the calibration process. In all training and optimization stages we use SGD optimizer with learning rate 0.001 and 0.9 momentum.
4.1 SYNTHETIC REGRESSION PROBLEM
Experimenting with a synthetic regression problem enables us to control the target distribution Y and to validate method. We randomly generate T 50, 000 input samples (2t, yr VT We sample 2;

---

Under review as a conference paper at ICLR 2020
from X Uniffrmml (011 and y from Y (x2, 22). This way, the target standard deviation of sample Fe is It- We train a cully-connected network with four layers and ReLU activation function on the generated training set using the smooth L₁ loss function. We then add separate branch with its own four layers to predict uncertainty.
Per example X2, The original network output is considered the mean of Gaussian distribution (144 and the additional output as its standard deviation (o₂). For numerical stability, as suggested by (Kendall & Gal 2017). the network oulputs log(o²). In the random uncertainty experiment, per example, the standard deviation representing the uncertainty is randomly drawn from J Jorrm[, 10). For the predicted uncertainty experiment, the uncertainty branch is optimized using the NLL loss (Eq. TO) while the rest of the network weights are fixed. By fixing the remaining weights, the predicted mean (14) remains unchanged making sure we do not calibrate using over-confident predictions. We then re-calibrate as described in Sec. 3.1 on a separate re-calibration set consisting of 6, 000 samples.
(c)
Cafore Geb, ENGE C7
4der Cale., ENGLLAE 5% C7
observed cetennneece level i.
1.4
500005
belore-calibaatin
after-calibratio (0.0001)
expected confidence level
Figure Reliability diagrams for the synthetic regression problem with random uncertainty estimation. Reliability diagram using our method before (a) and after (b) calibration. (c) Before and after calibration based on the confidence intervals method (Kuleshov et al. 2018).
a
Esbio Carb,, A 777)
0.5
Alter Callb,, ENCE -2
observed confideence level
0.
0.7
0.0
84
0.2
before before-calibnene calibration (8e-05)
02
after- calibration (6e-05)
0.A
0.5
3.5
0.2 0.4
expected confidence level
Figure 3: Synthetic regression problem with predicted uncertainty. (a) ground truth vs. predicted standard deviation. (b) Reliability diagram before and after calibration. (c) Reliability diagram using confidence intervals [Kuleshov et al. 2018 before and after calibration.
As one see in Fig. the confidence interval method can almost perfectly calibrate the random independent uncertainty estimation, as the expected and observed confidence level match and we get the desired identity curve. This phenomenon extremely undesirable for safety critical applications where falsely relying on uninformative uncertainty can lead to severe consequences. It is important to note that the perfect calibration did not arise from giving the same fixed a for each prediction, which would be acceptable, as the isotonic regression modifies the probabilities directly and not the outputted standard deviations. In contrast you can see how our method can only marginally improve the calibration and one can clearly see, both from the ENCE value and visually from the graph, that the predictions are not calibrated. In the trained experiment, in which uncertainty is predicted by the network, can in Fig. 3 that the network almost perfectly learns the correct uncertainty, as expected from the problem simplicity and the high data availability. In this case both methods do not change the calibration results much. The important thing note that our calibration and evaluation
7

---

Under review as a conference paper at ICLR 2020
method can easily differentiate between both cases, the random and predicted uncertainty, while they are almost exactly the same after calibrating with (Kuleshov et al. 2018).
4.2 BOUNDING BOX REGRESSION FOR OBJECT DETECTION
In computer vision, an object detector outputs per input image set of bounding boxes, each commonly defined by 5 outputs: classification confidence and four positional outputs (lz, bys bw, 4x) representing its (x.y) position, width and height. We show results on each positional output as an independent regression task using the R-FCN detector (Dai et al. 2016). To this architecture we add an additional uncertainty branch predicting the corresponding STDs for each regression output, (T.,, yy ww: TT.. Thus, the network outputs a Gaussian distribution per regression task. For training the network weights we use the entire Common objects in context (COCO) dataset (Lin et al. 2014). For uncertainty calibration and validation we use two separate subsets of the KITTI (Geiger et al.) 2012) object detection benchmark dataset, which consists of road scenes. Training the uncertainty output on one dataset and performing calibration a different one reduces the risk of over-fitting and increases the calibration validity. See Appendix A for further details.
We initially train the network without the additional uncertainty branch as in (Dai et al. 2016), while the uncertainty branch weights are randomly initialized. Therefore, in this state which we refer to untrained uncertainty, random uncertainties are assigned to each example. We then train the uncertainty branch by minimizing the NLL loss (Eq. TO) on the training set, freezing all network weights but the uncertainty head for 1K training iterations with 6 images per iteration. Freezing the rest of the network ensures that the additional uncertainty estimation does not sacrify accuracy. The result of this stage the network with predicted uncertainty. Finally, we train the NLL loss for 1K additional training iterations on the re- re-calibration set, to optimize the single scaling parameter s, and obtain the calibrated uncertainty.
Figure 4 shows the resulting reliability diagrams before calibration (predicted uncertainty) and after (calibrated uncertainty) for all four positional outputs, on the validation set. As can be observed from the monotonously increasing curve before calibration, the output uncertainties are indeed correlated with the empirical ones. Additionally, since the curves are entirely above the ideal one, the predictions are over confident. Using the learned scaling factor which varies between 1.1 and 1.2, the ENCE significantly reduced as shown table T The e, remains unchanged after calibration since is invariant to uniform scaling of the output STDs (Eq. 99. For untrained uncertainty, Fig. [ shows that after calibration, just as with the synthetic dataset, using the interval- based method, uncertainty is almost perfectly calibrated. In contrast, method reveals the lack of correlation between the predictions and empirical uncertainties before/ after applying calibration (See results Appendix A).
tx
ty
tx
th
B052 11
New 2000
04
2.5
04
06
03
2.8
0.5
0.6
07
03
Figure 4: Reliability diagrams for bounding box regression on the KITTI validation set before and after calibration. Each plot compares the empirical RMSE and the root mean variance (mV AR) in each bin. Grey dashed line indicates the ideal calibration line. See Sec. 4.2 for details.
5 CONCLUSIONS
Calibration, and more generally uncertainty prediction, are critical parts of machine learning especially in safety-critial applications. In this work we exposed serious flaws in the current approach define and evaluate calibration for regression problem. We also proposed an alternative approach and showed that even very simple re-calibration method can lead to significant improvement in real-wo real-world applications. Our proposed method for calibration effectively takes into consideration the first two moments when comparing the output and real distributions. An interesting direction for future
8

---

Under review as a conference paper at ICLR 2020
Table I: Evaluation of uncertainty calibration for the bounding box regression tasks the KITTI validation dataset.
Before calibration ENCE
After calibration
C
ENCE
Ce
tx 17.2%
0.38
8.3%
0.38
ty 25.0%
0.31
4.7%
0.31
tw 24.7%
0.36
8.4%
0.36
Lh 12.5%
0.25
5.7%
0.25
research would be extending method handle more complex distributions using, for example, higher-order moments.
REFERENCES
S. S. Blackman. Multiple hypothesis tracking for multiple target tracking. JEEE Aerospace and Electronic Systems Magazine, 19(1):5-18, Jan 2004. ISSN 0885-8985. doi: 10.1109/MEES 1263228.
Jifeng Dai, Yi Li. Kaiming He, and Jian Sun. R-fen: Object detection via region-based fully convolutional networks. In Proceedings of the 30th International Conference on Neural Information Processing Systems, NIPS' 16, pp. 377,387, USA, 2016. Curran Associates Inc. ISBN 978-1-5108- 3881-9.
Morris H. DeGroot and Stephen E. Fienberg. The comparison and evaluation of forecasters. The Statistician: Journal of the Institute of Statisticians, 32:12-22, 1983.
David Eigen, Christian Puhrsch, and Rob Fergus. Depth map prediction from a single image using a multi-scale deep network. In Z. Ghahramani, M. Welling, C. Cortes, N. D. Lawrence, and K. Q. Weinberger (eds.), Advances in Neural Information Processing Systems 27, pp. 2366-2374. Curran Associates, Inc., 2014.
Di Feng, Lars Rosenbaum, and Klaus Dietmayer. Towards safe autonomous driving: Capture uncertainty in the deep neural network for lidar vehicle detection. CoRR, abs/1804.05132, 2018. URL http://arxiv org/ abs/ 05132
Yarin Gal. Uncertainty in deep learning. 2016.
Yarin Gal and Zoubin Ghahramani. Dropout a Bayesian approximation: Representing model uncertainty in deep learning. In Proceedings of the 33rd International Conference Machine Learning (ICML-16), 2016.
Andreas Geiger, Philip Lenz, and Raquel Urtasun. Are we ready for autonomous driving? the kitti vision benchmark suite. In Conference on Computer Vision and Pattern Recognition (CVPR), 2012.
Ross Girshick. Fast r-cnn. In Proceedings of the 2015 IEEE International Conference Computer Vision (ICCV), ICCV '15, pp. 1440-148,, Washington, DC, USA, 2015. IEEE Computer Society. ISBN 978- 118-1-4673-83911
doi: 10. 00.100///CV22015.166
Chuan Guo, Geoff Pleiss, Yu Sun, and Kilian Q. Weinberger. On calibration of modern neural networks, In ICML, volume 70 of Proceedings of Machine Learning Research, pp. 1321-1330. PMLR, 2017.
Trevor Hastie, Robert Tibshirami, and Jerome Friedman. The Elements of Statistical Learning. Springer Series in Statistics. Springer New York Inc., New York, NY, USA, 2001.

---

Under review as a conference paper at ICLR 2020
Kaiming He, Xiangyu Zhang, Shaoqing Ren, and Jian Sun. Deep residual learning for image recognition. 2016 IEEE Conference on Computer Vision and Pattem Recognition, CVPR 2016, Las Vegas, NV, USA, June 27-30, 2016, pp. 770-778, 2016. doi: 10.1109/CVPR.2016.520 URL
htt.ps://don www.ddi.orggggoo /t. 1109/ CVPR. 201 6. 90
Yihui He, Xiangyu Zhang, Marios Savvides, and Kris Kitani. Softer-nms: Rethinking bounding box regression for accurate object detection. CoRR, abs/1809.08545, 2018. URL httt:://rxiy>
htg/abs/1809 08545
Alex Kendall and Yarin Gal. What uncertainties do we need in bayesian deep learning for computer vision? I. Guyon, U. V. Luxburg. Bengio, H. Wallach, R. Fergus, S. Vishwanathan, and R. Garnett (eds.), Advances in Neural Information Processing Systems 30, pp. 5574-5584, Curran Associates, Inc., 2017.
Volodymyr Kuleshov, Nathan Fenner, and Stefano Ermon. Accurate uncertainties for deep learning using calibrated regression. In International Conference Machine Learning (ICML), 2018.
Balaji Lakshminarayanan, Alexander Pritzel, and Charles Blundell. Simple and scalable predictive uncertainty estimation using deep ensembles. In I. Guyon, U. V. Luxburg, S. Bengio, H. Wallach, R. Fergus, S. Vishwanathan, and R. Garnett (eds.), Advances Neural Information Processing Systems 30, pp. 6402-6413, Curran Associates, Inc., 2017.
Tsung-Yo Yi Lin, Michael Maire, Serge Belongie, James Hays, Pietro Perona, Deva Ramanan, Piotr Dollár, and C. Lawrence Zitnick. Microsoft coco: Common objects in context. In David Fleet, Tomas Pajdla, Bernt Schiele, and Tinne Tuytelaars (eds.), Computer Vision ECCV 2014, 2014.
Mahdi Pakdaman Naeini, Gregory Cooper, and Milos Hauskrecht. Obtaining well calibrated probabilities using bayesian binning. In AAAI, pp. 2901-2907. AAAI Press, 2015.
Alexandru Niculescu-Mizil and Rich Caruana. Predicting good probabilities with supervised learning. In Proceedings of the 22Nd International Conference on Machine Learning. ICML '05, pp. 625- 632, New York, NY, USA, 2005. ACM. ISBN 1-59593-180-5. doi: 10. 10.1145/1102551.110044
D. A. Nix and A. S. Weigend. Estimating the mean and variance of the target probability distribution. In Proceedings of 1994 IEEE International Conference on Neural Networks (CCNN'94), volume 1, pp. 55-60 60 vol.1, June 1994. doi: 10.1109//CNN.1194.337
Buu Phan, Rick Salay, Krzysztof Czarnecki, Vahdat Abdelzad, Taylor Denouden, and Sachin Vernekar. Calibrating uncertainties in object localization task. CoRR, abs/1 81 11111.121101 1210, 2018.
John C. Platt. Probabilistic outputs for support vector machines and comparisons to regularized likelihood methods. In ADVANCES IN LARGE MARGIN CLASSIFIERS, pp. 61-74. MIT Press, 1999.
Olof Thorin. On the infinite divisibility of the lognormal distribution. Scandinavian Actuarial Journal, 1977(3):211148, 1977. doi: 1880004/33 1977. URL BtLlhhtps://oi..co 10. 10.1080/03461233 197.,
Juan Manuel Vera-Diaz, Daniel Pizarro, and Javier Macías Guarasa. Towards end-to-end acous- tic localization using deep learning: from audio signal to source position coordinates. CoRR, abs/1807.1 2018.
Bianca Zadrozny and Charles Elkan. Obtaining calibrated probability estimates from decision trees and naive bayesian classifiers. In Proceedings of the Eighteenth International Conference Machine Learning, ICML '01, pp. 609-616, San Francisco, CA, USA, 2001. Morgan Kaufmann Publishers Inc. ISBN 1-55860-778-1.
10

---

Under review as a conference paper at ICLR 2020
A BOUNDING BOX REGRESSION FOR OBJECT DETECTION: ADDITIONAL DETAILS AND RESULTS
In this section provide additional details the network architecture and datasets used for bounding box prediction as well as additional results using random predictions. As our base architecture we use the R-FCN detector (Dai et al. 2016) with ResNet-101 backbone (He al. 2016). The R-FCN regression branch outputs per region candidate a 4-d vector that parametrizes the bounding box as to (tzz ty. fy.tuw tw t/.) following the accepted parametrization Girshick 2015). We use these outputs in our experiments as four seperate regression outputs. To this architecture we add an uncertainty brunch, identical in structure to the regression brunch, that outputs 4-d vector (u,, U2 43, u4) = (oog(o))loog(
(og(a=), log(o]]) each representing the log variance of the Gaussian distributions of the corresponding output. As before, the original regression output represents the Gaussian mean (i.c. P2= = t.).
For training the network weights we use the entire Common objects in context (COCO) dataset (Lin al., 2014). As stated previously we use two-stage training approach. We first train the original R- FCN network, and then freeze all weights and train only the additional uncertainty prediction branch. In this way train uncertainty prediction without sacrificing the network's accuracy. Note however that our method completely holds if the entire network is trained at once (e.g. if confidence estimation importance is such that accuracy may be marginally sacrified). For uncertainty calibration use the KITTI (Geiger et al. 2012) object detection benchmark dataset, which consists of road scenes. We divide the KITTI dataset into a re-calibration set used for training the calibration parameters (~~ 6K images), and a validation set (~ 1.5K images, 37K object instances). The classes in the KITTI dataset represent a small subset of the classes in the COCO dataset, and therefore we reduce our model training on COCO to the 9 relevant classes (e.g. car, person) and map them accordingly to the KITTI classes.
Figure 5 shows the reliability diagrams for the four bounding box regression outputs with unirained uncertainty before and after we apply our calibration method. As with the synthetic dataset, graphs immediately reveal the disconnect between the random values and the empirical uncertainties. In all the cases the calibration results a highly non-calibrated uncertainty according to our metrics.
ly
027
340
375
400
CD
Figure 5: Reliability diagrams for bounding box regression with untrained uncertainty estima- tion for the bounding box regression outputs (tz, (t.,ty, twr tR). Top row: before calibration, bottom row: after calibration.
11


Reviews:
[{"review_id": "r1lQVT49FB", "reviewer": "AnonReviewer1", "summary": "", "questions": "", "limitations": "", "rating": 1, "confidence": null, "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": "", "summary_of_the_paper": "", "summary_of_the_review": "", "strength_and_weaknesses": "", "limitations_and_societal_impact": "", "review_text": "First, I do not follow the authors’ argumentation in the motivating example where the discus calibration in a mis-specified model. They argue that it should not be possible to calibrate the output of a mis-specified model. It is of course a bad idea to model a Gaussian with a Cauchy distribution (the way it is always a bad idea to have a mis-specified model), but I would actually argue that the isotonic regression based approach by Kuleshov et al., 2018 is more robust against model mis-specification due to its higher flexibility and thus a more powerful approach for pos-hoc calibration. \n\nSecond, I find the approach lacks novelty and is a straightforward application of the well established temperature scaling method and the expected calibration error to regression tasks. In addition, there are only minor differences to Phan et al 2018, CoRR.\n\nMost importantly, I have major concerns regarding the lack of in-depth evaluation. The authors provide no systematic comparison to the state-of-the art (Kuleshov et al., 2018) and only show reliability diagrams (they introduced themselves) for one singe (real) dataset and only their own method.  ", "extra_scores": {"experience_assessment": "I have published one or two papers in this area.", "review_assessment:_checking_correctness_of_derivations_and_theory": "I carefully checked the derivations and theory.", "review_assessment:_checking_correctness_of_experiments": "I carefully checked the experiments.", "review_assessment:_thoroughness_in_paper_reading": "I read the paper thoroughly."}, "extra_text": {}}, {"review_id": "HkgpKUBecS", "reviewer": "AnonReviewer2", "summary": "", "questions": "", "limitations": "", "rating": 1, "confidence": null, "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": "", "summary_of_the_paper": "", "summary_of_the_review": "", "strength_and_weaknesses": "", "limitations_and_societal_impact": "", "review_text": "This paper is concerned with uncertainty calibration diagnostics and re-calibration methods, applied to neural network regression. It is motivated by a flaw in the diagnostic proposed by Kuleshov+ 2018 (abreviated K2018 below), as explained around eq4, and proposes a replacement diagnostic for uncertainty calibration quality (sec 3 before 3.1). It then specialises by considering the class of uncertainty prediction schemes qualified as \"direct\" uncertainty modeling (defined sec1), in which the network predicts the parameters of a parametric distribution over the target output, typically mean and variance of a Gaussian. For this class of schemes, it proposes a recalibration method (sec 3.1), which consists, as shown eq12, of rescaling (with a single parameter $s$) the square root of the variance predicted by the neural network. It then presents experiments (sec4) to demonstrate that the motivating flaw can be evidenced by their diagnostic, and fixed by their recalibration method where it makes sense (ie where predicted uncertainties are not random, i.e. statistically independent of the empirical uncertainty).\n\nThe formal treatment of the issue appears sound, as do the experiments. Nevertheless I believe the paper should be rejected for the following reasons. (1) I fail to see the relevance of the alleged flaw, as explained below. I may have missed something and am looking forward to the author's response. (2) The proposed palliatives are not easy to extend to other forms of uncertainty prediction, even for \"direct\" (parametric) uncertainty modelling schemes, as they are specialised (def of ENCE eq8 and STD coef of variation eq9). (3) The advantage, mentioned just below eq2, of not averaging over data points, breaks down immediately since binning is needed; this is a consequence of outputting probability distributions over continuous variables, in the case of K2018, and of outputting a continuous parameter, $\\sigma^2$, in the present paper.\n\nRegarding (1): I am not surprised that, using K2018's setup, it is possible to recalibrate (i.e. minimise a calibration measure), on a given calibration data set, a model that outputs random uncertainty distributions. The calibration metric alone is not sufficient to measure the goodness of the model: that should take into account prediction sharpness, or test NLL. For a model with random uncertainty output, recalibrated with K2018, I would expect that the miscalibration appears on these other metrics evaluated on the test set.\n\nSuggestions for improvement (did not affect my assessment):\n- the training procedure is mostly common to sec4.1 and sec4.2, and explained relatively clearly: on training set, first train mean using eg L2 loss, then variance output against NLL loss, then recalibration parameter against NLL loss. This procedure could be discussed more explicitly and jointly for both experiments.\n- polishing the text and grammar", "extra_scores": {"experience_assessment": "I have read many papers in this area.", "review_assessment:_thoroughness_in_paper_reading": "I read the paper at least twice and used my best judgement in assessing the paper.", "review_assessment:_checking_correctness_of_experiments": "I assessed the sensibility of the experiments.", "review_assessment:_checking_correctness_of_derivations_and_theory": "I assessed the sensibility of the derivations and theory."}, "extra_text": {}}, {"review_id": "HJxjYldctH", "reviewer": "AnonReviewer3", "summary": "", "questions": "", "limitations": "", "rating": 3, "confidence": null, "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": "", "summary_of_the_paper": "", "summary_of_the_review": "", "strength_and_weaknesses": "", "limitations_and_societal_impact": "", "review_text": "This paper focuses on the calibration for the regression problem. First, it investigates the shortcomings of a recently proposed calibration metric [1] for regression, and show theoretically where this metric can be fooled. Later, it introduces new metrics for measuring the calibration in regression problem which are instantiated from similar idea as the ECE calibration metric [2] used for classification problem. The paper defines the uncertainty as the mean square error and like the ECE idea, it divides the samples into different uncertainty bins and for each bin, it calculates RMSE of network output uncertainty. The RMSE versus variance of estimated uncertainty is depicted as the reliability diagram.\nTo summarize the calibration error as the numbers, the paper proposes two other metrics as ENCE and CV that explain the overall calibration error for the network and calibration error for each sample, respectively. It also shows the effectiveness of the metrics, on the synthetic data where the calibration metric proposed in [1] can be fooled VS. more informative metrics like proposed reliability diagram with RMSE and mVAR.  The other experiment is conducted on object detection problem where the uncertainty of bounding box positional outputs is considered as the calibration for the regression problem. \n\n\nPros:\n1- Investigating theoretically the shortcoming of the calibration metric for regression is interesting\n2- Proposing the new metrics specifically  designed for regression in novel, however it needs more accurate investigation. \n\nCons:\nThe paper is not well-written and the experiments and discussions are not support the ideas, more specifically I can mention several concerns:\n\n1- Motivation: The flaw of the previously proposed calibration metric is not explained clearly. The paper only discusses in which scenario, the metric cannot work properly considering. However, the considered assumption (for instance the output of uncertainty estimation from the network has uniform distribution) can never happen in real scenario. Then the importance of redefining of calibration method is not clear.\n\n2-  Accuracy of Proposed Method: The measure proposed for calibration (Eq. 8) should be shown it will converge to the definition of calibration proposed in Eq.5, which is missing in the paper. \n\n3- Lack of Clarity in some Parts: The paper introduces the  new architecture for adding the uncertainty output to the regression network. But this new architecture is not explained clearly. I suggest the authors add more details about this part.\n\n4- Justification: The paper trains the uncertainty part of the network with NLL loss function and later fine-tunes the output with temperature scaling method. But this calibration  method is not related to the proposed metric which is claimed it has better calibration clarity. Then the importance of using the new metric to define the calibration is not clear. \n\n5- Experiments: The experiment setup needs more accuracy. The paper should investigate the shortcomings of the previous metric in the same setting as the new proposed metric. In experiment Sec. 4.1, the settings for obtaining the output of the network uncertainty is different then comparing the results are not fare.  The experiments for real scenario is not wide enough. It just shows that the parameters get calibrated. However we expect to see more results about the CV metric and its importance to define.  \n  \nOverall, I think this paper should be rejected as 1) the novelty of proposed metrics are not enough. 2) the motivation and justification of why the proposed metrics is better than previous metrics is not clear. 3) the experiments are not supporting the idea.\n\nReferences:\n\n[1]  Kuleshov, Volodymyr, Nathan Fenner, and Stefano Ermon. \"Accurate Uncertainties for Deep Learning Using Calibrated Regression.\" International Conference on Machine Learning. 2018.\n\n[2] Naeini, Mahdi Pakdaman, Gregory Cooper, and Milos Hauskrecht. \"Obtaining well calibrated probabilities using bayesian binning.\" Twenty-Ninth AAAI Conference on Artificial Intelligence. 2015.\n", "extra_scores": {"experience_assessment": "I have published one or two papers in this area.", "review_assessment:_checking_correctness_of_derivations_and_theory": "I assessed the sensibility of the derivations and theory.", "review_assessment:_checking_correctness_of_experiments": "I carefully checked the experiments.", "review_assessment:_thoroughness_in_paper_reading": "I read the paper at least twice and used my best judgement in assessing the paper."}, "extra_text": {}}]

Author rebuttal:

Meta-review: The paper investigates calibration for regression problems. The paper identifies a shortcoming of previous work by Kuleshov et al. 2018 and proposes an alternative. 

All the reviewers agreed that while this is an interesting direction, the paper requires more work before it can be accepted. In particular, the reviewers raised several concerns about motivation, clarity of the presentation and lack of in-depth empirical evaluation.

I encourage the authors to revise the draft based on the reviewers’ feedback and resubmit to a different venue.

Decision: Reject