Constructor and Description |
---|
TrecJudge(java.io.BufferedReader reader)
Constructor from a reader.
|
Modifier and Type | Method and Description |
---|---|
boolean |
isRelevant(java.lang.String docName,
QualityQuery query)
Judge if document
docName is relevant for the given quality query. |
int |
maxRecall(QualityQuery query)
Return the maximal recall for the input quality query.
|
boolean |
validateData(QualityQuery[] qq,
java.io.PrintWriter logger)
Validate that queries and this Judge match each other.
|
public TrecJudge(java.io.BufferedReader reader) throws java.io.IOException
Expected input format:
qnum 0 doc-name is-relevantTwo sample lines:
19 0 doc303 1 19 0 doc7295 0
reader
- where judgments are read from.java.io.IOException
- If there is a low-level I/O error.public boolean isRelevant(java.lang.String docName, QualityQuery query)
Judge
docName
is relevant for the given quality query.isRelevant
in interface Judge
docName
- name of doc tested for relevancy.query
- tested quality query.public boolean validateData(QualityQuery[] qq, java.io.PrintWriter logger)
Judge
validateData
in interface Judge
qq
- quality queries to be validated.logger
- if not null, validation issues are logged.public int maxRecall(QualityQuery query)
Judge
Copyright © 2000–2019 The Apache Software Foundation. All rights reserved.