#include <sent/stddefs.h>
#include <sent/vocabulary.h>
#include <sent/htk_hmm.h>
Go to the source code of this file.
Defines | |
| #define | PHONEMELEN_STEP 30 |
| Memory allocation step for phoneme sequence. | |
Functions | |
| static void | add_to_error (WORD_INFO *winfo, char *name) |
| Add a triphone name to the missing error list in WORD_INFO. | |
| static void | callback_list_error (void *x) |
| Traverse callback function to output a error phone. | |
| static void | list_error (WORD_INFO *winfo) |
| Output all error phones appeared while readin a word dictionary. | |
| boolean | voca_load_word_line (char *buf, WORD_INFO *winfo, HTK_HMM_INFO *hmminfo, char *headphone, char *tailphone, char *contextphone) |
| Load a line from buffer and set parameters to the dictionary. | |
| boolean | voca_load_wordlist (FILE *fp, WORD_INFO *winfo, HTK_HMM_INFO *hmminfo, char *headphone, char *tailphone, char *contextphone) |
| Top function to read word list via text. | |
| boolean | voca_load_wordlist_fp (FILE *fp, WORD_INFO *winfo, HTK_HMM_INFO *hmminfo, char *headphone, char *tailphone, char *contextphone) |
| Top function to read word list via file pointer. | |
| boolean | voca_load_wordlist_line (char *buf, WORD_ID *vnum_p, int linenum, WORD_INFO *winfo, HTK_HMM_INFO *hmminfo, boolean do_conv, boolean *ok_flag, char *headphone, char *tailphone, char *contextphone) |
| Sub function to Add a dictionary entry line to the word dictionary. | |
Variables | |
| static char | buf [MAXLINELEN] |
| Local work area for input text processing. | |
| static char | bufbak [MAXLINELEN] |
| Local work area for debug message. | |
Definition in file voca_load_wordlist.c.
| static void add_to_error | ( | WORD_INFO * | winfo, | |
| char * | name | |||
| ) | [static] |
Add a triphone name to the missing error list in WORD_INFO.
| winfo | [i/o] word dictionary to add the error phone to error list | |
| name | [in] phone name to be added |
Definition at line 56 of file voca_load_wordlist.c.
| static void callback_list_error | ( | void * | x | ) | [static] |
Traverse callback function to output a error phone.
| x | [in] error phone string of the node |
Definition at line 79 of file voca_load_wordlist.c.
| static void list_error | ( | WORD_INFO * | winfo | ) | [static] |
Output all error phones appeared while readin a word dictionary.
| winfo | [in] word dictionary data |
Definition at line 91 of file voca_load_wordlist.c.
| boolean voca_load_word_line | ( | char * | buf, | |
| WORD_INFO * | winfo, | |||
| HTK_HMM_INFO * | hmminfo, | |||
| char * | headphone, | |||
| char * | tailphone, | |||
| char * | contextphone | |||
| ) |
Load a line from buffer and set parameters to the dictionary.
| buf | [in] input buffer containing a word entry | |
| winfo | [i/o] word dictionary to append the entry | |
| hmminfo | [in] phoneme HMM definition | |
| headphone | [in] word head silence model name | |
| tailphone | [in] word tail silence model name | |
| contextphone | [in] silence context name to be used at head and tail |
Definition at line 114 of file voca_load_wordlist.c.
Referenced by voca_load_wordlist(), and voca_load_wordlist_fp().
| boolean voca_load_wordlist | ( | FILE * | fp, | |
| WORD_INFO * | winfo, | |||
| HTK_HMM_INFO * | hmminfo, | |||
| char * | headphone, | |||
| char * | tailphone, | |||
| char * | contextphone | |||
| ) |
Top function to read word list via text.
| fp | [in] file pointer | |
| winfo | [out] pointer to word dictionary to store the read data. | |
| hmminfo | [in] HTK HMM definition data. if NULL, phonemes are ignored. | |
| headphone | [in] word head silence model name | |
| tailphone | [in] word tail silence model name | |
| contextphone | [in] silence context name to be used at head and tail |
Definition at line 142 of file voca_load_wordlist.c.
Referenced by init_wordlist().
| boolean voca_load_wordlist_fp | ( | FILE * | fp, | |
| WORD_INFO * | winfo, | |||
| HTK_HMM_INFO * | hmminfo, | |||
| char * | headphone, | |||
| char * | tailphone, | |||
| char * | contextphone | |||
| ) |
Top function to read word list via file pointer.
| fp | [in] file pointer | |
| winfo | [out] pointer to word dictionary to store the read data. | |
| hmminfo | [in] HTK HMM definition data. if NULL, phonemes are ignored. | |
| headphone | [in] word head silence model name | |
| tailphone | [in] word tail silence model name | |
| contextphone | [in] silence context name to be used at head and tail |
Definition at line 169 of file voca_load_wordlist.c.
| boolean voca_load_wordlist_line | ( | char * | buf, | |
| WORD_ID * | vnum_p, | |||
| int | linenum, | |||
| WORD_INFO * | winfo, | |||
| HTK_HMM_INFO * | hmminfo, | |||
| boolean | do_conv, | |||
| boolean * | ok_flag, | |||
| char * | headphone, | |||
| char * | tailphone, | |||
| char * | contextphone | |||
| ) |
Sub function to Add a dictionary entry line to the word dictionary.
| buf | [i/o] buffer to hold the input string, will be modified in this function | |
| vnum_p | [in] current number of words in winfo | |
| linenum | [in] current line number of the input | |
| winfo | [out] pointer to word dictionary to append the data. | |
| hmminfo | [in] HTK HMM definition data. if NULL, phonemes are ignored. | |
| do_conv | [in] TRUE if performing triphone conversion | |
| ok_flag | [out] will be set to FALSE if an error occured for this input. | |
| headphone | [in] word head silence model name | |
| tailphone | [in] word tail silence model name | |
| contextphone | [in] silence context name to be used at head and tail |
Definition at line 199 of file voca_load_wordlist.c.
Referenced by voca_load_word_line().
1.5.1