Hi, I have confusion about optimizing the loss objective with SGD


loss=1-F.cosine_similarity(x,y) and loss= -F.cosine_similarity(x,y), are these two represent to minimize the similarity using SGD? Apparently,  (1-Cosinesim) seems suitable to me  but i have seen the (-CosineSim) in a contrastive Self-Supervise learning objective. So how these two behave differently?


whats the difference between : loss = -F.crossentropy(logits, label) and loss=F.crossentropy(-logits, label) ? are these two represents to maximize the cross entropy ?