嘉渊
2023-05-25 cefa8ff17e3e2f4a7745d15a59beef0a255fabfd
funasr/losses/label_smoothing_loss.py
@@ -97,7 +97,7 @@
        normalize_length=False,
        criterion=nn.NLLLoss(reduction='none'),
    ):
        """Construct an LabelSmoothingLoss object."""
        """Construct an NllLoss object."""
        super(NllLoss, self).__init__()
        self.criterion = criterion
        self.padding_idx = padding_idx