Figured out a solution. In this line, the argument parsed into the definition of contrastive loss have 'batch_size=batch_size*2'. However, in the function, the batch size has been multiplied again. The problem was fixed when I set 'batch_size=batch_size' in the definition. If it is the case, I would send a PR to fix that.
Originally posted by @Eason-Qin in #624 (comment)
Figured out a solution. In this line, the argument parsed into the definition of contrastive loss have 'batch_size=batch_size*2'. However, in the function, the batch size has been multiplied again. The problem was fixed when I set 'batch_size=batch_size' in the definition. If it is the case, I would send a PR to fix that.
Originally posted by @Eason-Qin in #624 (comment)