Julius 4.2
|
00001 00027 /* 00028 * Copyright (c) 1991-2011 Kawahara Lab., Kyoto University 00029 * Copyright (c) 2000-2005 Shikano Lab., Nara Institute of Science and Technology 00030 * Copyright (c) 2005-2011 Julius project team, Nagoya Institute of Technology 00031 * All rights reserved 00032 */ 00033 00034 #ifndef __SENT_HMM_NEW2_H__ 00035 #define __SENT_HMM_NEW2_H__ 00036 00037 #include <sent/stddefs.h> 00038 #include <sent/htk_hmm.h> 00039 #include <sent/htk_param.h> 00040 #include <sent/hmm_calc.h> 00041 00043 typedef struct _a_cell { 00044 LOGPROB a; 00045 int arc; 00046 struct _a_cell *next; 00047 } A_CELL; 00048 00050 typedef struct { 00051 A_CELL *ac; 00052 00069 union { 00070 HTK_HMM_State *state; 00071 CD_State_Set *cdset; 00072 } out; 00073 boolean is_pseudo_state; 00074 } HMM_STATE; 00075 00082 typedef struct { 00083 int len; 00084 HMM_STATE *state; 00085 LOGPROB accept_ac_a; 00086 } HMM; 00087 00088 00093 typedef struct _seg_token { 00094 int last_id; 00095 int last_end_frame; 00096 LOGPROB last_end_score; 00097 struct _seg_token *next; 00098 struct _seg_token *list; 00099 } SEGTOKEN; 00100 00101 #ifdef __cplusplus 00102 extern "C" { 00103 #endif 00104 00105 /* mkwhmm.c */ 00106 HMM *new_make_word_hmm(HTK_HMM_INFO *, HMM_Logical **, int, boolean *); 00107 HMM *new_make_word_hmm_with_lm(HTK_HMM_INFO *, HMM_Logical **, int, boolean *, LOGPROB *); 00108 void free_hmm(HMM *); 00109 /* vsegment.c */ 00110 LOGPROB viterbi_segment(HMM *hmm, HTK_Param *param, HMMWork *wrk, boolean multipath, int *endstates, int ulen, int **id_ret, int **seg_ret, LOGPROB **uscore_ret, int *retlen); 00111 00112 /* hmminfo/outprob.c */ 00113 LOGPROB outprob(HMMWork *wrk, int t, HMM_STATE *hmmstate, HTK_Param *param); 00114 /* hmminfo/put_htkdata_info */ 00115 void put_hmm_arc(FILE *fp, HMM *d); 00116 void put_hmm_outprob(FILE *fp, HMM *d); 00117 void put_hmm(FILE *fp, HMM *d); 00118 00119 #ifdef __cplusplus 00120 } 00121 #endif 00122 00123 #endif /* __SENT_HMM_NEW2_H__ */