torch.nn.functional.multilabel_margin_loss#
- torch.nn.functional.multilabel_margin_loss(input, target, size_average=None, reduce=None, reduction='mean')[source]#
Compute the multilabel margin loss.
See
MultiLabelMarginLoss
for details.- Parameters
input (Tensor) โ Predicted values.
target (Tensor) โ Ground truth values.
size_average (bool, optional) โ Deprecated (see
reduction
).reduce (bool, optional) โ Deprecated (see
reduction
).reduction (str, optional) โ Specifies the reduction to apply to the output: โnoneโ | โmeanโ | โsumโ. โmeanโ: the mean of the output is taken. โsumโ: the output will be summed. โnoneโ: no reduction will be applied. Default: โmeanโ.
- Returns
Mutilabel margin loss.
- Return type