Upload metric.py with huggingface_hub
Browse files
metric.py
CHANGED
@@ -18,6 +18,7 @@ from .hf_utils import __file__ as _
|
|
18 |
from .instructions import __file__ as _
|
19 |
from .load import __file__ as _
|
20 |
from .loaders import __file__ as _
|
|
|
21 |
from .metrics import __file__ as _
|
22 |
from .normalizers import __file__ as _
|
23 |
from .operator import (MultiStreamOperator, SequentialOperator,
|
@@ -32,7 +33,6 @@ from .random_utils import __file__ as _
|
|
32 |
from .recipe import __file__ as _
|
33 |
from .register import __file__ as _
|
34 |
from .register import _reset_env_local_catalogs, register_all_artifacts
|
35 |
-
from .renderers import __file__ as _
|
36 |
from .schema import UNITXT_DATASET_SCHEMA
|
37 |
from .schema import __file__ as _
|
38 |
from .split_utils import __file__ as _
|
@@ -53,7 +53,7 @@ class MultiStreamScoreMean(MultiStreamOperator):
|
|
53 |
def aggegate_results(self, multi_stream: MultiStream):
|
54 |
scores = []
|
55 |
for stream in multi_stream.values():
|
56 |
-
instance = stream.
|
57 |
scores.append(instance["score"]["global"]["score"])
|
58 |
|
59 |
from statistics import mean
|
|
|
18 |
from .instructions import __file__ as _
|
19 |
from .load import __file__ as _
|
20 |
from .loaders import __file__ as _
|
21 |
+
from .logging_utils import __file__ as _
|
22 |
from .metrics import __file__ as _
|
23 |
from .normalizers import __file__ as _
|
24 |
from .operator import (MultiStreamOperator, SequentialOperator,
|
|
|
33 |
from .recipe import __file__ as _
|
34 |
from .register import __file__ as _
|
35 |
from .register import _reset_env_local_catalogs, register_all_artifacts
|
|
|
36 |
from .schema import UNITXT_DATASET_SCHEMA
|
37 |
from .schema import __file__ as _
|
38 |
from .split_utils import __file__ as _
|
|
|
53 |
def aggegate_results(self, multi_stream: MultiStream):
|
54 |
scores = []
|
55 |
for stream in multi_stream.values():
|
56 |
+
instance = stream.peek()
|
57 |
scores.append(instance["score"]["global"]["score"])
|
58 |
|
59 |
from statistics import mean
|