Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -95,7 +95,18 @@ def compute_metrics(p: EvalPrediction):
|
|
95 |
return result
|
96 |
|
97 |
|
98 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
99 |
|
100 |
"""
|
101 |
|
|
|
95 |
return result
|
96 |
|
97 |
|
98 |
+
trainer = Trainer(
|
99 |
+
model,
|
100 |
+
args,
|
101 |
+
train_dataset=encoded_dataset["train"],
|
102 |
+
eval_dataset=encoded_dataset["validation"],
|
103 |
+
tokenizer=tokenizer,
|
104 |
+
compute_metrics=compute_metrics
|
105 |
+
)
|
106 |
+
|
107 |
+
trainer.train()
|
108 |
+
|
109 |
+
trainer.evaluate()
|
110 |
|
111 |
"""
|
112 |
|