Update README.md
Browse files
README.md
CHANGED
|
@@ -79,7 +79,7 @@ test_tokenized_dataset.set_format(type='torch', columns=['input_ids', 'attention
|
|
| 79 |
# Load the model from the specified directory
|
| 80 |
pipe = TextClassificationPipeline(model=model, tokenizer=tokenizer, device=0)
|
| 81 |
# Save the predictions to the output file
|
| 82 |
-
predictions_test = pipe(
|
| 83 |
actual_labels_test = []
|
| 84 |
for prediction in predictions_test:
|
| 85 |
pred_label = prediction['label']
|
|
|
|
| 79 |
# Load the model from the specified directory
|
| 80 |
pipe = TextClassificationPipeline(model=model, tokenizer=tokenizer, device=0)
|
| 81 |
# Save the predictions to the output file
|
| 82 |
+
predictions_test = pipe(test_texts, truncation=True, max_length=256)
|
| 83 |
actual_labels_test = []
|
| 84 |
for prediction in predictions_test:
|
| 85 |
pred_label = prediction['label']
|