罗俊辉 1 рік тому
батько
коміт
c9f7d4db41
1 змінених файлів з 2 додано та 2 видалено
  1. 2 2
      result_analysis.py

+ 2 - 2
result_analysis.py

@@ -16,13 +16,13 @@ def analysis(data):
             true_count += 1
         if int(pred_tag) == 1:
             pred_count += 1
-        if true_tag == pred_tag == 1:
+        if int(true_tag) == int(pred_tag) == 1:
             accuracy_count += 1
         total_count += 1
     print("预测为 1 的数量", pred_count)
     print("实际为 1 的数量", true_count)
     print("预测为 1,实际也为 1 的数量", accuracy_count)
-    print("total_video", true_count)
+    print("total_video", total_count)
 
 
 if __name__ == '__main__':