How to get all confusion matrix terminologies (TPR, FPR, TNR, FNR) for a multi class?
问题 I have a code that can print the confusion matrix for a multiclass classification problem. import itertools import numpy as np import matplotlib.pyplot as plt from sklearn import svm, datasets from sklearn.model_selection import train_test_split from sklearn.metrics import confusion_matrix # import some data to play with iris = datasets.load_iris() X = iris.data y = iris.target class_names = iris.target_names # Split the data into a training set and a test set X_train, X_test, y_train, y_test