Classes | Macros | Typedefs | Functions
ms_mgau.h File Reference

(Sphinx 3.0 specific) A module that wraps up the code of gauden and senone because they are closely related. More...

#include <prim_type.h>
#include <cmd_ln.h>
#include <logmath.h>
#include <s3types.h>
#include <ms_gauden.h>
#include <ms_senone.h>
#include <interp.h>
#include <feat.h>
#include <mdef.h>
#include <ascr.h>

Go to the source code of this file.

Classes

struct  mgau2sen_s
struct  ms_mgau_model_t

Macros

#define ms_mgau_gauden(msg)   (msg->g)
#define ms_mgau_senone(msg)   (msg->s)
#define ms_mgau_interp(msg)   (msg->i)
#define ms_mgau_mgau2sen(msg)   (msg->mgau2sen)
#define ms_mgau_topn(msg)   (msg->topn)

Typedefs

typedef struct mgau2sen_s mgau2sen_t

Functions

ms_mgau_model_tms_mgau_init (const char *meanfile, const char *varfile, float64 varfloor, const char *mixwfile, float64 mixwfloor, int32 precomp, const char *senmgau, const char *lambdafile, int32 topn, logmath_t *logmath)
void ms_mgau_free (ms_mgau_model_t *g)
S3DECODER_EXPORT int32 ms_cont_mgau_frame_eval (ascr_t *ascr, ms_mgau_model_t *msg, mdef_t *mdef, float32 **feat)
S3DECODER_EXPORT int32 model_set_mllr (ms_mgau_model_t *msg, const char *mllrfile, const char *cb2mllrfile, feat_t *fcb, mdef_t *mdef, cmd_ln_t *config)

Detailed Description

(Sphinx 3.0 specific) A module that wraps up the code of gauden and senone because they are closely related.

At the time at Sphinx 3.1 to 3.2, Ravi has decided to rewrite only single-stream part of the code into cont_mgau.[ch]. This marks the beginning of historical problem of having two sets of Gaussian distribution computation routine, one for single-stream and one of multi-stream.

In Sphinx 3.5, when we figure out that it is possible to allow both 3.0 family of tools and 3.x family of tools to coexist. This becomes one problem we found that very hard to reconcile. That is why we currently allow two versions of the code in the code base. This is likely to change in the future.


Macro Definition Documentation

#define ms_mgau_gauden (   msg)    (msg->g)
#define ms_mgau_interp (   msg)    (msg->i)
#define ms_mgau_mgau2sen (   msg)    (msg->mgau2sen)
#define ms_mgau_senone (   msg)    (msg->s)
#define ms_mgau_topn (   msg)    (msg->topn)

Typedef Documentation

typedef struct mgau2sen_s mgau2sen_t

Function Documentation

S3DECODER_EXPORT int32 model_set_mllr ( ms_mgau_model_t msg,
const char *  mllrfile,
const char *  cb2mllrfile,
feat_t *  fcb,
mdef_t mdef,
cmd_ln_t *  config 
)
Parameters:
msgThe model-stream Gaussian distribution model
mllrfileThe MLLR file name
cb2mllrfileThe codebook to MLLR file name
fcbFCB object
mdefA model definition

Referenced by main().

S3DECODER_EXPORT int32 ms_cont_mgau_frame_eval ( ascr_t ascr,
ms_mgau_model_t msg,
mdef_t mdef,
float32 **  feat 
)
Parameters:
ascrIn: An ascr object
msgIn: A multi-stream mgau mode
mdefIn: A mdef
void ms_mgau_free ( ms_mgau_model_t g)

Free memory allocated by ms_mgau_init

Parameters:
gIn: A set of models to free
ms_mgau_model_t* ms_mgau_init ( const char *  meanfile,
const char *  varfile,
float64  varfloor,
const char *  mixwfile,
float64  mixwfloor,
int32  precomp,
const char *  senmgau,
const char *  lambdafile,
int32  topn,
logmath_t *  logmath 
)
Parameters:
meanfileIn: File containing means of mixture gaussians
varfileIn: File containing variances of mixture gaussians
varfloorIn: Floor value applied to variances; e.g., 0.0001
mixwfileIn: File containing mixture weights
mixwfloorIn: Floor value for mixture weights; e.g., 0.0000001
senmgauIn: type of the gaussians distribution, .cont. or .semi. FIX me! This is confusing!
lambdafileIn: Interplation file
topnIn: Top-n gaussian will be computed