The Validation loss stays constant when nn.CosineEmbeddingLoss() function is used, while nn.CrossEntropy() is working fine.