API symbolsnn
Copy
tensorplay.nn.functional.triplet_margin_loss
- tensorplay.nn.functional.triplet_margin_loss(anchor: TensorBase, positive: TensorBase, negative: TensorBase, margin: float = 1.0, p: float = 2, eps: float = 1e-06, swap: bool = False, size_average=None, reduce=None, reduction: str = 'mean') TensorBase[source]
Compute the triplet loss between given input tensors and a margin greater than 0.
See
TripletMarginLossfor details.
Help improve this page
Found an error, an unclear step, or a missing example?
Was this page helpful?
