Varun Wadhwa commited on
Commit
1f849a3
·
unverified ·
1 Parent(s): 157d28c
Files changed (1) hide show
  1. app.py +4 -4
app.py CHANGED
@@ -151,10 +151,10 @@ def evaluate_model(model, dataloader, device):
151
  print("evaluate_model sizes")
152
  print(len(all_preds))
153
  print(len(all_labels))
154
- print(id2label(all_preds[0]))
155
- print(id2label(all_labels[0]))
156
- print(id2label(all_preds[1]))
157
- print(id2label(all_labels[1]))
158
  all_preds = np.asarray(all_preds, dtype=np.float32)
159
  all_labels = np.asarray(all_labels, dtype=np.float32)
160
  accuracy = accuracy_score(all_labels, all_preds)
 
151
  print("evaluate_model sizes")
152
  print(len(all_preds))
153
  print(len(all_labels))
154
+ for i in range(min(100, len(all_labels))):
155
+ print("Pred vs Label")
156
+ print(id2label[all_preds[i]])
157
+ print(id2label[all_labels[i]])
158
  all_preds = np.asarray(all_preds, dtype=np.float32)
159
  all_labels = np.asarray(all_labels, dtype=np.float32)
160
  accuracy = accuracy_score(all_labels, all_preds)