Hi all,
I’m new at Python, thus I’m not very familiar with its syntax yet. I just want to confirm in the confusion matrix visualization part of the, in function compute_confusion_matrix(metrics, labels)
there is this code snippet:
label_to_index = {l:i for i,l in enumerate(labels)}
Is this some sort of “list comprehension” syntax? So it’s possible to use list comprehension to create not only list but also dictionary?
Thanks,
chalkdust