Module: tfa.losses.npairs

View source on GitHub

Implements npairs loss.

Classes

class NpairsLoss: Computes the npairs loss between y_true and y_pred.

class NpairsMultilabelLoss: Computes the npairs loss between multilabel data y_true and y_pred.

Functions

TensorLike(...): Union type; Union[X, Y] means either X or Y.

check_if_windows(...)

npairs_loss(...): Computes the npairs loss between y_true and y_pred.

npairs_multilabel_loss(...): Computes the npairs loss between multilabel data y_true and y_pred.