Skip to content

Commit

Permalink
Update to change factorial
Browse files Browse the repository at this point in the history
  • Loading branch information
Carole Sudre authored and Carole Sudre committed Sep 26, 2024
1 parent 7277da0 commit e549ee0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion MetricsReloaded/metrics/calibration_measures.py
Original file line number Diff line number Diff line change
Expand Up @@ -236,7 +236,7 @@ def kernel_calibration_error(self):
vect_j = one_hot_ref[j,:] - self.pred[j,:]
value_ij = np.matmul(vect_i, np.matmul(kernel,vect_j.T))
sum_tot += value_ij
multiplicative_factor = math.factorial(numb_samples)/ (2 * np.math.factorial(numb_samples-2))
multiplicative_factor = math.factorial(numb_samples)/ (2 * math.factorial(numb_samples-2))
kce = 1/multiplicative_factor * sum_tot
return kce

Expand Down

0 comments on commit e549ee0

Please sign in to comment.