fillpen.h File Reference

Filler penalties, penalties for words that do not show up in the main LM. More...

#include <logmath.h>
#include <s3types.h>
#include "dict.h"

Go to the source code of this file.

Classes

struct  fillpen_t

Functions

S3DECODER_EXPORT fillpen_tfillpen_init (dict_t *dict, const char *file, float64 silprob, float64 fillprob, float64 lw, float64 wip, logmath_t *logmath)
int32 fillpen (fillpen_t *f, s3wid_t w)
void fillpen_report (fillpen_t *f)
S3DECODER_EXPORT void fillpen_free (fillpen_t *f)

Detailed Description

Filler penalties, penalties for words that do not show up in the main LM.


Function Documentation

int32 fillpen ( fillpen_t f,
s3wid_t  w 
)

Return the filler word probability for the given dictionary word-ID.

Parameters:
f In: Filler word probabilities structure
w In: Dictionary word-ID of filler word

Referenced by word_trans().

S3DECODER_EXPORT void fillpen_free ( fillpen_t f  ) 
Parameters:
f A filler penalty structure
S3DECODER_EXPORT fillpen_t* fillpen_init ( dict_t dict,
const char *  file,
float64  silprob,
float64  fillprob,
float64  lw,
float64  wip,
logmath_t *  logmath 
)

Initialize filler probabilities (penalties, whatever) module and return a pointer to the structure created. Filler word probabilities are simple unigram probabilities. Here is an example of such a file (one entry per line; a word and a probability): <sil> 0.10792 <uh> 0.00866 <um> 0.00147 If the first character in a line is a '#', the line is treated as a comment and ignored. If no filler probabilities file is provided, the silence word gets silprob, and all other filler words get fillprob. As with the trigram LM, the resulting log-probabilities are multiplied by a language weight and finally a word insertion penalty is tacked on.

Parameters:
dict In: Dictionary containing filler words
file In: Filler word probabilities file, if any
silprob In: Default probability for silence word
fillprob In: Default probability for non-silence filler words
lw In: Language weight (see lm.h)
wip In: Word insertion penalty (see lm.h)
void fillpen_report ( fillpen_t f  ) 

Report the fillpen_t structure

Parameters:
f In: Filler word probabilities structure

Generated on 7 Mar 2010 by  doxygen 1.6.1