@@ -91,6 +91,8 @@ public class EvaluateTreebank {
91
91
AbstractEval .ScoreEval factLL = null ;
92
92
AbstractEval kGoodLB = null ;
93
93
94
+ List <Double > factLBHistory = null ;
95
+
94
96
BestOfTopKEval pcfgTopK = null ;
95
97
private final List <BestOfTopKEval > topKEvals = new ArrayList <>();
96
98
@@ -182,6 +184,7 @@ public EvaluateTreebank(Options op, Lexicon lex, ParserQueryFactory pqFactory, F
182
184
}
183
185
if (Boolean .parseBoolean (op .testOptions .evals .getProperty ("factLB" ))) {
184
186
factLB = new Evalb ("factor LP/LR" , runningAverages );
187
+ factLBHistory = new ArrayList <>();
185
188
}
186
189
if (op .testOptions .evals .getProperty ("factChildSpecific" ) != null ) {
187
190
String filter = op .testOptions .evals .getProperty ("factChildSpecific" );
@@ -268,6 +271,10 @@ public boolean hasPCFGTopKF1() {
268
271
return pcfgTopK != null ;
269
272
}
270
273
274
+ public List <Double > getF1History () {
275
+ return Collections .unmodifiableList (factLBHistory );
276
+ }
277
+
271
278
/**
272
279
* Remove tree scores, so they don't print.
273
280
* <br>
@@ -524,6 +531,7 @@ else if(pwFileOut != null) {
524
531
//Factored parser (1best) eval
525
532
if (factLB != null ) {
526
533
factLB .evaluate (treeFact , transGoldTree , pwErr );
534
+ factLBHistory .add (factLB .getLastF1 ());
527
535
}
528
536
if (factChildSpecific != null ) {
529
537
factChildSpecific .evaluate (treeFact , transGoldTree , pwErr );
0 commit comments