 
 
	 
In file ../include/EST_SCFG.h:
| class EST_SCFG_traintest | 
A class used to train (and test) SCFGs is an extention of EST_SCFG.
| ![[more]](icon1.gif) void | test_corpus () Test the current grammar against the current corpus print summary. | 
| ![[more]](icon1.gif) void | test_crossbrackets () Test the current grammar against the current corpus. | 
| ![[more]](icon1.gif) void | load_corpus (const EST_String &filename) Load a corpus from the given file. | 
| ![[more]](icon1.gif) void | train_inout (int passes, int startpass, int checkpoint, int spread, const EST_String &outfile) Train a grammar using the loaded corpus. | 
Constructor and initialisation functions
![[more]](icon1.gif) EST_SCFG(LISP rules)
 EST_SCFG(LISP rules)
utility functions
![[more]](icon1.gif) void set_rules(LISP rules)
void set_rules(LISP rules)
![[more]](icon1.gif) LISP get_rules()
LISP get_rules()
![[more]](icon1.gif) SCFGRuleList rules
SCFGRuleList rules
![[more]](icon1.gif) void find_terms_nonterms(EST_StrList &nt, EST_StrList &t, LISP rules)
void find_terms_nonterms(EST_StrList &nt, EST_StrList &t, LISP rules)
![[more]](icon1.gif) EST_String nonterminal(int p) const
EST_String nonterminal(int p) const 
![[more]](icon1.gif) EST_String terminal(int m) const
EST_String terminal(int m) const 
![[more]](icon1.gif) int nonterminal(const EST_String &p) const
int nonterminal(const EST_String &p) const 
![[more]](icon1.gif) int terminal(const EST_String &m) const
int terminal(const EST_String &m) const 
![[more]](icon1.gif) int num_nonterminals() const
int num_nonterminals() const 
![[more]](icon1.gif) int num_terminals() const
int num_terminals() const 
![[more]](icon1.gif) double prob_B(int p, int q, int r) const
double prob_B(int p, int q, int r) const 
![[more]](icon1.gif) double prob_U(int p, int m) const
double prob_U(int p, int m) const 
![[more]](icon1.gif) void set_rule_prob_cache()
void set_rule_prob_cache()
file i/o functions
![[more]](icon1.gif) EST_read_status load(const EST_String &filename)
EST_read_status load(const EST_String &filename)
![[more]](icon1.gif) EST_write_status save(const EST_String &filename)
EST_write_status save(const EST_String &filename)
A class used to train (and test) SCFGs is an extention of EST_SCFG.This offers an implementation of Pereira and Schabes ``Inside-Outside reestimation from partially bracket corpora.'' ACL 1992.
A SCFG maybe trained from a corpus (optionally) containing brackets over a series of passes reestimating the grammar probabilities after each pass. This basically extends the EST_SCFG class adding support for a bracket corpus and various indexes for efficient use of the grammar.
 void test_corpus()
void test_corpus()
Cross entropy measure only is given.
 void test_crossbrackets()
void test_crossbrackets()
Sumamry includes percentage of cross bracketing accuracy and percentage of fully correct parses.
 void load_corpus(const EST_String &filename)
void load_corpus(const EST_String &filename)
Each setence in the corpus should be contained in parentheses. Additional paranethesis may be used to denote phrasing within a sentence. The corpus is read using the LISP reader so LISP conventions shold apply, notable single quotes should appear within double quotes.
 void train_inout(int passes, int startpass, int checkpoint, int spread, const EST_String &outfile)
void train_inout(int passes, int startpass, int checkpoint, int spread, const EST_String &outfile)
Alphabetic index HTML hierarchy of classes or Java
 
This page is part of the 
Edinburgh Speech Tools Library documentation
Copyright  University of Edinburgh 1997
Contact:  
         speech_tools@cstr.ed.ac.uk