Update README.md
Browse filesmax_length param added to Hugging Face Transformer part
README.md
CHANGED
|
@@ -63,7 +63,7 @@ tokenizer = AutoTokenizer.from_pretrained('mpi-inno-comp/paecter')
|
|
| 63 |
model = AutoModel.from_pretrained('mpi-inno-comp/paecter')
|
| 64 |
|
| 65 |
# Tokenize sentences
|
| 66 |
-
encoded_input = tokenizer(sentences, padding=True, truncation=True, return_tensors='pt')
|
| 67 |
|
| 68 |
# Compute token embeddings
|
| 69 |
with torch.no_grad():
|
|
|
|
| 63 |
model = AutoModel.from_pretrained('mpi-inno-comp/paecter')
|
| 64 |
|
| 65 |
# Tokenize sentences
|
| 66 |
+
encoded_input = tokenizer(sentences, padding=True, truncation=True, return_tensors='pt', max_length=512)
|
| 67 |
|
| 68 |
# Compute token embeddings
|
| 69 |
with torch.no_grad():
|