pranjalchitale
commited on
Commit
•
f63eb00
1
Parent(s):
f5d8281
Update modeling_indictrans.py
Browse files- modeling_indictrans.py +1 -1
modeling_indictrans.py
CHANGED
@@ -1393,7 +1393,7 @@ class IndicTransForConditionalGeneration(IndicTransPreTrainedModel):
|
|
1393 |
masked_lm_loss = F.cross_entropy(
|
1394 |
input=lm_logits.view(-1, self.config.decoder_vocab_size),
|
1395 |
target=labels.view(-1),
|
1396 |
-
ignore_index
|
1397 |
label_smoothing=self._label_smoothing,
|
1398 |
)
|
1399 |
|
|
|
1393 |
masked_lm_loss = F.cross_entropy(
|
1394 |
input=lm_logits.view(-1, self.config.decoder_vocab_size),
|
1395 |
target=labels.view(-1),
|
1396 |
+
ignore_index=-100,
|
1397 |
label_smoothing=self._label_smoothing,
|
1398 |
)
|
1399 |
|