red1bluelost
commited on
Commit
•
c503e24
1
Parent(s):
85ee43a
Adds count for progress bar.
Browse files
evaluate_genericify_cpp.py
CHANGED
@@ -137,6 +137,8 @@ class EvaluateGenericifyCpp(evaluate.Metric):
|
|
137 |
"This metric is currently not supported on Windows."
|
138 |
)
|
139 |
|
|
|
|
|
140 |
with concurrent.futures.ThreadPoolExecutor(
|
141 |
max_workers=num_workers
|
142 |
) as executor:
|
@@ -160,7 +162,9 @@ class EvaluateGenericifyCpp(evaluate.Metric):
|
|
160 |
completion_id[task_id] += 1
|
161 |
|
162 |
for future in tqdm(
|
163 |
-
concurrent.futures.as_completed(futures),
|
|
|
|
|
164 |
):
|
165 |
result = future.result()
|
166 |
results[result["task_id"]].append(
|
|
|
137 |
"This metric is currently not supported on Windows."
|
138 |
)
|
139 |
|
140 |
+
total_predictions = sum(map(len, predictions))
|
141 |
+
|
142 |
with concurrent.futures.ThreadPoolExecutor(
|
143 |
max_workers=num_workers
|
144 |
) as executor:
|
|
|
162 |
completion_id[task_id] += 1
|
163 |
|
164 |
for future in tqdm(
|
165 |
+
concurrent.futures.as_completed(futures),
|
166 |
+
desc="Evaluating",
|
167 |
+
total=total_predictions,
|
168 |
):
|
169 |
result = future.result()
|
170 |
results[result["task_id"]].append(
|