Confusion Matrix function

This commit is contained in:
lucas de oliveira carvalho 2022-10-11 09:23:53 -03:00
parent f9e93bf8ba
commit bd842f4a2b

View File

@ -51,9 +51,4 @@ def make_confusion_matrix(y_true, y_pred, classes=None, figsize=(10, 10), text_s
# Save the figure to the current working directory
if savefig:
fig.savefig("confusion_matrix.png")
y_true = [0, 0, 0, 0, 1, 1, 1, 0, 1, 0, 1, 0, 1, 0, 1, 0, 1, 1, 1, 0]
y_pred = [0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 0, 0, 1, 0, 1, 1, 1, 0, 1, 0]
make_confusion_matrix(y_true, y_pred)
fig.savefig("confusion_matrix.png")