}
private void reEstmateGrammars(){
for (GrammarFactory grammarFactory : this.p_grammar_factories) {
Grammar bathGrammar = grammarFactory.getGrammarForSentence(null);
accumulatePosteriorCountInGrammar(bathGrammar);
normalizePosteriorCountInGrammar(bathGrammar);
//TODO: this will *correctly* write the regular grammar, instead of the GLUE grammar, but we should avoid this
((MonolingualGrammar) bathGrammar).writeGrammarOnDisk(outGrammarFile, this.symbolTable);
bathGrammar.sortGrammar(this.p_l_feat_functions);
}
}