From 60a1647fb59852fa093af21e5586f7450bf3638a Mon Sep 17 00:00:00 2001 From: padg9912 Date: Tue, 26 May 2026 22:37:16 -0400 Subject: [PATCH] Fix SyntaxWarning in ece_confidence_multiclass docstring (#1142) --- pyhealth/metrics/calibration.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyhealth/metrics/calibration.py b/pyhealth/metrics/calibration.py index 32e27b617..d9f755f61 100644 --- a/pyhealth/metrics/calibration.py +++ b/pyhealth/metrics/calibration.py @@ -99,7 +99,7 @@ def _ECE_classwise(prob:np.ndarray, label_onehot:np.ndarray, bins=20, threshold= return summs, class_losses def ece_confidence_multiclass(prob:np.ndarray, label:np.ndarray, bins=20, adaptive=False): - """Expected Calibration Error (ECE). + r"""Expected Calibration Error (ECE). We group samples into 'bins' basing on the top-class prediction. Then, we compute the absolute difference between the average top-class prediction and