Skip to content

Commit 069ab10

Browse files
Carole SudreCarole Sudre
authored andcommitted
Correction of warning for probabilistic input
1 parent 663de49 commit 069ab10

2 files changed

Lines changed: 4 additions & 1 deletion

File tree

MetricsReloaded/metrics/calibration_measures.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -138,6 +138,9 @@ def expectation_calibration_error(self):
138138
"""
139139
Derives the expectation calibration error in the case of binary task
140140
bins_ece is the key in the dictionary for the number of bins to consider
141+
Cheat sheet SN 3.68 p113
142+
Defined in Mahdi Pakdaman Naeini, Gregory Cooper, and Milos Hauskrecht. Obtaining well calibrated probabilities using
143+
bayesian binning. In Twenty-Ninth AAAI Conference on Artificial Intelligence, 2015.
141144
Default is 10
142145
143146
.. math::

MetricsReloaded/processes/mixed_measures_processes.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -776,7 +776,7 @@ def per_label_dict(self):
776776
dict_mt["label"] = lab
777777
dict_mt["case"] = name
778778
list_mt.append(dict_mt)
779-
else:
779+
if not self.flag_valid_proba and len(self.measures_mt)>0:
780780
warnings.warn('No probabilistic input or no probabilistic measure so impossible to get multi-threshold metric')
781781
else:
782782
list_pred.append(pred_tmp)

0 commit comments

Comments
 (0)