I have two arrays like:
correct = [['*','*'],['*','PER','*','GPE','ORG'],['GPE','*','*','*','ORG']]
predicted = [['PER','*'],['*','ORG','*','GPE','ORG'],['PER','*','*','*','MISC']]
Length of correct and predicted is same(10K+) also the length of each positional element in two arrays have the same length. I want to calculate the precision, recall, and f1 score for such two arrays using python. I Have following 6 classes: 'PER','ORG','MISC','LOC','*','GPE'
want to calculate precision and recall for 5 of the classes (Except '*') also to find f1 score. what can be the efficient way to perform this using python?