Python bindings for the trec_eval information retrieval evaluation tool, providing standard IR metrics like MAP, NDCG, P@k, etc. Supports Python 3+. Current version 0.5 is the latest stable release. Updates are infrequent.
pip install pytrec-evalVerified import paths — ran on the pinned version, not inferred.
Evaluate a run against qrels using MAP and NDCG.
Install trec_eval via system package manager or build from source, and ensure trec_eval is in PATH.
Use str(query_id) and str(doc_id) when building qrel and run dictionaries.
Upgrade to Python 3.
No dependency data recorded yet.