Commit 6bd66d16 by Pamela Osuna

no changes

parent 0420074e
......@@ -379,11 +379,6 @@ class CNN_Antifrag:
y_test = encode(y_test)
y_pred = encode(y_pred)
# calculate area under the curve
fpr, tpr, auc = ra.roc_auc(N, y_test, y_pred)
total_auc += auc
print("Area under the curve:", auc)
# confusion matrix
if i == 0:
cm = confusion_matrix(
......@@ -398,6 +393,11 @@ class CNN_Antifrag:
precs_k.append(precision)
avgs_k.append(average_prec)
#auc
fpr, tpr, auc = ra.roc_auc(N, y_test, y_pred)
# calculate area under the curve
total_auc += auc
print("Area under the curve:", auc)
total_acc = total_acc/K
total_auc = total_auc/K
......@@ -406,4 +406,4 @@ class CNN_Antifrag:
print("Average accuracy: ", total_acc)
print("Average area under the curve: ", total_auc)
return total_acc, total_auc, cm, pr
return total_acc, total_auc, cm, pr, roc
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment