|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object de.fzi.kadmos.evaluator.impl.PrecRecEvaluatorImpl
public class PrecRecEvaluatorImpl
Implementation of a simple precision / recall evaluator.
An instance of this evaluator can be obtained via the
getInstance()
method, which requires a reference
alignment. Each instance is immutable wrt. to this reference
alignment, however, using the same instance for computing
precision and recall measures is not guaranteed to produce the
same results, since the reference alignment can change without
the evaluator being notified.
Method Summary | |
---|---|
double |
getFMeasure(Alignment alignment)
Computes and returns the F-Measure of an alignment. |
static PrecRecEvaluatorImpl |
getInstance(Alignment refAlign)
Gets a (new) instance of this evaluator. |
double |
getPrecision(Alignment alignment)
Computes and returns the precision of an alignment. |
double |
getRecall(Alignment alignment)
Computes and returns the recall of an alignment. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static PrecRecEvaluatorImpl getInstance(Alignment refAlign)
Alignment
instance there can only be one evaluator instance.
refAlign
- The reference Alignment
used for evaluating.
public double getFMeasure(Alignment alignment) throws IncompatibleAlignmentsException
getFMeasure
in interface PrecRecEvaluator
alignment
- Alignment, whose F-Measure is to be determined.
IncompatibleAlignmentsException
- if the alignment refers to different ontologies
than the reference alignment.public double getPrecision(Alignment alignment) throws IncompatibleAlignmentsException
getPrecision
in interface PrecRecEvaluator
alignment
- Alignment, whose precision is to be determined.
IncompatibleAlignmentsException
- if the alignment refers to different ontologies
than the reference alignment.public double getRecall(Alignment alignment) throws IncompatibleAlignmentsException
getRecall
in interface PrecRecEvaluator
alignment
- Alignment, whose recall is to be determined.
IncompatibleAlignmentsException
- if the alignment refers to different ontologies
than the reference alignment.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |