Julius 4.2
関数
libsent/src/anlz/paramselect.c

パラメータベクトルの型のチェックと調整 [詳細]

#include <sent/stddefs.h>
#include <sent/htk_param.h>
#include <sent/htk_hmm.h>

ソースコードを見る。

関数

static void mark_exclude_vector (int loc, int len, int *vmark, int vlen)
 Put exlusion marks for vector for len elements from loc -th dimension.
static void exec_exclude_vectors (HTK_Param *p, int *vmark)
 Execute exclusion for a parameter data according to the exclusion marks.
int guess_basenum (HTK_Param *p, short qualtype)
 Guess the length of the base coefficient according to the total vector length and parameter type.
static boolean select_param_vmark (HTK_Param *src, short dst_type_arg, int *vmark, int vlen, short *new_type)
 Compare source parameter type and required type in HTK HMM, and set mark.
static boolean select_param_kind (HTK_Param *p, short dst_type_arg)
 Extracts needed parameter vector specified in dst_type_arg from src, and returns newly allocated parameter structure.
int param_check_and_adjust (HTK_HMM_INFO *hmminfo, HTK_Param *param, boolean vflag)
 Top function to adjust parameter.

説明

パラメータベクトルの型のチェックと調整

HMMと入力特徴パラメータの型をチェックします.タイプが一致しない場合, 特徴パラメータの一部を削除することで一致するよう調整できるかどうか を試みます.(例:特徴量ファイルが MFCC_E_D_Z (26次元) で与えられた とき,音響モデルが MFCC_E_D_N_Z (25次元) である場合,絶対値パワー項を 差し引くことで調整できます.)

調整アルゴリズムは以下のとおりです.

  1. 入力の各ベクトル要素に対応するマークを 0 に初期化
  2. HMMで要求されている型に対応しないベクトル要素に 1 をマークする
  3. 新たにパラメータ領域を確保し,必要な要素(マークされていない要素) のみをコピーする.
作者:
Akinobu LEE
日付:
Sun Feb 13 20:46:39 2005
Revision:
1.3

paramselect.c で定義されています。


関数

static void mark_exclude_vector ( int  loc,
int  len,
int *  vmark,
int  vlen 
) [static]

Put exlusion marks for vector for len elements from loc -th dimension.

引数:
loc[in] beginning dimension to mark
len[in] number of dimension to mark from loc
vmark[in] mark buffer
vlen[in] length of vmark

paramselect.c63 行で定義されています。

参照元 select_param_vmark().

static void exec_exclude_vectors ( HTK_Param p,
int *  vmark 
) [static]

Execute exclusion for a parameter data according to the exclusion marks.

Execute vector element exclusion will be done inline.

引数:
p[i/o] parameter
vmark[in] mark buffer

paramselect.c101 行で定義されています。

参照元 select_param_kind().

int guess_basenum ( HTK_Param p,
short  qualtype 
)

Guess the length of the base coefficient according to the total vector length and parameter type.

引数:
p[in] parameter data
qualtype[in] parameter type
戻り値:
the guessed size of the base coefficient.

paramselect.c133 行で定義されています。

参照元 guess_abs_e_location(), と select_param_vmark().

static boolean select_param_vmark ( HTK_Param src,
short  dst_type_arg,
int *  vmark,
int  vlen,
short *  new_type 
) [static]

Compare source parameter type and required type in HTK HMM, and set mark.

引数:
src[in] input parameter
dst_type_arg[in] required parameter type
vmark[in] mark buffer
vlen[in] length of vmark
new_type[out] return the new type
戻り値:
TRUE on success, FALSE on failure.

paramselect.c168 行で定義されています。

参照元 select_param_kind().

static boolean select_param_kind ( HTK_Param p,
short  dst_type_arg 
) [static]

Extracts needed parameter vector specified in dst_type_arg from src, and returns newly allocated parameter structure.

引数:
src[in] input parameter
dst_type_arg[in] required parameter type
戻り値:
newly allocated adjusted parameter, NULL on failure.

paramselect.c319 行で定義されています。

参照元 param_check_and_adjust().

int param_check_and_adjust ( HTK_HMM_INFO hmminfo,
HTK_Param param,
boolean  vflag 
)

Top function to adjust parameter.

It compares the types for the given parameter param and HMM definition hmminfo. If type is not the same, adjustment will be tried.

引数:
hmminfo[in] HTK HMM definition
param[i/o] input parameter, will be freed if adjustment was performed in this function
vflag[in] if TRUE, output verbose messages
戻り値:
1 on success, 0 if no adjustment needed, or -1 on failure (in case parameter type does not match even by the adjustment).

paramselect.c371 行で定義されています。

参照元 j_recognize_stream_core().