July 2017
Intermediate to advanced
254 pages
6h 29m
English
Multi-label classification problems must be assessed using different performance measures than single-label classification problems. Two of the most common performance metrics are hamming loss and Jaccard similarity. Hamming loss is the average fraction of incorrect labels. Note that hamming loss is a loss function and that the perfect score is 0. Jaccard similarity, or the Jaccard index, is the size of the intersection of the predicted labels and the true labels divided by the size of the union of the predicted and true labels. It ranges from 0 to 1, and 1 is the perfect score. Jaccard similarity is given by the following equation:
# In[1]:import numpy as npfrom sklearn.metrics import hamming_loss, ...Read now
Unlock full access