23 #ifndef KALDI_FEAT_FEATURE_FUNCTIONS_H_ 24 #define KALDI_FEAT_FEATURE_FUNCTIONS_H_ 55 order(order), window(window) { }
57 opts->
Register(
"delta-order", &order,
"Order of delta computation");
58 opts->
Register(
"delta-window", &window,
59 "Parameter controlling window for delta computation (actual window" 60 " size for each delta order is 1 + 2*delta-window-size)");
91 window(1), num_blocks(7), block_shift(3) { }
93 opts->
Register(
"delta-window", &window,
"Size of delta advance and delay.");
94 opts->
Register(
"num-blocks", &num_blocks,
"Number of delta blocks in advance" 95 " of each frame to be concatenated");
96 opts->
Register(
"block-shift", &block_shift,
"Distance between each block");
169 normalize_variance(false),
173 opts->
Register(
"cmn-window", &cmn_window,
"Window in frames for running " 174 "average CMN computation");
175 opts->
Register(
"min-cmn-window", &min_window,
"Minimum CMN window " 176 "used at start of decoding (adds latency only at start). " 177 "Only applicable if center == false, ignored if center==true");
178 opts->
Register(
"max-warnings", &max_warnings,
"Maximum warnings to report " 179 "per utterance. 0 to disable, -1 to show all.");
180 opts->
Register(
"norm-vars", &normalize_variance,
"If true, normalize " 182 opts->
Register(
"center", ¢er,
"If true, use a window centered on the " 183 "current frame (to the extent possible, modulo end effects). " 184 "If false, window is to the left.");
204 #endif // KALDI_FEAT_FEATURE_FUNCTIONS_H_ This code computes Goodness of Pronunciation (GOP) and extracts phone-level pronunciation feature for...
Base class which provides matrix operations not involving resizing or allocation. ...
void ReverseFrames(const MatrixBase< BaseFloat > &input_features, Matrix< BaseFloat > *output_features)
Vector< BaseFloat > scales_
virtual void Register(const std::string &name, bool *ptr, const std::string &doc)=0
ShiftedDeltaFeaturesOptions opts_
void Register(OptionsItf *opts)
DeltaFeaturesOptions opts_
DeltaFeaturesOptions(int32 order=2, int32 window=2)
void ComputeShiftedDeltas(const ShiftedDeltaFeaturesOptions &delta_opts, const MatrixBase< BaseFloat > &input_features, Matrix< BaseFloat > *output_features)
ShiftedDeltaFeaturesOptions()
SlidingWindowCmnOptions()
void Register(OptionsItf *opts)
void InitIdftBases(int32 n_bases, int32 dimension, Matrix< BaseFloat > *mat_out)
void ComputePowerSpectrum(VectorBase< BaseFloat > *waveform)
A class representing a vector.
void ComputeDeltas(const DeltaFeaturesOptions &delta_opts, const MatrixBase< BaseFloat > &input_features, Matrix< BaseFloat > *output_features)
void SpliceFrames(const MatrixBase< BaseFloat > &input_features, int32 left_context, int32 right_context, Matrix< BaseFloat > *output_features)
std::vector< Vector< BaseFloat > > scales_
void Register(OptionsItf *opts)
Provides a vector abstraction class.
Represents a non-allocating general vector which can be defined as a sub-vector of higher-level vecto...
void SlidingWindowCmn(const SlidingWindowCmnOptions &opts, const MatrixBase< BaseFloat > &input, MatrixBase< BaseFloat > *output)
Applies sliding-window cepstral mean and/or variance normalization.