Skip to content
This repository has been archived by the owner on Jul 19, 2022. It is now read-only.

Commit

Permalink
Add progress bar to evaluation
Browse files Browse the repository at this point in the history
  • Loading branch information
SnowyCoder committed Feb 16, 2022
1 parent 5bff121 commit 12ebcd6
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion gamecompendium/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
import os
from typing import Dict, Optional, Iterable, MutableSequence

from tqdm import tqdm

from whoosh_bugs import run as dont_delete_me_im_fixing_whoosh_bugs
from whoosh.filedb.filestore import Storage, FileStorage
from whoosh.index import Index
Expand Down Expand Up @@ -114,7 +116,7 @@ def run_query(self, query_txt: str, k: int = 5) -> list[aggregator.AggregateHit]

def evaluate(self, suite: BenchmarkSuite) -> list[BenchmarkResult]:
res = []
for bench in suite.benchmarks:
for bench in tqdm(suite.benchmarks):
topk = self.run_query(bench.query, 10)
data = {(s.source, s.id): s.relevance for s in bench.scores}
entries = []
Expand Down

0 comments on commit 12ebcd6

Please sign in to comment.