25 std::string str=
"default_for_str";
33 so.
Register(
"num", &num,
"Description of num");
34 so.
Register(
"unum", &unum,
"Description of unum");
35 so.
Register(
"str", &str,
"Description of str");
36 so.
Register(
"flag", &flag,
"Description of flag");
37 so.
Register(
"realnum", &realnum,
"Description of realnum");
41 so.
SetOption(
"unum", static_cast<uint32>(43));
43 rval = so.
SetOption(
"str", (std::string)
"foo");
63 rval = so.
SetOption(
"realnum", static_cast<float>(0.2));
66 rval = so.
SetOption(
"realnum", static_cast<double>(0.3));
83 using namespace kaldi;
This code computes Goodness of Pronunciation (GOP) and extracts phone-level pronunciation feature for...
The class SimpleOptions is an implementation of OptionsItf that allows setting and getting option val...
bool GetOptionType(const std::string &key, OptionType *type)
void Register(const std::string &name, bool *ptr, const std::string &doc)
void UnitTestSimpleOptions()
#define KALDI_ASSERT(cond)
bool SetOption(const std::string &key, const bool &value)