Computer scienceData scienceInstrumentsScikit-learnModel evaluation with scikit-learn

sklearn.metrics.classification_report()

Classification report on binary classification task

Report a typo

Complete the solution() function that receives two lists of a binary classification problem: true and predicted labels. The function should print the classification report for these labels.

Example input:

true_labels = ['apple', 'banana', 'apple', 'apple', 'apple', 'apple', 'apple', 'apple']
predicted_labels = ['banana', 'banana', 'banana', 'apple', 'banana', 'apple', 'apple', 'apple']
Write a program in Python 3
def solution(true_labels, predicted_labels):
pass
___

Create a free account to access the full topic