Regression Methods for Geospatial DataPart 3 of 4Intermediate · Updated December 1, 2026
Calibration and Proper Scoring Rules
A forecast in is a probability only if it is calibrated: among all the cases where the model says 0.3, the event occurs about 30% of the time. A decision that weighs an expected cost against another cost uses the probability values themselves, so it needs calibration, which ranking metrics do not measure.
Ranking and calibration are different properties
Passing a model’s output through any strictly increasing function (squaring it, taking its square root, applying a sigmoid) preserves the order of every pair of predictions. As a result:
- ROC-AUC is unchanged, since it depends only on the ordering.
- Precision, recall and accuracy at a tuned threshold are unchanged, since the threshold moves with the transform.
- The probabilities themselves change.
Models that differ only by such a transform report different confidence but score identically on these metrics. When the output is multiplied by a cost or compared against an externally chosen threshold, they are not interchangeable, and a metric is needed that distinguishes them.
Proper scoring rules reward reporting the true probability
A scoring rule is proper if a forecaster minimises the expected penalty by reporting the true probability. Under an improper rule, exaggerating confidence can lower the score, so the rule cannot detect miscalibration.
Binary cross-entropy (log loss) is proper:
If the true probability is and the forecast is , the expected loss has its unique minimum at , so BCE is strictly proper. The Brier score, , is also strictly proper. Accuracy is not: it is maximised by reporting 0 or 1 regardless of the underlying probability. A model fitted end to end on BCE is therefore driven towards calibrated forecasts, whereas fitting on accuracy would reward overconfidence.
A reliability diagram shows calibration directly
A reliability diagram bins the predictions and plots the observed frequency in each bin against the mean predicted probability. A calibrated model lies on the diagonal. Points below the diagonal mean the event occurred less often than predicted (overconfident); points above mean the reverse.
Two features make these diagrams easy to misread. A bin with nine samples is drawn as prominently as one with nine thousand, so the noisiest part of the curve is often the most visible; the bin counts should be shown alongside. The number of bins is also a choice: too few hide structure, too many turn the curve into noise.
Platt scaling rescales the logit
A calibration map is a monotone function, fitted after the model, with few parameters. Platt scaling works in logit space, where probabilities become unbounded:
and applies an affine map before transforming back:
The two parameters are fitted on held-out data by minimising BCE; is the identity. Dividing the logit by moves it towards zero, which corresponds to , so:
- softens: predictions move towards 0.5.
- sharpens: predictions move towards 0 and 1.
corrects a systematic offset; a negative lowers every prediction, as needed when a model over-predicts the positive class.
The map is strictly increasing, so calibration neither improves nor degrades the ranking. It can therefore be fitted last, on a small held-out set, without changing what the model has learned about ordering.
Beta calibration corrects the two ends separately
Platt scaling has a single shape parameter, which stretches the logit by the same factor everywhere. It cannot soften the rare high forecasts without also moving the many forecasts near zero, which is often the correction needed at low prevalence.
Beta calibration (Kull, Silva Filho and Flach, 2017) adds a shape parameter. It is logistic in and separately rather than in their difference:
The three parameters are fitted on held-out data by BCE. The map is the exact correction when the model’s scores for each class follow Beta distributions, a natural assumption for values in . Three properties matter in practice:
- It contains Platt scaling. With the log terms combine into , so is Platt scaling with temperature , and is the identity.
- It is monotone when . With this constraint it changes no ranking, so ROC-AUC and PR-AUC are unchanged.
- The shape parameters act on different ends. governs the map as and as , so it can soften the high forecasts without moving those near zero, or the reverse.
Miscalibration can also vary across cases: a forecast may be overconfident when its evidence is recent and underconfident when it relies on the prior. One remedy is to fit a separate calibration map for each regime, for example for each forecast lead time, interpolating between them. Each map is monotone, so none changes which places the forecast ranks highest.
A fitted temperature measures the miscalibration
Since is the identity, the distance of the fitted from 1 measures how miscalibrated the raw model was, and its direction shows which way. The same reading applies to beta calibration: and below 1 soften, above 1 sharpen.
A kernel estimator like the one in the previous tutorial can be overconfident (). A weighted mean of labels near 0 or 1 inherits their extremity, and the denominator counts a dozen correlated observations from one source (a single flight, say) as a dozen independent ones. Redundant evidence is indistinguishable from strong evidence, and a fitted temperature then partly reflects that redundancy.
Assumptions and failure modes
A post-hoc map corrects the symptom, not its cause: the estimator is overconfident because it does not model how its observations are correlated. One response is to fit the calibration map jointly with the estimator, so that the length scales and prior are learned with the map in place. The other is an estimator that models the correlation directly, a Gaussian process.
A calibration map also cannot repair a poor ranking, and it is only as reliable as the data it is fitted on.
Summary
- Ranking metrics such as ROC-AUC are unchanged by monotone transforms and cannot detect miscalibration; strictly proper scores such as BCE and the Brier score can.
- Reliability diagrams show calibration directly; bin counts should be shown alongside.
- Platt scaling rescales the logit with one shape parameter; beta calibration has two and can correct the high and low ends separately. Both preserve the ranking.
- Overconfidence in kernel estimators partly reflects correlated evidence counted as independent.
Gaussian Process Regression models that correlation directly and returns an uncertainty with each estimate.
References
- Brier, G. W. (1950). Verification of forecasts expressed in terms of probability. Monthly Weather Review, 78(1), 1–3. doi:10.1175/1520-0493(1950)078<0001:VOFEIT>2.0.CO;2
- Gneiting, T., & Raftery, A. E. (2007). Strictly proper scoring rules, prediction, and estimation. Journal of the American Statistical Association, 102(477), 359–378. doi:10.1198/016214506000001437
- Niculescu-Mizil, A., & Caruana, R. (2005). Predicting good probabilities with supervised learning. Proceedings of the 22nd International Conference on Machine Learning (ICML), 625–632. doi:10.1145/1102351.1102430
- Kull, M., Silva Filho, T., & Flach, P. (2017). Beta calibration: A well-founded and easily implemented improvement on logistic calibration for binary classifiers. Proceedings of the 20th International Conference on Artificial Intelligence and Statistics (AISTATS), PMLR 54, 623–631. proceedings.mlr.press
- Guo, C., Pleiss, G., Sun, Y., & Weinberger, K. Q. (2017). On calibration of modern neural networks. Proceedings of the 34th International Conference on Machine Learning (ICML), PMLR 70, 1321–1330. proceedings.mlr.press