FlagEmbedding icon indicating copy to clipboard operation
FlagEmbedding copied to clipboard

How can I customize the loss function? It seems that cross-entropy does not push the distance between positive and negative samples far enough.

Open QuangTQV opened this issue 1 year ago • 1 comments

QuangTQV avatar Aug 05 '24 10:08 QuangTQV

Currently, we only implement cross-entropy in this repo. If you want to use more loss functions, you need to add the code in modeling.py.

staoxiao avatar Aug 10 '24 15:08 staoxiao