-
-
Notifications
You must be signed in to change notification settings - Fork 26.4k
Closed
Labels
Description
| h_true, h_pred = entropy(labels_true), entropy(labels_pred) |
entropy must be inputed with frequency table of labels_true / labels_pred, not those array directly.
Example solution
from collections import Counter
freq_table = [x[1] for x in dict(Counter(labels_true)).items()]
entropy(freq_table)