tr_phn_cstr_2.cc
来自「这是处理语音信号的程序」· CC 代码 · 共 55 行
CC
55 行
// file: tr_phn_cstr_2.cc//// isip include files//#include "train_phone.h"#include "train_phone_constants.h"// method: constructor//// arguments:// char_1* name_a: name to set for this phone// int_4 nph : (input) number of phones// int_4* phones : (input) index of phones// Train_Model* model : (input) the pointer to the HMM for this phone//// return: none//// this is an overloaded constructor//Train_Phone::Train_Phone(char_1* name_a, int_4 nph_a, int_4* phones_a, Train_Model* model_a) { // initialize name of the phone // name_d = new char_1[strlen((char*)name_a) + (int_4)1]; strcpy((char*)name_d, (char*)name_a); // set the phone indices // num_phones_d = nph_a; // for the TP_WRD_INTERNAL // if (num_phones_d == (int_4)2) { phones_d = new int_4[3]; for (int_4 i = 0; i<3; i++) { phones_d[i] = phones_a[i]; } } else { phones_d = new int_4[num_phones_d]; for (int_4 i = 0; i < num_phones_d; i++) { phones_d[i] = phones_a[i]; } } // set the model pointer // model_d = model_a; active_d = ISIP_FALSE; // exit gracefully //}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?