diff --git a/image_ref/main.py b/image_ref/main.py
index 001af33fd3057f11f11eeec54377e0d3c6b6976e..dc6b1f6099b833ccf42bf35a1bc4ae24549f5f04 100644
--- a/image_ref/main.py
+++ b/image_ref/main.py
@@ -61,7 +61,7 @@ def test_duo(model, data_test, loss_function, epoch):
         label_class = torch.argmin(label).data.cpu().numpy()
         pred_logits = model.forward(imaer,imana,img_ref)
         pred_class = torch.argmax(pred_logits[:,0])
-        acc_contrastive += (torch.argmax(pred_logits,dim=1).data.cpu().numpy()==label).sum().item()
+        acc_contrastive += (torch.argmax(pred_logits,dim=1).data.cpu().numpy()==label.data.cpu().numpy()).sum().item()
         acc += (pred_class==label_class)
         loss = loss_function(pred_logits,label)
         losses += loss.item()