23 #include "fst/fstlib.h"    41 int main(
int argc, 
char *argv[]) {
    43     using namespace kaldi;
    48         "Copy tables/archives of FSTs, indexed by a string (e.g. utterance-id)\n"    50         "Usage: fstcopy <fst-rspecifier> <fst-wspecifier>\n";
    61     std::string fst_rspecifier = po.
GetArg(1),
    62         fst_wspecifier = po.
GetArg(2);
    68     for (; !fst_reader.
Done(); fst_reader.
Next(), n_done++)
    71     KALDI_LOG << 
"Copied " << n_done << 
" FSTs.";
    72     return (n_done != 0 ? 0 : 1);
    73   } 
catch(
const std::exception &e) {
    74     std::cerr << e.what();
 This code computes Goodness of Pronunciation (GOP) and extracts phone-level pronunciation feature for...
 
For an extended explanation of the framework of which grammar-fsts are a part, please see Support for...
 
void PrintUsage(bool print_command_line=false)
Prints the usage documentation [provided in the constructor]. 
 
A templated class for writing objects to an archive or script file; see The Table concept...
 
void Write(const std::string &key, const T &value) const
 
The class ParseOptions is for parsing command-line options; see Parsing command-line options for more...
 
int main(int argc, char *argv[])
 
A templated class for reading objects sequentially from an archive or script file; see The Table conc...
 
int Read(int argc, const char *const *argv)
Parses the command line options and fills the ParseOptions-registered variables. 
 
std::string GetArg(int param) const
Returns one of the positional parameters; 1-based indexing for argc/argv compatibility. 
 
int NumArgs() const
Number of positional parameters (c.f. argc-1).