#include <rule_extractor.h>
Public Member Functions | |
RuleExtractor (Vocabulary &) | |
void | Extract (const PcfgTree &, RuleCollection &) const |
Definition at line 36 of file rule_extractor.h.
Moses::PCFG::RuleExtractor::RuleExtractor | ( | Vocabulary & | non_term_vocab | ) |
Definition at line 27 of file rule_extractor.cc.
void Moses::PCFG::RuleExtractor::Extract | ( | const PcfgTree & | tree, | |
RuleCollection & | rc | |||
) | const |
Definition at line 31 of file rule_extractor.cc.
References Moses::PCFG::RuleCollection::Add(), Moses::PCFG::SyntaxTreeBase< T, DerivedType >::children(), Moses::PCFG::NumberedSet< T, I >::Insert(), Moses::PCFG::SyntaxTreeBase< T, DerivedType >::IsLeaf(), Moses::PCFG::SyntaxTreeBase< T, DerivedType >::IsPreterminal(), and Moses::PCFG::SyntaxTreeBase< T, DerivedType >::label().
Referenced by Moses::PCFG::PcfgExtract::Main().