#include <julius/julius.h>
Go to the source code of this file.
Functions | |
static HMM_Logical ** | make_phseq (WORD_ID *wseq, short num, boolean **has_sp_ret, int *num_ret, int **end_ret, int per_what, RecogProcess *r) |
Make the whole sentence HMM from given word sequence by connecting each phoneme HMM. | |
static void | do_align (WORD_ID *words, short wnum, HTK_Param *param, int per_what, Sentence *s, RecogProcess *r) |
Build sentence HMM, call viterbi_segment() and output result. | |
void | word_align (WORD_ID *words, short wnum, HTK_Param *param, Sentence *s, RecogProcess *r) |
Do forced alignment per word for the given word sequence. | |
void | word_rev_align (WORD_ID *revwords, short wnum, HTK_Param *param, Sentence *s, RecogProcess *r) |
Do forced alignment per word for the given word sequence (reversed order). | |
void | phoneme_align (WORD_ID *words, short num, HTK_Param *param, Sentence *s, RecogProcess *r) |
Do forced alignment per phoneme for the given word sequence. | |
void | phoneme_rev_align (WORD_ID *revwords, short num, HTK_Param *param, Sentence *s, RecogProcess *r) |
Do forced alignment per phoneme for the given word sequence (reversed order). | |
void | state_align (WORD_ID *words, short num, HTK_Param *param, Sentence *s, RecogProcess *r) |
Do forced alignment per HMM state for the given word sequence. | |
void | state_rev_align (WORD_ID *revwords, short num, HTK_Param *param, Sentence *s, RecogProcess *r) |
Do forced alignment per state for the given word sequence (reversed order). |
This file defines functions for performing forced alignment of recognized words. The forced alignment is implimented in Julius/Julian to get the best matching segmentation of recognized word sequence upon input speech. Word-level, phoneme-level and HMM state-level alignment can be obtained.
Julius/Julian performs the forced alignment as a post-processing of recognition process. Recomputation of Viterbi path on the recognized word sequence toward input speech will be done after the recognition to get better alignment.
Definition in file word_align.c.
static HMM_Logical** make_phseq | ( | WORD_ID * | wseq, | |
short | num, | |||
boolean ** | has_sp_ret, | |||
int * | num_ret, | |||
int ** | end_ret, | |||
int | per_what, | |||
RecogProcess * | r | |||
) | [static] |
Make the whole sentence HMM from given word sequence by connecting each phoneme HMM.
wseq | [in] word sequence to align | |
num | [in] number of wseq | |
has_sp_ret | [out] unit information of whether it can be followed by a short-pause | |
num_ret | [out] number of HMM contained in the generated sentence HMM | |
end_ret | [out] sequence of state location as alignment unit | |
per_what | [in] specify the alignment unit (word / phoneme / state) | |
r | [in] recognition process instance |
Definition at line 78 of file word_align.c.
Referenced by do_align().
static void do_align | ( | WORD_ID * | words, | |
short | wnum, | |||
HTK_Param * | param, | |||
int | per_what, | |||
Sentence * | s, | |||
RecogProcess * | r | |||
) | [static] |
Build sentence HMM, call viterbi_segment() and output result.
words | [in] word sequence of the sentence | |
wnum | [in] number of words in words | |
param | [in] input parameter vector | |
per_what | [in] specify the alignment unit (word / phoneme / state) | |
s | [out] Sentence data area to store the alignment result | |
r | [i/o] recognition process instance |
Definition at line 186 of file word_align.c.
Referenced by phoneme_align(), phoneme_rev_align(), state_align(), state_rev_align(), word_align(), and word_rev_align().
void word_align | ( | WORD_ID * | words, | |
short | wnum, | |||
HTK_Param * | param, | |||
Sentence * | s, | |||
RecogProcess * | r | |||
) |
Do forced alignment per word for the given word sequence.
words | [in] word sequence | |
wnum | [in] length of words | |
param | [in] input parameter vectors | |
s | [out] Sentence data area to store the alignment result | |
r | [i/o] recognition process instance |
Definition at line 370 of file word_align.c.
void word_rev_align | ( | WORD_ID * | revwords, | |
short | wnum, | |||
HTK_Param * | param, | |||
Sentence * | s, | |||
RecogProcess * | r | |||
) |
Do forced alignment per word for the given word sequence (reversed order).
revwords | [in] word sequence in reversed direction | |
wnum | [in] length of revwords | |
param | [in] input parameter vectors | |
s | [out] Sentence data area to store the alignment result | |
r | [i/o] recognition process instance |
Definition at line 398 of file word_align.c.
void phoneme_align | ( | WORD_ID * | words, | |
short | num, | |||
HTK_Param * | param, | |||
Sentence * | s, | |||
RecogProcess * | r | |||
) |
Do forced alignment per phoneme for the given word sequence.
words | [in] word sequence | |
num | [in] length of words | |
param | [in] input parameter vectors | |
s | [out] Sentence data area to store the alignment result | |
r | [i/o] recognition process instance |
Definition at line 431 of file word_align.c.
void phoneme_rev_align | ( | WORD_ID * | revwords, | |
short | num, | |||
HTK_Param * | param, | |||
Sentence * | s, | |||
RecogProcess * | r | |||
) |
Do forced alignment per phoneme for the given word sequence (reversed order).
revwords | [in] word sequence in reversed direction | |
num | [in] length of revwords | |
param | [in] input parameter vectors | |
s | [out] Sentence data area to store the alignment result | |
r | [i/o] recognition process instance |
Definition at line 459 of file word_align.c.
void state_align | ( | WORD_ID * | words, | |
short | num, | |||
HTK_Param * | param, | |||
Sentence * | s, | |||
RecogProcess * | r | |||
) |
Do forced alignment per HMM state for the given word sequence.
words | [in] word sequence | |
num | [in] length of words | |
param | [in] input parameter vectors | |
s | [out] Sentence data area to store the alignment result | |
r | [i/o] recognition process instance |
Definition at line 492 of file word_align.c.
void state_rev_align | ( | WORD_ID * | revwords, | |
short | num, | |||
HTK_Param * | param, | |||
Sentence * | s, | |||
RecogProcess * | r | |||
) |
Do forced alignment per state for the given word sequence (reversed order).
revwords | [in] word sequence in reversed direction | |
num | [in] length of revwords | |
param | [in] input parameter vectors | |
s | [out] Sentence data area to store the alignment result | |
r | [i/o] recognition process instance |
Definition at line 520 of file word_align.c.