Skip to content

Commit

Permalink
Merge pull request #74 from AntoineSimoulin/patch-1
Browse files Browse the repository at this point in the history
馃悰 fix trunctation when preparing bert data
  • Loading branch information
farthur committed Dec 3, 2020
2 parents 9bccac9 + b24ab2e commit 53d7f99
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion melusine/models/train.py
Original file line number Diff line number Diff line change
Expand Up @@ -449,7 +449,7 @@ def _prepare_bert_sequences(self, X):
else:
sequence = X[self.text_input_column].values.tolist()
seqs = self.tokenizer.batch_encode_plus(
sequence, max_length=self.seq_size, padding="max_length"
sequence, max_length=self.seq_size, padding="max_length", truncation=True
)

return (
Expand Down

0 comments on commit 53d7f99

Please sign in to comment.