소스 검색

working model used at poster

Ruben 4 달 전
부모
커밋
38ca4cb5bb
1개의 변경된 파일5개의 추가작업 그리고 1개의 파일을 삭제
  1. 5 1
      utils/CNN.py

+ 5 - 1
utils/CNN.py

@@ -9,7 +9,7 @@ import pandas as pd
 import matplotlib.pyplot as plt
 import time
 import numpy as np
-from sklearn.metrics import roc_curve, auc, confusion_matrix
+from sklearn.metrics import roc_curve, auc, confusion_matrix, classification_report
 import seaborn as sns
 
 class CNN_Net(nn.Module):
@@ -182,6 +182,10 @@ class CNN_Net(nn.Module):
             plt.savefig('./confusion_matrix.png')
             plt.show()
 
+            # Classification Report
+            report = classification_report(true_labels, predictionsLabels)
+            print(report)
+
         self.train()
 
         return(loss.item())