#include <sent/stddefs.h>
#include <sent/htk_hmm.h>
#include <sent/ptree.h>
Include dependency graph for hmm_lookup.c:
Go to the source code of this file.
Functions | |
HTK_HMM_Data * | htk_hmmdata_lookup_physical (HTK_HMM_INFO *hmminfo, char *keyname) |
HMM_Logical * | htk_hmmdata_lookup_logical (HTK_HMM_INFO *hmminfo, char *keyname) |
static void | hmm_count_logical_num (HTK_HMM_INFO *hmminfo) |
void | hmm_add_physical_to_logical (HTK_HMM_INFO *hmminfo) |
Add all physical HMM to logical HMM. | |
static void | hmm_add_pseudo_phones_sub (HTK_HMM_INFO *hmminfo, char *name) |
Add a pseudo monophone and pseudo biphone to logical HMM. | |
void | hmm_add_pseudo_phones (HTK_HMM_INFO *hmminfo) |
int | hmm_logical_state_num (HMM_Logical *lg) |
HTK_HMM_Trans * | hmm_logical_trans (HMM_Logical *lg) |
Variables | |
static int | add_count |
Number of pseudo phones added to logical HMM list. |
The result is pointer to the corresponding logical HMM (HMM_Logical). The logical HMM holds either pointer to an actual HMM data defined in HTK HMM definition, or pointer to a pseudo HMM set when the query name is biphone or monophone and they are not defined in either HTK HMM definition or HMMList mapping file.
Adding physical HMM defined in HTK HMM definitions and pseudo phones to the logical HMM mapping function is also done here.
Definition in file hmm_lookup.c.
HTK_HMM_Data* htk_hmmdata_lookup_physical | ( | HTK_HMM_INFO * | hmminfo, | |
char * | keyname | |||
) |
Look up physical (defined in HTK HMM definition file) HMM by its name.
hmminfo | [in] HMM definition data | |
keyname | [in] key string of HMM name |
Definition at line 62 of file hmm_lookup.c.
Referenced by rdhmmlist().
HMM_Logical* htk_hmmdata_lookup_logical | ( | HTK_HMM_INFO * | hmminfo, | |
char * | keyname | |||
) |
Look up logical HMM by its name.
hmminfo | [in] HMM definition data | |
keyname | [in] key string of HMM name |
Definition at line 82 of file hmm_lookup.c.
Referenced by get_left_context_HMM(), get_right_context_HMM(), htk_hmm_set_pause_model(), print_hmminfo(), triphone_callback_normal(), triphone_callback_right(), voca_load_htkdict_line(), and voca_mono2tri().
static void hmm_count_logical_num | ( | HTK_HMM_INFO * | hmminfo | ) | [static] |
Count the number of logical HMM and store it.
hmminfo | [in] HMM definition data. |
Definition at line 99 of file hmm_lookup.c.
Referenced by hmm_add_physical_to_logical(), and hmm_add_pseudo_phones().
void hmm_add_physical_to_logical | ( | HTK_HMM_INFO * | hmminfo | ) |
Add all physical HMM to logical HMM.
This function should be called only if HMMList is not specified. Julius assumes all the triphones should be explicitly mapped using HMMList file.
hmminfo | [in] HMM definition data. |
Definition at line 119 of file hmm_lookup.c.
Referenced by init_hmminfo().
static void hmm_add_pseudo_phones_sub | ( | HTK_HMM_INFO * | hmminfo, | |
char * | name | |||
) | [static] |
Add a pseudo monophone and pseudo biphone to logical HMM.
Logical HMM specified in HMMlist precedes pseudo HMM: if some monophones or biphones are already defined in HMMList, pseudo HMM will not be added.
hmminfo | [in] HMM definition data. | |
name | [in] name of the pseudo phone to add. |
Definition at line 169 of file hmm_lookup.c.
Referenced by hmm_add_pseudo_phones().
void hmm_add_pseudo_phones | ( | HTK_HMM_INFO * | hmminfo | ) |
Update logical HMM list by adding all the possible pseudo monophone and biphone to the list.
hmminfo | [in] HMM definition data. |
Definition at line 209 of file hmm_lookup.c.
Referenced by initialize_HMM().
int hmm_logical_state_num | ( | HMM_Logical * | lg | ) |
Generic function to get the number of states in a logical HMM.
lg | [in] logical HMM |
Definition at line 245 of file hmm_lookup.c.
Referenced by do_align(), make_phseq(), new_make_word_hmm_with_lm(), print_voca_info(), scan_word(), set_maxwn(), totalstatelen(), wchmm_add_word(), wchmm_duplicate_leafnode(), wchmm_duplicate_state(), and wchmm_link_subword().
HTK_HMM_Trans* hmm_logical_trans | ( | HMM_Logical * | lg | ) |
Generic function to get transition matrix of a logical HMM.
lg | [in] logical HMM |
Definition at line 261 of file hmm_lookup.c.
Referenced by wchmm_calc_wordend_arc(), wchmm_duplicate_leafnode(), and wchmm_link_subword().