Skip to content
Snippets Groups Projects
Commit 70c64d51 authored by Schneider Leo's avatar Schneider Leo
Browse files

fix : acc contrastive

parent 38f7a7b4
No related branches found
No related tags found
No related merge requests found
......@@ -153,18 +153,21 @@ def make_prediction_duo(model, data, f_name, f_name2):
label = label.long()
specie = torch.argmin(label)
if torch.cuda.is_available():
imaer = imaer.cuda()
imana = imana.cuda()
img_ref = img_ref.cuda()
label = label.cuda()
output = model(imaer,imana,img_ref)
print(output, label)
confidence_pred_list[specie].append(output[:,0].data.cpu().numpy())
#Mono class output (only most postive paire)
output = torch.argmax(output[:,0]).data.cpu().numpy()
output = torch.argmax(output[:,0])
y_pred.extend(output)
label = torch.argmin(label).data.cpu().numpy()
label = torch.argmin(label)
y_true.extend(label) # Save Truth
# constant for classes
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment