lets not make order an arg for now
Browse files
gleu.py
CHANGED
@@ -183,7 +183,6 @@ class gleu(evaluate.Metric):
|
|
183 |
{
|
184 |
"predictions": datasets.Value("string", id="sequence"),
|
185 |
"references": datasets.Value("string", id="sequence"),
|
186 |
-
"order": datasets.Value("int32"),
|
187 |
}
|
188 |
),
|
189 |
codebase_urls=["https://github.com/cnap/gec-ranking/"],
|
@@ -194,11 +193,13 @@ class gleu(evaluate.Metric):
|
|
194 |
# TODO: Download external resources if needed
|
195 |
pass
|
196 |
|
197 |
-
def _compute(self, references, predictions
|
198 |
"""Returns the scores"""
|
199 |
|
200 |
num_iterations = 500
|
201 |
|
|
|
|
|
202 |
if len(references)==1:
|
203 |
num_iterations = 1
|
204 |
|
|
|
183 |
{
|
184 |
"predictions": datasets.Value("string", id="sequence"),
|
185 |
"references": datasets.Value("string", id="sequence"),
|
|
|
186 |
}
|
187 |
),
|
188 |
codebase_urls=["https://github.com/cnap/gec-ranking/"],
|
|
|
193 |
# TODO: Download external resources if needed
|
194 |
pass
|
195 |
|
196 |
+
def _compute(self, references, predictions):
|
197 |
"""Returns the scores"""
|
198 |
|
199 |
num_iterations = 500
|
200 |
|
201 |
+
order=4
|
202 |
+
|
203 |
if len(references)==1:
|
204 |
num_iterations = 1
|
205 |
|