Skip to content

Commit

Permalink
print
Browse files Browse the repository at this point in the history
  • Loading branch information
alicebizeul committed Apr 16, 2023
1 parent 6a64f89 commit 2586e34
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion simclr/modules/custom_infonce.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ def forward(self, anchor_rec, positive_rec):
# total_loss_value = torch.mean(- pos + neg)
if self.bound:
if self.subsample:
keep=random.shuffle(list(np.arange(anchor_rec.shape[1])))
keep=random.shuffle(list(np.arange(int(anchor_rec.shape[1]))))
print(keep) #[:int(int(anchor_rec.shape[1])/2)]
sim11=sim11[:,keep,:]
sim12=sim12[:,keep,:]
Expand Down

0 comments on commit 2586e34

Please sign in to comment.