Learn Before
Concept
Max-margin loss
Max-margin loss (also known as hinge loss) is a loss function used to compare the decoded score of a true pair to a negative sample. Instead of formulating the problem as a binary classification task, it compares the direct outputs of the decoders. If the score for the positive (true) pair exceeds that of the negative pair by at least a margin , the loss is zero. Otherwise, a loss is incurred. This can be mathematically expressed as:
where and represent the decoded scores for the true and negative pairs, respectively.

0
1
Updated 2026-07-03
Tags
Data Science