# Poster 31481

- Kind: Poster
- Talk page and recording: https://iclr.cc/virtual/2025/poster/31481

> Transcript of the talk's recording (session_asr), made by speech recognition or taken from the host's captions. It may contain errors. The words are the speakers'; listen to the recording on the talk's page before quoting it.

Hello, I'm Jacek and today I'll be talking about unbiased calibration using meta -regularization. This is work by Chang Wang and myself and it was done while both of us were at Amazon. So what is calibration? In the real world decision-making systems, classification networks should not only be accurate but also should reliably indicate when they're likely to be unconfident. So this is measured by calibration, which is a problem of predicting probability estimates representative of the true correctness likelihood.
So to make that happen, we consider confidence with the probability of a data point X having label Y as predicted by the classifier and accuracy, which is the fraction of data points with the correct label assignment.
So using those two values, we can compute the key metrics for calibration, ECE and MCE. ECE is the expected calibration error, and it's an expectation of the calibration error across all points. The MCE is the maximum calibration error. This is simply the maximum of the calibration error.
So our proposed approach for regularizing a neural network relies on using a focal loss for calibration. So focal loss is a parameterized modification of the standard cross -entropy that is used to better deal with long tail classes. So Lin and all have found that it helps with calibration, but they leave the hyperparameter of the loss as a hyperparameter of the whole method.
So it needs to be set before the training gets started. So in our work, we include two new components to the training. The first one is the gamma net, which is a meta network designed to learn a sample-wise gamma values that can be used for training with focal loss. And using this, we don't have to rely on a single predefined gamma value or a gamma value scheduler.
We also introduce SECE, which is a differentiable proxy of expected calibration error that we use to optimize the gamma net on the validation set. So, what is the gamma net? So, here we introduce a learnable approach with a gamma network that learns a fine-grained and local gamma values.
So for each sample, a gamma predicts an individual gamma value in the continuous space. And this gamma value can be plugged in into the focal loss for this particular example and then used for optimal training. In the formula, gamma takes the representation from the second to last layer of the backbone network and predict the best gamma value for the example, which then can be useful.
So, the second part is S_E_C, which is a smooth estimator of the E_C_E, which replaces the binning approach normally used in expected calibration error for a kernel-based estimation that can be applied sample by sample. For accuracy, we leverage the accuracy of other points in the vicinity of the chosen example, weighted by their distance in the confidence space, and for confidence, we suggest the standard confidence value for the example. Combined together, they form a differentiable unbiased estimator of the E_C_E.
So, how do you actually use the two to run a meta -learning to get a nice calibrated classifier? So, the algorithm starts with the initialized backbone network, this is the one you use for classification, and the gamma network, this is the one used for predicting the gamma parameter of the focal loss.
So we of course need also the training set and the validation set. So during that training loop at each iteration we sample a mini-batch of training data and a mini-batch of the validation data.
So we use the GammaNet to predict the right gamma value for each example in the training set, and then we use those gamma values to update the parameters of the backbone network. So essentially each gamma value is plugged into the focal loss, and then the focal loss is used to update the backbone network. So after the backbone network is updated, we use the validation mini-batch.
on the s-e-c-e loss to update the parameters of the gamma network so after this is done the whole loop repeats right so it's always going to be update like predict the gamma values update the backward network in the gamma values and then update the gamma network so let's let's take a look at the results we have run extensive evaluations c4 10 c4 100 and tiny image net
And the results are really overwhelming here, but the key point is that our approach, so focal loss.
with the gamma net, I believe the gamma predicted using SECE achieves lower errors across multiple calibration metrics. So those are highlighted in bold and in the red banners. And our approach also achieves comparable predictive performance, which means that we gain in the calibration metrics, but we do not lose any accuracy, which means it's a good approach to implementing your production workbooks.
And yeah, so finally, I would like to leave you with this image of two networks that essentially have the same accuracy, but actually only one of them is calibrated and can be used to run production workloads. Okay, thank you very much and I invite you to come to our poster to learn more.
