pierreguillou
commited on
Commit
•
faaca22
1
Parent(s):
1ab4de9
Update files/functions.py
Browse files- files/functions.py +1 -0
files/functions.py
CHANGED
@@ -728,6 +728,7 @@ def predictions_line_level(dataset, outputs, images_ids_list, chunk_ids, input_i
|
|
728 |
probs_label = list()
|
729 |
for probs_list in probs:
|
730 |
prob_label = reduce(lambda x, y: x*y, probs_list)
|
|
|
731 |
probs_label.append(prob_label)
|
732 |
max_value = max(probs_label)
|
733 |
max_index = probs_label.index(max_value)
|
|
|
728 |
probs_label = list()
|
729 |
for probs_list in probs:
|
730 |
prob_label = reduce(lambda x, y: x*y, probs_list)
|
731 |
+
prob_label = prob_label**(1./(len(probs_list))) # normalization
|
732 |
probs_label.append(prob_label)
|
733 |
max_value = max(probs_label)
|
734 |
max_index = probs_label.index(max_value)
|