// new SemanticModel(m).writeJson(Params.MODEL_DIR +
// newSource.getName() + fileExt);
//
// }
ModelEvaluation me;
models.put("1-correct model", correctModel);
if (topHypotheses != null)
for (int k = 0; k < topHypotheses.size(); k++) {
SortableSemanticModel m = topHypotheses.get(k);
me = m.evaluate(correctModel);
String label = "candidate" + k +
m.getSteinerNodes().getScoreDetailsString() +
"cost:" + roundDecimals(m.getCost(), 6) +
// "-distance:" + me.getDistance() +
"-precision:" + me.getPrecision() +
"-recall:" + me.getRecall();
models.put(label, m);
if (k == 0) { // first rank model
System.out.println("number of known models: " + numberOfKnownModels +
", precision: " + me.getPrecision() +
", recall: " + me.getRecall() +
", time: " + elapsedTimeSec);
logger.info("number of known models: " + numberOfKnownModels +
", precision: " + me.getPrecision() +
", recall: " + me.getRecall() +
", time: " + elapsedTimeSec);
// resultFile.println("number of known models \t precision \t recall");
// resultFile.println(numberOfKnownModels + "\t" + me.getPrecision() + "\t" + me.getRecall());
String s = me.getPrecision() + "\t" + me.getRecall() + "\t" + elapsedTimeSec;
if (resultsArray[numberOfKnownModels + 2].length() > 0)
resultsArray[numberOfKnownModels + 2].append(" \t ");
resultsArray[numberOfKnownModels + 2].append(s);
// resultFile.println(me.getPrecision() + "\t" + me.getRecall() + "\t" + elapsedTimeSec);