From sumomo @ users.sourceforge.jp Wed Dec 4 19:13:00 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Wed, 04 Dec 2013 19:13:00 +0900 Subject: [Julius-cvs 862] CVS update: julius4/libjulius/src Message-ID: <1386151980.193026.8847.nullmailer@users.sourceforge.jp> Index: julius4/libjulius/src/m_adin.c diff -u julius4/libjulius/src/m_adin.c:1.15 julius4/libjulius/src/m_adin.c:1.16 --- julius4/libjulius/src/m_adin.c:1.15 Fri Jun 21 02:14:20 2013 +++ julius4/libjulius/src/m_adin.c Wed Dec 4 19:12:59 2013 @@ -12,7 +12,7 @@ * @author Akinobu LEE * @date Fri Mar 18 16:17:23 2005 * - * $Revision: 1.15 $ + * $Revision: 1.16 $ * */ /* @@ -67,9 +67,6 @@ #ifdef USE_MIC case SP_MIC: /* microphone input */ - a->ad_resume = NULL; - a->ad_pause = NULL; - a->ad_terminate = NULL; a->silence_cut_default = TRUE; a->enable_thread = TRUE; switch(dev) { @@ -79,6 +76,9 @@ a->ad_end = adin_mic_end; a->ad_read = adin_mic_read; a->ad_input_name = adin_mic_input_name; + a->ad_pause = adin_mic_pause; + a->ad_terminate = adin_mic_terminate; + a->ad_resume = adin_mic_resume; break; #ifdef HAS_ALSA case SP_INPUT_ALSA: @@ -87,6 +87,9 @@ a->ad_end = adin_alsa_end; a->ad_read = adin_alsa_read; a->ad_input_name = adin_alsa_input_name; + a->ad_pause = NULL; + a->ad_terminate = NULL; + a->ad_resume = NULL; break; #endif #ifdef HAS_OSS @@ -96,6 +99,9 @@ a->ad_end = adin_oss_end; a->ad_read = adin_oss_read; a->ad_input_name = adin_oss_input_name; + a->ad_pause = NULL; + a->ad_terminate = NULL; + a->ad_resume = NULL; break; #endif #ifdef HAS_ESD @@ -105,6 +111,9 @@ a->ad_end = adin_esd_end; a->ad_read = adin_esd_read; a->ad_input_name = adin_esd_input_name; + a->ad_pause = NULL; + a->ad_terminate = NULL; + a->ad_resume = NULL; break; #endif #ifdef HAS_PULSEAUDIO @@ -114,6 +123,9 @@ a->ad_end = adin_pulseaudio_end; a->ad_read = adin_pulseaudio_read; a->ad_input_name = adin_pulseaudio_input_name; + a->ad_pause = NULL; + a->ad_terminate = NULL; + a->ad_resume = NULL; break; #endif default: From sumomo @ users.sourceforge.jp Wed Dec 4 19:13:00 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Wed, 04 Dec 2013 19:13:00 +0900 Subject: [Julius-cvs 863] CVS update: julius4/libsent/src/adin Message-ID: <1386151980.513017.8909.nullmailer@users.sourceforge.jp> Index: julius4/libsent/src/adin/adin_mic_darwin_coreaudio.c diff -u julius4/libsent/src/adin/adin_mic_darwin_coreaudio.c:1.7 julius4/libsent/src/adin/adin_mic_darwin_coreaudio.c:1.8 --- julius4/libsent/src/adin/adin_mic_darwin_coreaudio.c:1.7 Wed Sep 5 17:18:24 2012 +++ julius4/libsent/src/adin/adin_mic_darwin_coreaudio.c Wed Dec 4 19:13:00 2013 @@ -29,7 +29,7 @@ * @author Masatomo Hashimoto * @date Wed Oct 12 11:31:27 2005 * - * $Revision: 1.7 $ + * $Revision: 1.8 $ * */ @@ -44,7 +44,7 @@ * */ -/* $Id: adin_mic_darwin_coreaudio.c,v 1.7 2012/09/05 08:18:24 sumomo Exp $ */ +/* $Id: adin_mic_darwin_coreaudio.c,v 1.8 2013/12/04 10:13:00 sumomo Exp $ */ #include #include @@ -665,6 +665,38 @@ } /** + * Function to pause audio input (wait for buffer flush) + * + * @return TRUE on success, FALSE on failure. + */ +boolean +adin_mic_pause() +{ + return TRUE; +} + +/** + * Function to terminate audio input (disgard buffer) + * + * @return TRUE on success, FALSE on failure. + */ +boolean +adin_mic_terminate() +{ + return TRUE; +} +/** + * Function to resume the paused / terminated audio input + * + * @return TRUE on success, FALSE on failure. + */ +boolean +adin_mic_resume() +{ + return TRUE; +} + +/** * * Function to return current input source device name * Index: julius4/libsent/src/adin/adin_mic_freebsd.c diff -u julius4/libsent/src/adin/adin_mic_freebsd.c:1.9 julius4/libsent/src/adin/adin_mic_freebsd.c:1.10 --- julius4/libsent/src/adin/adin_mic_freebsd.c:1.9 Fri Jun 21 02:14:20 2013 +++ julius4/libsent/src/adin/adin_mic_freebsd.c Wed Dec 4 19:13:00 2013 @@ -39,7 +39,7 @@ * @author Akinobu LEE * @date Sun Feb 13 16:18:26 2005 * - * $Revision: 1.9 $ + * $Revision: 1.10 $ * */ /* @@ -279,6 +279,38 @@ } /** + * Function to pause audio input (wait for buffer flush) + * + * @return TRUE on success, FALSE on failure. + */ +boolean +adin_mic_pause() +{ + return TRUE; +} + +/** + * Function to terminate audio input (disgard buffer) + * + * @return TRUE on success, FALSE on failure. + */ +boolean +adin_mic_terminate() +{ + return TRUE; +} +/** + * Function to resume the paused / terminated audio input + * + * @return TRUE on success, FALSE on failure. + */ +boolean +adin_mic_resume() +{ + return TRUE; +} + +/** * * Function to return current input source device name * Index: julius4/libsent/src/adin/adin_mic_linux.c diff -u julius4/libsent/src/adin/adin_mic_linux.c:1.9 julius4/libsent/src/adin/adin_mic_linux.c:1.10 --- julius4/libsent/src/adin/adin_mic_linux.c:1.9 Fri Jun 21 02:14:20 2013 +++ julius4/libsent/src/adin/adin_mic_linux.c Wed Dec 4 19:13:00 2013 @@ -23,7 +23,7 @@ * @author Akinobu LEE * @date Sun Feb 13 16:18:26 2005 * - * $Revision: 1.9 $ + * $Revision: 1.10 $ * */ /* @@ -137,6 +137,38 @@ } /** + * Function to pause audio input (wait for buffer flush) + * + * @return TRUE on success, FALSE on failure. + */ +boolean +adin_mic_pause() +{ + return TRUE; +} + +/** + * Function to terminate audio input (disgard buffer) + * + * @return TRUE on success, FALSE on failure. + */ +boolean +adin_mic_terminate() +{ + return TRUE; +} +/** + * Function to resume the paused / terminated audio input + * + * @return TRUE on success, FALSE on failure. + */ +boolean +adin_mic_resume() +{ + return TRUE; +} + +/** * * Function to return current input source device name * Index: julius4/libsent/src/adin/adin_mic_o2.c diff -u julius4/libsent/src/adin/adin_mic_o2.c:1.7 julius4/libsent/src/adin/adin_mic_o2.c:1.8 --- julius4/libsent/src/adin/adin_mic_o2.c:1.7 Fri Jun 21 02:14:20 2013 +++ julius4/libsent/src/adin/adin_mic_o2.c Wed Dec 4 19:13:00 2013 @@ -29,7 +29,7 @@ * @author Akinobu LEE * @date Sun Feb 13 18:42:22 2005 * - * $Revision: 1.7 $ + * $Revision: 1.8 $ * */ /* @@ -176,6 +176,38 @@ } /** + * Function to pause audio input (wait for buffer flush) + * + * @return TRUE on success, FALSE on failure. + */ +boolean +adin_mic_pause() +{ + return TRUE; +} + +/** + * Function to terminate audio input (disgard buffer) + * + * @return TRUE on success, FALSE on failure. + */ +boolean +adin_mic_terminate() +{ + return TRUE; +} +/** + * Function to resume the paused / terminated audio input + * + * @return TRUE on success, FALSE on failure. + */ +boolean +adin_mic_resume() +{ + return TRUE; +} + +/** * * Function to return current input source device name * Index: julius4/libsent/src/adin/adin_mic_sol2.c diff -u julius4/libsent/src/adin/adin_mic_sol2.c:1.8 julius4/libsent/src/adin/adin_mic_sol2.c:1.9 --- julius4/libsent/src/adin/adin_mic_sol2.c:1.8 Fri Jun 21 02:14:20 2013 +++ julius4/libsent/src/adin/adin_mic_sol2.c Wed Dec 4 19:13:00 2013 @@ -38,7 +38,7 @@ * @author Akinobu LEE * @date Sun Feb 13 19:06:46 2005 * - * $Revision: 1.8 $ + * $Revision: 1.9 $ * */ /* @@ -239,6 +239,38 @@ } /** + * Function to pause audio input (wait for buffer flush) + * + * @return TRUE on success, FALSE on failure. + */ +boolean +adin_mic_pause() +{ + return TRUE; +} + +/** + * Function to terminate audio input (disgard buffer) + * + * @return TRUE on success, FALSE on failure. + */ +boolean +adin_mic_terminate() +{ + return TRUE; +} +/** + * Function to resume the paused / terminated audio input + * + * @return TRUE on success, FALSE on failure. + */ +boolean +adin_mic_resume() +{ + return TRUE; +} + +/** * * Function to return current input source device name * Index: julius4/libsent/src/adin/adin_mic_sp.c diff -u julius4/libsent/src/adin/adin_mic_sp.c:1.4 julius4/libsent/src/adin/adin_mic_sp.c:1.5 --- julius4/libsent/src/adin/adin_mic_sp.c:1.4 Fri Jul 3 02:05:20 2009 +++ julius4/libsent/src/adin/adin_mic_sp.c Wed Dec 4 19:13:00 2013 @@ -35,7 +35,7 @@ * @author Akinobu LEE * @date Sun Feb 13 19:16:43 2005 * - * $Revision: 1.4 $ + * $Revision: 1.5 $ * */ /* adin_mic_sp.c --- adin microphone library for spAudio @@ -140,6 +140,38 @@ } /** + * Function to pause audio input (wait for buffer flush) + * + * @return TRUE on success, FALSE on failure. + */ +boolean +adin_mic_pause() +{ + return TRUE; +} + +/** + * Function to terminate audio input (disgard buffer) + * + * @return TRUE on success, FALSE on failure. + */ +boolean +adin_mic_terminate() +{ + return TRUE; +} +/** + * Function to resume the paused / terminated audio input + * + * @return TRUE on success, FALSE on failure. + */ +boolean +adin_mic_resume() +{ + return TRUE; +} + +/** * * Function to return current input source device name * Index: julius4/libsent/src/adin/adin_mic_sun4.c diff -u julius4/libsent/src/adin/adin_mic_sun4.c:1.7 julius4/libsent/src/adin/adin_mic_sun4.c:1.8 --- julius4/libsent/src/adin/adin_mic_sun4.c:1.7 Fri Jun 21 02:14:20 2013 +++ julius4/libsent/src/adin/adin_mic_sun4.c Wed Dec 4 19:13:00 2013 @@ -34,7 +34,7 @@ * @author Akinobu LEE * @date Sun Feb 13 18:56:13 2005 * - * $Revision: 1.7 $ + * $Revision: 1.8 $ * */ /* @@ -258,6 +258,38 @@ } /** + * Function to pause audio input (wait for buffer flush) + * + * @return TRUE on success, FALSE on failure. + */ +boolean +adin_mic_pause() +{ + return TRUE; +} + +/** + * Function to terminate audio input (disgard buffer) + * + * @return TRUE on success, FALSE on failure. + */ +boolean +adin_mic_terminate() +{ + return TRUE; +} +/** + * Function to resume the paused / terminated audio input + * + * @return TRUE on success, FALSE on failure. + */ +boolean +adin_mic_resume() +{ + return TRUE; +} + +/** * * Function to return current input source device name * Index: julius4/libsent/src/adin/adin_portaudio.c diff -u julius4/libsent/src/adin/adin_portaudio.c:1.20 julius4/libsent/src/adin/adin_portaudio.c:1.21 --- julius4/libsent/src/adin/adin_portaudio.c:1.20 Fri Jun 21 02:14:20 2013 +++ julius4/libsent/src/adin/adin_portaudio.c Wed Dec 4 19:13:00 2013 @@ -56,7 +56,7 @@ * @author Akinobu LEE * @date Mon Feb 14 12:03:48 2005 * - * $Revision: 1.20 $ + * $Revision: 1.21 $ * */ /* @@ -662,6 +662,60 @@ } /** + * Function to pause audio input (wait for buffer flush) + * + * @return TRUE on success, FALSE on failure. + */ +boolean +adin_mic_pause() +{ + PaError err; + + err = Pa_StopStream(stream); + if (err != paNoError) { + jlog("Error: adin_portaudio: failed to pause stream: %s\n", Pa_GetErrorText(err)); + return FALSE; + } + return TRUE; +} + +/** + * Function to terminate audio input (disgard buffer) + * + * @return TRUE on success, FALSE on failure. + */ +boolean +adin_mic_terminate() +{ + PaError err; + + err = Pa_AbortStream(stream); + if (err != paNoError) { + jlog("Error: adin_portaudio: failed to terminate stream: %s\n", Pa_GetErrorText(err)); + return FALSE; + } + return TRUE; +} + +/** + * Function to resume the paused / terminated audio input + * + * @return TRUE on success, FALSE on failure. + */ +boolean +adin_mic_resume() +{ + PaError err; + + err = Pa_StartStream(stream); + if (err != paNoError) { + jlog("Error: adin_portaudio: failed to resume stream: %s\n", Pa_GetErrorText(err)); + return FALSE; + } + return TRUE; +} + +/** * * Function to return current input source device name * From sumomo @ users.sourceforge.jp Wed Dec 4 19:13:00 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Wed, 04 Dec 2013 19:13:00 +0900 Subject: [Julius-cvs 864] CVS update: julius4/libsent/include/sent Message-ID: <1386151980.391124.8882.nullmailer@users.sourceforge.jp> Index: julius4/libsent/include/sent/adin.h diff -u julius4/libsent/include/sent/adin.h:1.13 julius4/libsent/include/sent/adin.h:1.14 --- julius4/libsent/include/sent/adin.h:1.13 Fri Jun 21 02:14:20 2013 +++ julius4/libsent/include/sent/adin.h Wed Dec 4 19:13:00 2013 @@ -19,7 +19,7 @@ * @author Akinobu LEE * @date Thu Feb 10 17:22:36 2005 * - * $Revision: 1.13 $ + * $Revision: 1.14 $ */ /* * Copyright (c) 1991-2013 Kawahara Lab., Kyoto University @@ -140,6 +140,9 @@ boolean adin_mic_begin(char *pathname); boolean adin_mic_end(); int adin_mic_read(SP16 *buf, int sampnum); +boolean adin_mic_pause(); +boolean adin_mic_terminate(); +boolean adin_mic_resume(); char *adin_mic_input_name(); /* adin/adin_mic_linux_alsa.c */ boolean adin_alsa_standby(int freq, void *arg); From sumomo @ users.sourceforge.jp Wed Dec 4 19:15:06 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Wed, 04 Dec 2013 19:15:06 +0900 Subject: [Julius-cvs 865] CVS update: julius4/libjulius/src Message-ID: <1386152106.946438.15383.nullmailer@users.sourceforge.jp> Index: julius4/libjulius/src/instance.c diff -u julius4/libjulius/src/instance.c:1.9 julius4/libjulius/src/instance.c:1.10 --- julius4/libjulius/src/instance.c:1.9 Fri Jun 21 02:14:20 2013 +++ julius4/libjulius/src/instance.c Wed Dec 4 19:15:06 2013 @@ -12,7 +12,7 @@ * @author Akinobu Lee * @date Sun Oct 28 18:06:20 2007 * - * $Revision: 1.9 $ + * $Revision: 1.10 $ * */ /* @@ -58,7 +58,7 @@ mfcc->htk_loaded = (amconf->analysis.para_htk.loaded == 1) ? TRUE : FALSE; mfcc->wrk = WMP_work_new(mfcc->para); if (mfcc->wrk == NULL) { - jlog("ERROR: j_mfcccalc_new: failed to initialize MFCC computation\n"); + jlog("ERROR: j_mfcccalc_new: failed to initialize feature computation\n"); return NULL; } mfcc->cmn.load_filename = amconf->analysis.cmnload_filename; Index: julius4/libjulius/src/m_fusion.c diff -u julius4/libjulius/src/m_fusion.c:1.26 julius4/libjulius/src/m_fusion.c:1.27 --- julius4/libjulius/src/m_fusion.c:1.26 Fri Jun 21 02:14:20 2013 +++ julius4/libjulius/src/m_fusion.c Wed Dec 4 19:15:06 2013 @@ -20,7 +20,7 @@ * @author Akinobu Lee * @date Thu May 12 13:31:47 2005 * - * $Revision: 1.26 $ + * $Revision: 1.27 $ * */ /* @@ -104,8 +104,13 @@ if (jconf->input.type == INPUT_WAVEFORM) { /* Decode parameter extraction type according to the training parameter type in the header of the given acoustic HMM */ - if ((hmminfo->opt.param_type & F_BASEMASK) != F_MFCC) { - jlog("ERROR: m_fusion: for direct speech input, only HMM trained by MFCC is supported\n"); + switch(hmminfo->opt.param_type & F_BASEMASK) { + case F_MFCC: + case F_FBANK: + case F_MELSPEC: + break; + default: + jlog("ERROR: m_fusion: for direct speech input, only HMM trained by MFCC ior filterbank is supported\n"); hmminfo_free(hmminfo); return NULL; } @@ -236,8 +241,13 @@ if (jconf->input.type == INPUT_WAVEFORM) { /* Decode parameter extraction type according to the training parameter type in the header of the given acoustic HMM */ - if ((gmm->opt.param_type & F_BASEMASK) != F_MFCC) { - jlog("ERROR: m_fusion: for direct speech input, only GMM trained by MFCC is supported\n"); + switch(gmm->opt.param_type & F_BASEMASK) { + case F_MFCC: + case F_FBANK: + case F_MELSPEC: + break; + default: + jlog("ERROR: m_fusion: for direct speech input, only GMM trained by MFCC ior filterbank is supported\n"); hmminfo_free(gmm); return NULL; } Index: julius4/libjulius/src/m_usage.c diff -u julius4/libjulius/src/m_usage.c:1.23 julius4/libjulius/src/m_usage.c:1.24 --- julius4/libjulius/src/m_usage.c:1.23 Fri Jun 21 02:14:20 2013 +++ julius4/libjulius/src/m_usage.c Wed Dec 4 19:15:06 2013 @@ -12,7 +12,7 @@ * @author Akinobu Lee * @date Fri May 13 15:04:34 2005 * - * $Revision: 1.23 $ + * $Revision: 1.24 $ * */ /* @@ -62,7 +62,7 @@ fprintf(fp, "\n--- Global Options -----------------------------------------------\n"); fprintf(fp, "\n Speech Input:\n"); - fprintf(fp, " (Can extract only MFCC based features from waveform)\n"); + fprintf(fp, " (Can extract MFCC/FBANK/MELSPEC features from waveform)\n"); fprintf(fp, " [-input devname] input source (default = htkparam)\n"); fprintf(fp, " htkparam/mfcfile HTK parameter file\n"); fprintf(fp, " file/rawfile waveform file (%s)\n", SUPPORTED_WAVEFILE_FORMAT); Index: julius4/libjulius/src/realtime-1stpass.c diff -u julius4/libjulius/src/realtime-1stpass.c:1.11 julius4/libjulius/src/realtime-1stpass.c:1.12 --- julius4/libjulius/src/realtime-1stpass.c:1.11 Fri Jun 21 02:14:20 2013 +++ julius4/libjulius/src/realtime-1stpass.c Wed Dec 4 19:15:06 2013 @@ -111,7 +111,7 @@ * @author Akinobu Lee * @date Tue Aug 23 11:44:14 2005 * - * $Revision: 1.11 $ + * $Revision: 1.12 $ * */ /* @@ -164,7 +164,7 @@ /* これから計算されるパラメータの型をヘッダに設定 */ /* set header types */ - mfcc->param->header.samptype = F_MFCC; + mfcc->param->header.samptype = para->basetype; if (para->delta) mfcc->param->header.samptype |= F_DELTA; if (para->acc) mfcc->param->header.samptype |= F_ACCL; if (para->energy) mfcc->param->header.samptype |= F_ENERGY; Index: julius4/libjulius/src/wav2mfcc.c diff -u julius4/libjulius/src/wav2mfcc.c:1.5 julius4/libjulius/src/wav2mfcc.c:1.6 --- julius4/libjulius/src/wav2mfcc.c:1.5 Fri Jun 21 02:14:20 2013 +++ julius4/libjulius/src/wav2mfcc.c Wed Dec 4 19:15:06 2013 @@ -40,7 +40,7 @@ * @author Akinobu Lee * @date Sun Sep 18 19:40:34 2005 * - * $Revision: 1.5 $ + * $Revision: 1.6 $ * */ /* @@ -143,7 +143,7 @@ /* make MFCC from speech data */ if (Wav2MFCC(speech, mfcc->param->parvec, para, speechlen, mfcc->wrk) == FALSE) { - jlog("ERROR: failed to compute MFCC from input speech\n"); + jlog("ERROR: failed to compute features from input speech\n"); if (mfcc->frontend.sscalc) { free(mfcc->frontend.ssbuf); mfcc->frontend.ssbuf = NULL; From sumomo @ users.sourceforge.jp Wed Dec 4 19:15:07 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Wed, 04 Dec 2013 19:15:07 +0900 Subject: [Julius-cvs 866] CVS update: julius4/libsent/include/sent Message-ID: <1386152107.407154.15420.nullmailer@users.sourceforge.jp> Index: julius4/libsent/include/sent/mfcc.h diff -u julius4/libsent/include/sent/mfcc.h:1.6 julius4/libsent/include/sent/mfcc.h:1.7 --- julius4/libsent/include/sent/mfcc.h:1.6 Sun Aug 5 10:26:54 2012 +++ julius4/libsent/include/sent/mfcc.h Wed Dec 4 19:15:07 2013 @@ -27,7 +27,7 @@ * @author Akinobu LEE * @date Fri Feb 11 03:40:52 2005 * - * $Revision: 1.6 $ + * $Revision: 1.7 $ * */ @@ -74,6 +74,7 @@ /// mfcc configuration parameter values typedef struct { + short basetype; ///< Parameter basetype (F_MFCC/F_FBANK/F_MELSPEC)/ int smp_period; ///< Sampling period in 100ns units int smp_freq; ///< Sampling frequency int framesize; ///< Window size in samples, similar to WINDOWSIZE in HTK (unit is different) @@ -145,6 +146,8 @@ double *fbank; ///< Local buffer to hold filterbank FBankInfo fb; ///< Local buffer to hold filterbank information int bflen; ///< Length of above + boolean fbank_only; ///< True if output is filterbank + boolean log_fbank; ///< True if use log filterbank #ifdef MFCC_SINCOS_TABLE double *costbl_hamming; ///< Cos table for hamming window int costbl_hamming_len; ///< Length of above From sumomo @ users.sourceforge.jp Wed Dec 4 19:15:07 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Wed, 04 Dec 2013 19:15:07 +0900 Subject: [Julius-cvs 867] CVS update: julius4/libsent/src/wav2mfcc Message-ID: <1386152107.719557.15436.nullmailer@users.sourceforge.jp> Index: julius4/libsent/src/wav2mfcc/mfcc-core.c diff -u julius4/libsent/src/wav2mfcc/mfcc-core.c:1.8 julius4/libsent/src/wav2mfcc/mfcc-core.c:1.9 --- julius4/libsent/src/wav2mfcc/mfcc-core.c:1.8 Fri Jun 21 02:14:27 2013 +++ julius4/libsent/src/wav2mfcc/mfcc-core.c Wed Dec 4 19:15:07 2013 @@ -17,7 +17,7 @@ * @author Akinobu Lee * @date Mon Aug 7 11:55:45 2006 * - * $Revision: 1.8 $ + * $Revision: 1.9 $ * */ /* @@ -510,11 +510,13 @@ } } - /* Take logs */ - for(bin = 1; bin <= para->fbank_num; bin++){ - temp = w->fbank[bin]; - if(temp < 1.0) temp = 1.0; - w->fbank[bin] = log(temp); + if (w->log_fbank) { + /* Take logs */ + for(bin = 1; bin <= para->fbank_num; bin++){ + temp = w->fbank[bin]; + if(temp < 1.0) temp = 1.0; + w->fbank[bin] = log(temp); + } } } @@ -625,6 +627,26 @@ w = (MFCCWork *)mymalloc(sizeof(MFCCWork)); memset(w, 0, sizeof(MFCCWork)); + /* set switches by the parameter type */ + switch(para->basetype) { + case F_MFCC: + w->fbank_only = FALSE; + w->log_fbank = TRUE; + break; + case F_FBANK: + w->fbank_only = TRUE; + w->log_fbank = TRUE; + break; + case F_MELSPEC: + w->fbank_only = TRUE; + w->log_fbank = FALSE; + break; + default: + jlog("Error: mfcc-core: unsupported parameter type\n"); + free(w); + return NULL; + } + /* set filterbank information */ if (InitFBank(w, para) == FALSE) return NULL; @@ -679,6 +701,15 @@ } /* filterbank */ MakeFBank(w->bf, w, para); + + if (w->fbank_only) { + /* return the filterbank */ + for (p = 0; p < para->mfcc_dim; p++) { + mfcc[p] = w->fbank[p+1]; + } + return; + } + /* 0'th cepstral parameter */ if (para->c0) c0 = CalcC0(w, para); /* MFCC */ Index: julius4/libsent/src/wav2mfcc/para.c diff -u julius4/libsent/src/wav2mfcc/para.c:1.12 julius4/libsent/src/wav2mfcc/para.c:1.13 --- julius4/libsent/src/wav2mfcc/para.c:1.12 Fri Jun 21 02:14:27 2013 +++ julius4/libsent/src/wav2mfcc/para.c Wed Dec 4 19:15:07 2013 @@ -16,7 +16,7 @@ * @author Akinobu Lee * @date Fri Oct 27 14:55:00 2006 * - * $Revision: 1.12 $ + * $Revision: 1.13 $ * */ /* @@ -38,6 +38,7 @@ void undef_para(Value *para) { + para->basetype = F_ERR_INVALID; para->smp_period = -1; para->smp_freq = -1; para->framesize = -1; @@ -84,6 +85,7 @@ void make_default_para(Value *para) { + para->basetype = F_MFCC; para->smp_period = 625; /* 16kHz = 625 100ns unit */ para->smp_freq = 16000; /* 16kHz = 625 100ns unit */ para->framesize = DEF_FRAMESIZE; @@ -144,6 +146,7 @@ void apply_para(Value *dst, Value *src) { + if (dst->basetype == F_ERR_INVALID) dst->basetype = src->basetype; if (dst->smp_period == -1) dst->smp_period = src->smp_period; if (dst->smp_freq == -1) dst->smp_freq = src->smp_freq; if (dst->framesize == -1) dst->framesize = src->framesize; @@ -322,12 +325,14 @@ int dim; /* decode required parameter extraction types */ + para->basetype = param_type & F_BASEMASK; para->delta = (param_type & F_DELTA) ? TRUE : FALSE; para->acc = (param_type & F_ACCL) ? TRUE : FALSE; para->energy = (param_type & F_ENERGY) ? TRUE : FALSE; para->c0 = (param_type & F_ZEROTH) ? TRUE : FALSE; para->absesup = (param_type & F_ENERGY_SUP) ? TRUE : FALSE; para->cmn = (param_type & F_CEPNORM) ? TRUE : FALSE; + /* guess MFCC dimension from the vector size and parameter type in the acoustic HMM */ dim = vec_size; @@ -343,6 +348,16 @@ para->vecbuflen = para->baselen * (1 + (para->delta ? 1 : 0) + (para->acc ? 1 : 0)); /* set size of final parameter vector */ para->veclen = para->vecbuflen - (para->absesup ? 1 : 0); + + /* on filter-bank output, also overwrite the number of filterbank */ + if (para->basetype == F_FBANK || para->basetype == F_MELSPEC) { + if (para->fbank_num != dim) { + jlog("Warning: number of filterbank is set to %d, but AM requires %d\n", para->fbank_num, dim); + jlog("Warning: use value of AM: %d\n", dim); + para->fbank_num = dim; + } + } + } /** @@ -356,7 +371,21 @@ put_para(FILE *fp, Value *para) { fprintf(fp, " Acoustic analysis condition:\n"); - fprintf(fp, "\t parameter = MFCC"); + fprintf(fp, "\t parameter = "); + switch(para->basetype) { + case F_MFCC: + fprintf(fp, "MFCC"); + break; + case F_FBANK: + fprintf(fp, "FBANK"); + break; + case F_MELSPEC: + fprintf(fp, "MELSPEC"); + break; + default: + fprintf(fp, "(UNKNOWN_OR_NOT_SUPPORTED)"); + break; + } if (para->c0) fprintf(fp, "_0"); if (para->energy) fprintf(fp, "_E"); if (para->delta) fprintf(fp, "_D"); From sumomo @ users.sourceforge.jp Thu Dec 5 12:43:14 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Thu, 05 Dec 2013 12:43:14 +0900 Subject: [Julius-cvs 868] CVS update: julius4/libjulius/src Message-ID: <1386214994.617996.17119.nullmailer@users.sourceforge.jp> Index: julius4/libjulius/src/m_fusion.c diff -u julius4/libjulius/src/m_fusion.c:1.27 julius4/libjulius/src/m_fusion.c:1.28 --- julius4/libjulius/src/m_fusion.c:1.27 Wed Dec 4 19:15:06 2013 +++ julius4/libjulius/src/m_fusion.c Thu Dec 5 12:43:13 2013 @@ -20,7 +20,7 @@ * @author Akinobu Lee * @date Thu May 12 13:31:47 2005 * - * $Revision: 1.27 $ + * $Revision: 1.28 $ * */ /* @@ -1376,6 +1376,25 @@ } } + /* initialize CMN and CVN calculation work area for batch computation */ + if (! recog->jconf->decodeopt.realtime_flag) { + if (recog->jconf->input.type == INPUT_WAVEFORM) { + for(mfcc = recog->mfcclist; mfcc; mfcc = mfcc->next) { + if (mfcc->cmn.load_filename) { + if (mfcc->para->cmn || mfcc->para->cvn) { + mfcc->cmn.wrk = CMN_realtime_new(mfcc->para, mfcc->cmn.map_weight); + if ((mfcc->cmn.loaded = CMN_load_from_file(mfcc->cmn.wrk, mfcc->cmn.load_filename))== FALSE) { + jlog("ERROR: m_fusion: failed to read initial cepstral mean from \"%s\"\n", mfcc->cmn.load_filename); + return FALSE; + } + } else { + jlog("WARNING: m_fusion: CMN load file specified but AM not require it, ignored\n"); + } + } + } + } + } + /* finished! */ jlog("STAT: All init successfully done\n\n"); Index: julius4/libjulius/src/m_info.c diff -u julius4/libjulius/src/m_info.c:1.20 julius4/libjulius/src/m_info.c:1.21 --- julius4/libjulius/src/m_info.c:1.20 Fri Jun 21 02:14:20 2013 +++ julius4/libjulius/src/m_info.c Thu Dec 5 12:43:13 2013 @@ -12,7 +12,7 @@ * @author Akinobu Lee * @date Thu May 12 14:14:01 2005 * - * $Revision: 1.20 $ + * $Revision: 1.21 $ * */ /* @@ -208,26 +208,42 @@ jlog("off\n"); } } - jlog(" cepstral normalization = "); - if (mfcc->para->cmn || mfcc->para->cvn) { + jlog(" cep. mean normalization = "); + if (mfcc->para->cmn) { + jlog("yes, "); if (jconf->decodeopt.realtime_flag) { - jlog("real-time MAP-"); + jlog("real-time MAP-CMN, "); + if (mfcc->cmn.loaded) { + jlog("updating initial mean with last %.1f sec. utterances, first mean loaded from file\n", (float)CPMAX / 100.0); + } else { + jlog("updating initial mean with last %.1f sec utterances (no first mean)\n", (float)CPMAX / 100.0); + } } else { - jlog("sentence "); - } - if (mfcc->para->cmn) { - jlog("CMN"); - } - if (mfcc->para->cmn && mfcc->para->cvn) { - jlog("+"); + if (mfcc->cmn.loaded) { + jlog("applying a static mean loaded from file (no update)\n"); + } else { + jlog("applying self mean calculated per utterance\n"); + } } - if (mfcc->para->cvn) { - jlog("CVN"); + } else { + jlog("no\n"); + } + jlog(" cep. var. normalization = "); + if (mfcc->para->cvn) { + jlog("yes, "); + if (mfcc->cmn.loaded) { + jlog("applying a static variance loaded from file (no update)\n"); + } else { + if (jconf->decodeopt.realtime_flag) { + jlog("estimating long-term variance from all speech input from start\n"); + } else { + jlog("applying self variance calculated per utterance\n"); + } } - jlog("\n"); } else { jlog("no\n"); } + jlog("\t base setup from ="); if (mfcc->htk_loaded == 1 || mfcc->hmm_loaded == 1) { if (mfcc->hmm_loaded == 1) { @@ -927,71 +943,99 @@ jlog("\n"); jlog("----------------------- System Information end -----------------------\n"); + jlog("\n"); -#ifdef USE_MIC - if (jconf->decodeopt.realtime_flag) { - boolean flag; - flag = FALSE; - for(mfcc=recog->mfcclist; mfcc; mfcc=mfcc->next) { - if (mfcc->para->cmn && mfcc->cmn.loaded) { - flag = TRUE; - break; - } - } - if (flag) { - jlog("\n"); - jlog("initial CMN parameter loaded from file\nfor"); - for(mfcc=recog->mfcclist; mfcc; mfcc=mfcc->next) { - if (mfcc->para->cmn && mfcc->cmn.loaded) { - jlog(" MFCC%02d", mfcc->id); - } - } - jlog("\n"); - } - flag = FALSE; - for(mfcc=recog->mfcclist; mfcc; mfcc=mfcc->next) { - if (mfcc->para->cmn && !mfcc->cmn.loaded) { - flag = TRUE; - break; - } - } - if (flag) { - jlog("\n"); - jlog("\t*************************************************************\n"); - jlog("\t* NOTICE: The first input may not be recognized, since *\n"); - jlog("\t* no initial CMN parameter is available on startup. *\n"); - jlog("\t* for"); - for(mfcc=recog->mfcclist; mfcc; mfcc=mfcc->next) { - if (mfcc->para->cmn && !mfcc->cmn.loaded) { - jlog(" MFCC%02d", mfcc->id); + for(mfcc=recog->mfcclist; mfcc; mfcc=mfcc->next) { + + if (jconf->decodeopt.realtime_flag) { + + /* warning for real-time decoding */ + if (mfcc->para->cmn || mfcc->para->cvn) { + jlog("Notice for feature extraction (%02d),\n", mfcc->id); + jlog("\t*************************************************************\n"); + if (mfcc->para->cmn && mfcc->para->cvn) { + jlog("\t* Cepstral mean and variance norm. for real-time decoding: *\n"); + if (mfcc->cmn.loaded) { + jlog("\t* initial mean loaded from file, updating per utterance. *\n"); + jlog("\t* static variance loaded from file, apply it constantly. *\n"); + jlog("\t* NOTICE: The first input may not be recognized, since *\n"); + jlog("\t* cepstral mean is unstable on startup. *\n"); + } else { + jlog("\t* no static variance was given by file. *\n"); + jlog("\t* estimating long-term variance from all speech from start. *\n"); + jlog("\t* NOTICE: May not work on the first several minutes, since *\n"); + jlog("\t* no cepstral variance is given on startup. *\n"); + } + } else if (mfcc->para->cmn) { + jlog("\t* Cepstral mean normalization for real-time decoding: *\n"); + if (mfcc->cmn.loaded) { + jlog("\t* initial mean loaded from file, updating per utterance. *\n"); + jlog("\t* NOTICE: The first input may not good, since *\n"); + jlog("\t* cepstral mean is unstable on startup. *\n"); + } else { + jlog("\t* NOTICE: The first input may not be recognized, since *\n"); + jlog("\t* no initial mean is available on startup. *\n"); + } + } else if (mfcc->para->cvn) { + jlog("\t* Cepstral variance normalization for real-time decoding: *\n"); + if (mfcc->cmn.loaded) { + jlog("\t* static variance loaded from file, apply it constantly. *\n"); + } else { + jlog("\t* no static variance is given by file. *\n"); + jlog("\t* estimating long-term variance from all speech from start. *\n"); + jlog("\t* NOTICE: The first minutes may not work well, since *\n"); + jlog("\t* no cepstral variance is given on startup. *\n"); + } } + jlog("\t*************************************************************\n"); } - jlog("*\n"); - jlog("\t*************************************************************\n"); - } - flag = FALSE; - for(mfcc=recog->mfcclist; mfcc; mfcc=mfcc->next) { if (mfcc->para->energy && mfcc->para->enormal) { - flag = TRUE; - break; + jlog("Notice for energy computation (%02d),\n", mfcc->id); + jlog("\t*************************************************************\n"); + jlog("\t* NOTICE: Energy normalization is activated on live input: *\n"); + jlog("\t* maximum energy of LAST INPUT will be used for it. *\n"); + jlog("\t* So, the first input will not be recognized. *\n"); + jlog("\t*************************************************************\n"); } - } - if (flag) { - jlog("\t*************************************************************\n"); - jlog("\t* NOTICE: Energy normalization is activated on live input: *\n"); - jlog("\t* maximum energy of LAST INPUT will be used for it. *\n"); - jlog("\t* So, the first input will not be recognized. *\n"); - jlog("\t* for"); - for(mfcc=recog->mfcclist; mfcc; mfcc=mfcc->next) { - if (mfcc->para->energy && mfcc->para->enormal) { - jlog(" MFCC%02d", mfcc->id); + + } else { + + /* warning for batch decoding */ + if (mfcc->para->cmn || mfcc->para->cvn) { + jlog("Notice for feature extraction (%02d),\n", mfcc->id); + jlog("\t*************************************************************\n"); + if (mfcc->para->cmn && mfcc->para->cvn) { + jlog("\t* Cepstral mean and variance norm. for batch decoding: *\n"); + if (mfcc->cmn.loaded) { + jlog("\t* constant mean and variance was loaded from file. *\n"); + jlog("\t* they will be applied constantly for all input. *\n"); + } else { + jlog("\t* per-utterance mean and variance will be computed and *\n"); + jlog("\t* applied for each input. *\n"); + } + } else if (mfcc->para->cmn) { + jlog("\t* Cepstral mean normalization for batch decoding: *\n"); + if (mfcc->cmn.loaded) { + jlog("\t* constant mean was loaded from file. *\n"); + jlog("\t* they will be constantly applied for all input. *\n"); + } else { + jlog("\t* per-utterance mean will be computed and applied. *\n"); + } + } else if (mfcc->para->cvn) { + jlog("\t* Cepstral variance normalization for batch decoding: *\n"); + if (mfcc->cmn.loaded) { + jlog("\t* constant variance was loaded from file. *\n"); + jlog("\t* they will be constantly applied for all input. *\n"); + } else { + jlog("\t* per-utterance variance will be computed and applied. *\n"); + } } + jlog("\t*************************************************************\n"); } - jlog("*\n"); - jlog("\t*************************************************************\n"); + } + } -#endif } /* end of file */ Index: julius4/libjulius/src/wav2mfcc.c diff -u julius4/libjulius/src/wav2mfcc.c:1.6 julius4/libjulius/src/wav2mfcc.c:1.7 --- julius4/libjulius/src/wav2mfcc.c:1.6 Wed Dec 4 19:15:06 2013 +++ julius4/libjulius/src/wav2mfcc.c Thu Dec 5 12:43:13 2013 @@ -40,7 +40,7 @@ * @author Akinobu Lee * @date Sun Sep 18 19:40:34 2005 * - * $Revision: 1.6 $ + * $Revision: 1.7 $ * */ /* @@ -142,7 +142,7 @@ } /* make MFCC from speech data */ - if (Wav2MFCC(speech, mfcc->param->parvec, para, speechlen, mfcc->wrk) == FALSE) { + if (Wav2MFCC(speech, mfcc->param->parvec, para, speechlen, mfcc->wrk, mfcc->cmn.wrk) == FALSE) { jlog("ERROR: failed to compute features from input speech\n"); if (mfcc->frontend.sscalc) { free(mfcc->frontend.ssbuf); From sumomo @ users.sourceforge.jp Thu Dec 5 12:43:14 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Thu, 05 Dec 2013 12:43:14 +0900 Subject: [Julius-cvs 869] CVS update: julius4/libsent/include/sent Message-ID: <1386214994.868201.17134.nullmailer@users.sourceforge.jp> Index: julius4/libsent/include/sent/mfcc.h diff -u julius4/libsent/include/sent/mfcc.h:1.7 julius4/libsent/include/sent/mfcc.h:1.8 --- julius4/libsent/include/sent/mfcc.h:1.7 Wed Dec 4 19:15:07 2013 +++ julius4/libsent/include/sent/mfcc.h Thu Dec 5 12:43:14 2013 @@ -27,7 +27,7 @@ * @author Akinobu LEE * @date Fri Feb 11 03:40:52 2005 * - * $Revision: 1.7 $ + * $Revision: 1.8 $ * */ @@ -195,7 +195,9 @@ boolean mean; ///< TRUE if CMN is enabled boolean var; ///< TRUE if CVN is enabled boolean cmean_init_set; ///< TRUE if cmean_init (and cvar_init) was set - CMEAN now; ///< Work area to hold current cepstral mean + CMEAN now; ///< Work area to hold current cepstral mean and variance + CMEAN all; ///< Work area to hold all cepstral mean and variance + boolean loaded_from_file; ///< TRUE if loaded from file } CMNWork; /** @@ -243,7 +245,7 @@ /**** wav2mfcc-buffer.c ****/ /* Convert wave -> MFCC_E_D_(Z) (batch) */ -int Wav2MFCC(SP16 *wave, float **mfcc, Value *para, int nSamples, MFCCWork *w); +int Wav2MFCC(SP16 *wave, float **mfcc, Value *para, int nSamples, MFCCWork *w, CMNWork *c); /* Calculate delta coefficients (batch) */ void Delta(float **c, int frame, Value *para); /* Calculate acceleration coefficients (batch) */ @@ -251,8 +253,8 @@ /* Normalise log energy (batch) */ void NormaliseLogE(float **c, int frame_num, Value *para); /* Cepstrum Mean Normalization (batch) */ -void CMN(float **mfcc, int frame_num, int dim); -void MVN(float **mfcc, int frame_num, Value *para); +void CMN(float **mfcc, int frame_num, int dim, CMNWork *c); +void MVN(float **mfcc, int frame_num, Value *para, CMNWork *c); /**** wav2mfcc-pipe.c ****/ DeltaBuf *WMP_deltabuf_new(int veclen, int windowlen); From sumomo @ users.sourceforge.jp Thu Dec 5 12:43:14 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Thu, 05 Dec 2013 12:43:14 +0900 Subject: [Julius-cvs 870] CVS update: julius4/libsent/src/wav2mfcc Message-ID: <1386214994.954269.17151.nullmailer@users.sourceforge.jp> Index: julius4/libsent/src/wav2mfcc/wav2mfcc-buffer.c diff -u julius4/libsent/src/wav2mfcc/wav2mfcc-buffer.c:1.6 julius4/libsent/src/wav2mfcc/wav2mfcc-buffer.c:1.7 --- julius4/libsent/src/wav2mfcc/wav2mfcc-buffer.c:1.6 Thu Jul 28 16:07:48 2011 +++ julius4/libsent/src/wav2mfcc/wav2mfcc-buffer.c Thu Dec 5 12:43:14 2013 @@ -24,7 +24,7 @@ * @author Akinobu LEE * @date Thu Feb 17 17:43:35 2005 * - * $Revision: 1.6 $ + * $Revision: 1.7 $ * */ @@ -54,7 +54,7 @@ * @return the number of processed frames. */ int -Wav2MFCC(SP16 *wave, float **mfcc, Value *para, int nSamples, MFCCWork *w) +Wav2MFCC(SP16 *wave, float **mfcc, Value *para, int nSamples, MFCCWork *w, CMNWork *c) { int i, k, t; int end = 0, start = 1; @@ -94,8 +94,8 @@ if (para->acc) Accel(mfcc, frame_num, para); /* Cepstrum Mean and/or Variance Normalization */ - if (para->cmn && ! para->cvn) CMN(mfcc, frame_num, para->mfcc_dim + (para->c0 ? 1 : 0)); - else if (para->cmn || para->cvn) MVN(mfcc, frame_num, para); + if (para->cmn && ! para->cvn) CMN(mfcc, frame_num, para->mfcc_dim + (para->c0 ? 1 : 0), c); + else if (para->cmn || para->cvn) MVN(mfcc, frame_num, para, c); return(frame_num); } @@ -216,26 +216,34 @@ * @param frame_num [in] number of frames * @param dim [in] total dimension of MFCC vectors */ -void CMN(float **mfcc, int frame_num, int dim) +void CMN(float **mfcc, int frame_num, int dim, CMNWork *c) { int i, t; float *mfcc_ave, *sum; - mfcc_ave = (float *)mycalloc(dim, sizeof(float)); - sum = (float *)mycalloc(dim, sizeof(float)); - - for(i = 0; i < dim; i++){ - sum[i] = 0.0; - for(t = 0; t < frame_num; t++) - sum[i] += mfcc[t][i]; - mfcc_ave[i] = sum[i] / frame_num; - } - for(t = 0; t < frame_num; t++){ - for(i = 0; i < dim; i++) - mfcc[t][i] = mfcc[t][i] - mfcc_ave[i]; + if (c != NULL && c->cmean_init_set) { + /* has initial param, use it permanently */ + for(t = 0; t < frame_num; t++){ + for(i = 0; i < dim; i++) + mfcc[t][i] -= c->cmean_init[i]; + } + } else { + /* compute from current input */ + mfcc_ave = (float *)mycalloc(dim, sizeof(float)); + sum = (float *)mycalloc(dim, sizeof(float)); + for(i = 0; i < dim; i++){ + sum[i] = 0.0; + for(t = 0; t < frame_num; t++) + sum[i] += mfcc[t][i]; + mfcc_ave[i] = sum[i] / frame_num; + } + for(t = 0; t < frame_num; t++){ + for(i = 0; i < dim; i++) + mfcc[t][i] = mfcc[t][i] - mfcc_ave[i]; + } + free(sum); + free(mfcc_ave); } - free(sum); - free(mfcc_ave); } /** @@ -245,7 +253,7 @@ * @param frame_num [in] number of frames * @param para [in] configuration parameters */ -void MVN(float **mfcc, int frame_num, Value *para) +void MVN(float **mfcc, int frame_num, Value *para, CMNWork *c) { int i, t; float *mfcc_mean, *mfcc_sd; @@ -254,6 +262,21 @@ basedim = para->mfcc_dim + (para->c0 ? 1 : 0); + if (c != NULL && c->cmean_init_set) { + /* has initial param, use it permanently */ + for(t = 0; t < frame_num; t++){ + if (para->cmn) { + /* mean normalization (base MFCC only) */ + for(i = 0; i < basedim; i++) mfcc[t][i] -= c->cmean_init[i]; + } + if (para->cvn) { + /* variance normalization (full MFCC) */ + for(i = 0; i < para->veclen; i++) mfcc[t][i] /= sqrt(c->cvar_init[i]); + } + } + return; + } + mfcc_mean = (float *)mycalloc(para->veclen, sizeof(float)); if (para->cvn) mfcc_sd = (float *)mycalloc(para->veclen, sizeof(float)); Index: julius4/libsent/src/wav2mfcc/wav2mfcc-pipe.c diff -u julius4/libsent/src/wav2mfcc/wav2mfcc-pipe.c:1.9 julius4/libsent/src/wav2mfcc/wav2mfcc-pipe.c:1.10 --- julius4/libsent/src/wav2mfcc/wav2mfcc-pipe.c:1.9 Fri Jun 21 02:14:27 2013 +++ julius4/libsent/src/wav2mfcc/wav2mfcc-pipe.c Thu Dec 5 12:43:14 2013 @@ -20,7 +20,7 @@ * @author Akinobu LEE * @date Thu Feb 17 18:12:30 2005 * - * $Revision: 1.9 $ + * $Revision: 1.10 $ * */ /* @@ -267,11 +267,19 @@ } c->now.mfcc_sum = (float *)mymalloc(sizeof(float) * c->veclen); if (c->var) c->now.mfcc_var = (float *)mymalloc(sizeof(float) * c->veclen); + if (c->var) c->all.mfcc_var = (float *)mymalloc(sizeof(float) * c->veclen); c->cmean_init = (float *)mymalloc(sizeof(float) * c->veclen); if (c->var) c->cvar_init = (float *)mymalloc(sizeof(float) * c->veclen); c->cmean_init_set = FALSE; + c->loaded_from_file = FALSE; + + if (c->var) { + for(i = 0; i < c->veclen; i++) c->all.mfcc_var[i] = 0.0; + } + c->all.framenum = 0; + return c; } @@ -291,6 +299,7 @@ if (c->var) { free(c->cvar_init); free(c->now.mfcc_var); + free(c->all.mfcc_var); } for(i=0;iclist_max;i++) { if (c->var) free(c->clist[i].mfcc_var); @@ -349,10 +358,8 @@ mfcc[d] -= x; } if (c->var) { - /* variance normalization */ - x = c->now.mfcc_var[d] + c->cweight * c->cvar_init[d]; - y = (double)c->now.framenum + c->cweight; - mfcc[d] /= sqrt(x / y); + /* variance normalization (static) */ + mfcc[d] /= sqrt(c->cvar_init[d]); } } } else { @@ -417,32 +424,31 @@ /* compute cepstral mean from now and previous sums up to CPMAX frames */ for(d=0;dveclen;d++) c->cmean_init[d] = c->now.mfcc_sum[d]; - if (c->var) { - for(d=0;dveclen;d++) c->cvar_init[d] = c->now.mfcc_var[d]; - } frames = c->now.framenum; for(i=0;iclist_num;i++) { for(d=0;dveclen;d++) c->cmean_init[d] += c->clist[i].mfcc_sum[d]; - if (c->var) { - for(d=0;dveclen;d++) c->cvar_init[d] += c->clist[i].mfcc_var[d]; - } frames += c->clist[i].framenum; if (frames >= CPMAX) break; } for(d=0;dveclen;d++) c->cmean_init[d] /= (float) frames; - if (c->var) { - for(d=0;dveclen;d++) c->cvar_init[d] /= (float) frames; - } c->cmean_init_set = TRUE; + /* also compute all and update cvar_init */ + if (c->loaded_from_file == FALSE && c->var) { + for(d = 0; d < c->veclen; d++) { + c->all.mfcc_var[d] = (c->all.mfcc_var[d] * c->all.framenum + c->now.mfcc_var[d]) / (c->all.framenum + c->now.framenum); + } + c->all.framenum += c->now.framenum; + for(d=0;dveclen;d++) c->cvar_init[d] = c->all.mfcc_var[d]; + } + /* expand clist if neccessary */ if (c->clist_num == c->clist_max && frames < CPMAX) { c->clist_max += CPSTEP; c->clist = (CMEAN *)myrealloc(c->clist, sizeof(CMEAN) * c->clist_max); for(i=c->clist_num;iclist_max;i++) { c->clist[i].mfcc_sum = (float *)mymalloc(sizeof(float)*c->veclen); - if (c->var) c->clist[i].mfcc_var = (float *)mymalloc(sizeof(float)*c->veclen); c->clist[i].framenum = 0; } } @@ -455,7 +461,6 @@ if (c->var) c->clist[0].mfcc_var = tmp2; /* copy now to clist[0] */ memcpy(c->clist[0].mfcc_sum, c->now.mfcc_sum, sizeof(float) * c->veclen); - if (c->var) memcpy(c->clist[0].mfcc_var, c->now.mfcc_var, sizeof(float) * c->veclen); c->clist[0].framenum = c->now.framenum; if (c->clist_num < c->clist_max) c->clist_num++; @@ -485,33 +490,10 @@ } /** - * Write binary with byte swap (assume data is Big Endian) - * - * @param buf [in] data buffer - * @param unitbyte [in] size of unit in bytes - * @param unitnum [in] number of units to write - * @param fd [in] file descriptor - * - * @return TRUE if required number of units are fully written, FALSE if failed. - */ -static boolean -mywrite(void *buf, size_t unitbyte, size_t unitnum, int fd) -{ -#ifndef WORDS_BIGENDIAN - swap_bytes(buf, unitbyte, unitnum); -#endif - if (write(fd, buf, unitbyte * unitnum) < unitbyte * unitnum) { - return(FALSE); - } -#ifndef WORDS_BIGENDIAN - swap_bytes(buf, unitbyte, unitnum); -#endif - return(TRUE); -} - -/** * Load CMN parameter from file. If the number of MFCC dimension in the * file does not match the specified one, an error will occur. + * + * Format can be either HTK ascii format or binary format (made by Julius older than ver.4.2.3) * * @param c [i/o] CMN calculation work area * @param filename [in] file name @@ -523,37 +505,126 @@ { FILE *fp; int veclen; + char ch[5]; + char *buf; - jlog("Stat: wav2mfcc-pipe: reading initial CMN from file \"%s\"\n", filename); + jlog("Stat: wav2mfcc-pipe: reading initial cepstral mean/variance from file \"%s\"\n", filename); if ((fp = fopen_readfile(filename)) == NULL) { - jlog("Error: wav2mfcc-pipe: failed to open\n"); + jlog("Error: wav2mfcc-pipe: failed to open %s\n", filename); return(FALSE); } - /* read header */ - if (myread(&veclen, sizeof(int), 1, fp) == FALSE) { - jlog("Error: wav2mfcc-pipe: failed to read header\n"); - fclose_readfile(fp); - return(FALSE); - } - /* check length */ - if (veclen != c->veclen) { - jlog("Error: wav2mfcc-pipe: cepstral dimension mismatch\n"); - jlog("Error: wav2mfcc-pipe: process = %d, file = %d\n", c->veclen, veclen); - fclose_readfile(fp); - return(FALSE); - } - /* read body */ - if (myread(c->cmean_init, sizeof(float), c->veclen, fp) == FALSE) { - jlog("Error: wav2mfcc-pipe: failed to read mean for CMN\n"); + + /* detect file format */ + if (myread(&ch, sizeof(char), 5, fp) == FALSE) { + jlog("Error: wav2mfcc-pipe: failed to read CMN/CVN file\n"); fclose_readfile(fp); return(FALSE); } - if (c->var) { - if (myread(c->cvar_init, sizeof(float), c->veclen, fp) == FALSE) { - jlog("Error: wav2mfcc-pipe: failed to read variance for CVN\n"); + + myfrewind(fp); + if (ch[0] == '<' && + (ch[1] == 'C' || ch[1] == 'c') && + (ch[2] == 'E' || ch[2] == 'e') && + (ch[3] == 'P' || ch[3] == 'p') && + (ch[4] == 'S' || ch[4] == 's') ) { + /* ascii HTK format (>=4.3) */ + char *p; + int mode; + int d, dv, len; + + jlog("Stat: wav2mfcc-pipe: reading HTK-format cepstral vectors\n"); + buf = (char *)mymalloc(MAXLINELEN); + mode = 0; + while(getl(buf, MAXLINELEN, fp) != NULL) { + for (p = mystrtok_quote(buf, "<> \t\r\n"); p; p = mystrtok_quote(NULL, "<> \t\r\n")) { + switch(mode){ + case 0: + if (strmatch(p, "MEAN")) { + mode = 1; + } else if (strmatch(p, "VARIANCE")) { + mode = 3; + } + break; + case 1: + len = atof(p); + if (len != c->veclen) { + jlog("Error: wav2mfcc-pipe: cepstral dimension mismatch\n"); + jlog("Error: wav2mfcc-pipe: process = %d, file = %d\n", c->veclen, len); + free(buf); fclose_readfile(fp); + return(FALSE); + } + d = 0; + mode = 2; + break; + case 2: + if (strmatch(p, "VARIANCE")) { + mode = 3; + } else { + if (d >= len) { + jlog("Error: wav2mfcc-pipe: corrupted data\n"); + free(buf); fclose_readfile(fp); + return(FALSE); + } + c->cmean_init[d++] = atof(p); + } + break; + case 3: + len = atof(p); + if (len != c->veclen) { + jlog("Error: wav2mfcc-pipe: cepstral dimension mismatch\n"); + jlog("Error: wav2mfcc-pipe: process = %d, file = %d\n", c->veclen, len); + free(buf); fclose_readfile(fp); + return(FALSE); + } + dv = 0; + mode = 4; + break; + case 4: + if (dv >= len) { + jlog("Error: wav2mfcc-pipe: corrupted data\n"); + free(buf); fclose_readfile(fp); + return(FALSE); + } + c->cvar_init[dv++] = atof(p); + break; + } + } + } + free(buf); + if (d != len || (mode >= 3 && dv != len)) { + jlog("Error: wav2mfcc-pipe: corrupted data\n"); + fclose_readfile(fp); + return(FALSE); + } + } else { + /* binary (<4.3) */ + jlog("Stat: wav2mfcc-pipe: reading binary-format cepstral vectors\n"); + /* read header */ + if (myread(&veclen, sizeof(int), 1, fp) == FALSE) { + jlog("Error: wav2mfcc-pipe: failed to read header\n"); fclose_readfile(fp); return(FALSE); } + /* check length */ + if (veclen != c->veclen) { + jlog("Error: wav2mfcc-pipe: cepstral dimension mismatch\n"); + jlog("Error: wav2mfcc-pipe: process = %d, file = %d\n", c->veclen, veclen); + fclose_readfile(fp); + return(FALSE); + } + /* read body */ + if (myread(c->cmean_init, sizeof(float), c->veclen, fp) == FALSE) { + jlog("Error: wav2mfcc-pipe: failed to read mean for CMN\n"); + fclose_readfile(fp); + return(FALSE); + } + if (c->var) { + if (myread(c->cvar_init, sizeof(float), c->veclen, fp) == FALSE) { + jlog("Error: wav2mfcc-pipe: failed to read variance for CVN\n"); + fclose_readfile(fp); + return(FALSE); + } + } } if (fclose_readfile(fp) == -1) { @@ -562,7 +633,8 @@ } c->cmean_init_set = TRUE; - jlog("Stat: wav2mfcc-pipe: read CMN parameter\n"); + c->loaded_from_file = TRUE; + jlog("Stat: wav2mfcc-pipe: finished reading CMN/CVN parameter\n"); return(TRUE); } @@ -578,41 +650,35 @@ boolean CMN_save_to_file(CMNWork *c, char *filename) { - int fd; + FILE *fp; + int d; - jlog("Stat: wav2mfcc-pipe: writing current cepstral data to file \"%s\"\n", filename); + /* save in HTK ascii format */ - if ((fd = open(filename, O_CREAT | O_RDWR -#ifdef O_BINARY - | O_BINARY -#endif - , 0644)) == -1) { + /* open file for writing */ + if ((fp = fopen_writefile(filename)) == NULL) { jlog("Error: wav2mfcc-pipe: failed to open \"%s\" to write current cepstral data\n", filename); return(FALSE); } - /* write header */ - if (mywrite(&(c->veclen), sizeof(int), 1, fd) == FALSE) { - jlog("Error: wav2mfcc-pipe: cannot write header to \"%s\" as current cepstral data\n", filename); - close(fd); - return(FALSE); - } - /* write body */ - if (mywrite(c->cmean_init, sizeof(float), c->veclen, fd) == FALSE) { - jlog("Error: wav2mfcc-pipe: cannot write mean to \"%s\" as current cepstral data\n", filename); - close(fd); - return(FALSE); + + fprintf(fp, " <>\n"); + fprintf(fp, " %d\n", c->veclen); + for(d=0;dveclen;d++) { + fprintf(fp, " %e", c->cmean_init[d]); } if (c->var) { - if (mywrite(c->cvar_init, sizeof(float), c->veclen, fd) == FALSE) { - jlog("Error: wav2mfcc-pipe: cannot write variance to \"%s\" as current cepstrum\n", filename); - close(fd); - return(FALSE); + fprintf(fp, "\n %d\n", c->veclen); + for(d=0;dveclen;d++) { + fprintf(fp, " %e", c->cvar_init[d]); } } + fprintf(fp, "\n"); - close(fd); + fclose_writefile(fp); - jlog("Stat: wav2mfcc-pipe: current cepstral data written to \"%s\"\n", filename); + jlog("Stat: wav2mfcc-pipe: cepstral mean"); + if (c->var) jlog(" and variance"); + jlog(" written to \"%s\"\n", filename); return(TRUE); } From sumomo @ users.sourceforge.jp Thu Dec 5 14:41:04 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Thu, 05 Dec 2013 14:41:04 +0900 Subject: [Julius-cvs 871] CVS update: julius4/libjulius/src Message-ID: <1386222064.802864.18312.nullmailer@users.sourceforge.jp> Index: julius4/libjulius/src/m_info.c diff -u julius4/libjulius/src/m_info.c:1.21 julius4/libjulius/src/m_info.c:1.22 --- julius4/libjulius/src/m_info.c:1.21 Thu Dec 5 12:43:13 2013 +++ julius4/libjulius/src/m_info.c Thu Dec 5 14:41:04 2013 @@ -12,7 +12,7 @@ * @author Akinobu Lee * @date Thu May 12 14:14:01 2005 * - * $Revision: 1.21 $ + * $Revision: 1.22 $ * */ /* @@ -945,11 +945,12 @@ jlog("----------------------- System Information end -----------------------\n"); jlog("\n"); - for(mfcc=recog->mfcclist; mfcc; mfcc=mfcc->next) { + if (jconf->input.type == INPUT_WAVEFORM) { - if (jconf->decodeopt.realtime_flag) { + if (jconf->decodeopt.realtime_flag) { - /* warning for real-time decoding */ + /* warning for real-time decoding */ + for(mfcc=recog->mfcclist; mfcc; mfcc=mfcc->next) { if (mfcc->para->cmn || mfcc->para->cvn) { jlog("Notice for feature extraction (%02d),\n", mfcc->id); jlog("\t*************************************************************\n"); @@ -997,10 +998,12 @@ jlog("\t* So, the first input will not be recognized. *\n"); jlog("\t*************************************************************\n"); } + } - } else { + } else { - /* warning for batch decoding */ + /* warning for batch decoding */ + for(mfcc=recog->mfcclist; mfcc; mfcc=mfcc->next) { if (mfcc->para->cmn || mfcc->para->cvn) { jlog("Notice for feature extraction (%02d),\n", mfcc->id); jlog("\t*************************************************************\n"); @@ -1032,10 +1035,12 @@ } jlog("\t*************************************************************\n"); } - } + } + } + } /* end of file */ Index: julius4/libjulius/src/plugin.c diff -u julius4/libjulius/src/plugin.c:1.8 julius4/libjulius/src/plugin.c:1.9 --- julius4/libjulius/src/plugin.c:1.8 Fri Jun 21 02:14:20 2013 +++ julius4/libjulius/src/plugin.c Thu Dec 5 14:41:04 2013 @@ -12,7 +12,7 @@ * @author Akinobu Lee * @date Sat Aug 2 09:46:09 2008 * - * $Revision: 1.8 $ + * $Revision: 1.9 $ * */ /* @@ -81,6 +81,8 @@ PLUGIN_ENTRY *p, *ptmp; int i, num; + if (global_plugin_list == NULL) return; + num = plugin_namelist_num(); for(i=0;inext) { func = (FUNC_VOID) p->func; (*func)(buf, (int)64); @@ -355,6 +360,8 @@ PLUGIN_ENTRY *p; FUNC_VOID func; + if (global_plugin_list == NULL) return NULL; + if ((id = plugin_get_id(name)) < 0) return NULL; for(p=global_plugin_list[id];p;p=p->next) { From sumomo @ users.sourceforge.jp Wed Dec 18 12:55:20 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Wed, 18 Dec 2013 12:55:20 +0900 Subject: [Julius-cvs 872] CVS update: julius4/adintool Message-ID: <1387338920.643403.10174.nullmailer@users.sourceforge.jp> Index: julius4/adintool/adintool.c diff -u julius4/adintool/adintool.c:1.17 julius4/adintool/adintool.c:1.18 --- julius4/adintool/adintool.c:1.17 Fri Jun 21 02:14:17 2013 +++ julius4/adintool/adintool.c Wed Dec 18 12:55:20 2013 @@ -35,7 +35,7 @@ * @author Akinobu LEE * @date Wed Mar 23 20:43:32 2005 * - * $Revision: 1.17 $ + * $Revision: 1.18 $ * */ /* @@ -55,7 +55,7 @@ static int sfreq; ///< Temporal storage of sample rate /* output */ -enum{SPOUT_FILE, SPOUT_STDOUT, SPOUT_ADINNET}; ///< value for speech_output +enum{SPOUT_FILE, SPOUT_STDOUT, SPOUT_ADINNET, SPOUT_VECTORNET}; ///< value for speech_output static int speech_output = SPOUT_FILE; ///< output device static int total_speechlen; ///< total samples of recorded segments static int speechlen; ///< samples of one recorded segments @@ -65,6 +65,8 @@ static int size; ///< Output file size static boolean use_raw = FALSE; ///< Output in RAW format if TRUE static boolean continuous_segment = TRUE; ///< enable/disable successive output +static short vecnet_paramtype = F_ERR_INVALID; ///< output parameter type +static int vecnet_veclen = 0; ///< output vector dimension static int startid = 0; ///< output file numbering variable static int sid = 0; ///< current file ID (for SPOUT_FILE) static char *outpath = NULL; ///< work space for output file name formatting @@ -106,6 +108,7 @@ fprintf(stderr, "outputdev: output data to:\n"); fprintf(stderr, " file speech file (\"foo.0000.wav\" - \"foo.N.wav\"\n"); fprintf(stderr, " adinnet to adinnet server (I'm client)\n"); + fprintf(stderr, " vecnet to vecnet server as feature vector (I'm client)\n"); fprintf(stderr, " stdout standard tty output\n"); fprintf(stderr, "I/O options:\n"); @@ -118,6 +121,10 @@ fprintf(stderr, " -filename foo (file-out) filename to record\n"); fprintf(stderr, " -startid id (file-out) recording start id (%04d)\n", startid); + fprintf(stderr, "Feature extraction options (other than in jconf):\n"); + fprintf(stderr, " -paramtype desc parameter type in HTK format\n"); + fprintf(stderr, " -veclen num total vector length\n"); + fprintf(stderr, "Recording and Pause segmentation options:\n"); fprintf(stderr, " (input segmentation: on for file/mic/stdin, off for adinnet)\n"); @@ -201,6 +208,9 @@ case 'a': speech_output = SPOUT_ADINNET; break; + case 'v': + speech_output = SPOUT_VECTORNET; + break; default: fprintf(stderr,"Error: no such output device: %s\n", arg[0]); return FALSE; @@ -211,7 +221,7 @@ opt_server(Jconf *jconf, char *arg[], int argnum) { char *p, *q; - if (speech_output == SPOUT_ADINNET) { + if (speech_output == SPOUT_ADINNET || speech_output == SPOUT_VECTORNET) { p = (char *)malloc(strlen(arg[0]) + 1); strcpy(p, arg[0]); for (q = strtok(p, ","); q; q = strtok(NULL, ",")) { @@ -225,7 +235,7 @@ } free(p); } else { - fprintf(stderr, "Warning: server [%s] should be with adinnet\n", arg[0]); + fprintf(stderr, "Warning: server [%s] should be used with adinnet / vecnet\n", arg[0]); return FALSE; } return TRUE; @@ -278,6 +288,24 @@ return TRUE; } static boolean +opt_paramtype(Jconf *jconf, char *arg[], int argnum) +{ + short code; + + vecnet_paramtype = param_str2code(arg[0]); + + return TRUE; +} +static boolean +opt_veclen(Jconf *jconf, char *arg[], int argnum) +{ + short code; + + vecnet_veclen = atoi(arg[0]); + + return TRUE; +} +static boolean opt_startid(Jconf *jconf, char *arg[], int argnum) { startid = atoi(arg[0]); @@ -349,9 +377,9 @@ int i; Jconf *jconf = recog->jconf; - fprintf(stderr,"----\n"); - fprintf(stderr, "Input stream:\n"); - fprintf(stderr, "\t input type = "); + fprintf(stderr, "----------------------------------------\n"); + fprintf(stderr, "INPUT\n"); + fprintf(stderr, "\t InputType: "); switch(jconf->input.type) { case INPUT_WAVEFORM: fprintf(stderr, "waveform\n"); @@ -360,13 +388,15 @@ fprintf(stderr, "feature vector sequence\n"); break; } - fprintf(stderr, "\t input source = "); + fprintf(stderr, "\t InputSource: "); if (jconf->input.plugin_source != -1) { fprintf(stderr, "plugin\n"); } else if (jconf->input.speech_input == SP_RAWFILE) { fprintf(stderr, "waveform file\n"); } else if (jconf->input.speech_input == SP_MFCFILE) { fprintf(stderr, "feature vector file (HTK format)\n"); + } else if (jconf->input.speech_input == SP_OUTPROBFILE) { + fprintf(stderr, "output probability file (HTK format)\n"); } else if (jconf->input.speech_input == SP_STDIN) { fprintf(stderr, "standard input\n"); } else if (jconf->input.speech_input == SP_ADINNET) { @@ -385,7 +415,7 @@ #endif } else if (jconf->input.speech_input == SP_MIC) { fprintf(stderr, "microphone\n"); - fprintf(stderr, "\t device API = "); + fprintf(stderr, "\t DeviceAPI: "); switch(jconf->input.device) { case SP_INPUT_DEFAULT: fprintf(stderr, "default\n"); break; case SP_INPUT_ALSA: fprintf(stderr, "alsa\n"); break; @@ -395,7 +425,7 @@ } } - fprintf(stderr,"Segmentation: "); + fprintf(stderr, "\tSegmentation: "); if (jconf->detect.silence_cut) { if (continuous_segment) { fprintf(stderr,"on, continuous\n"); @@ -403,45 +433,48 @@ fprintf(stderr,"on, only one snapshot\n"); } if (recog->adin->down_sample) { - fprintf(stderr," SampleRate: 48000Hz -> %d Hz\n", sfreq); + fprintf(stderr, "\t SampleRate: 48000Hz -> %d Hz\n", sfreq); } else { - fprintf(stderr," SampleRate: %d Hz\n", sfreq); + fprintf(stderr, "\t SampleRate: %d Hz\n", sfreq); } - fprintf(stderr," Level: %d / 32767\n", jconf->detect.level_thres); - fprintf(stderr," ZeroCross: %d per sec.\n", jconf->detect.zero_cross_num); - fprintf(stderr," HeadMargin: %d msec.\n", jconf->detect.head_margin_msec); - fprintf(stderr," TailMargin: %d msec.\n", jconf->detect.tail_margin_msec); + fprintf(stderr, "\t Level: %d / 32767\n", jconf->detect.level_thres); + fprintf(stderr, "\t ZeroCross: %d per sec.\n", jconf->detect.zero_cross_num); + fprintf(stderr, "\t HeadMargin: %d msec.\n", jconf->detect.head_margin_msec); + fprintf(stderr, "\t TailMargin: %d msec.\n", jconf->detect.tail_margin_msec); } else { fprintf(stderr,"OFF\n"); } if (jconf->preprocess.strip_zero_sample) { - fprintf(stderr," ZeroFrames: drop\n"); + fprintf(stderr, "\t ZeroFrames: drop\n"); } else { - fprintf(stderr," ZeroFrames: keep\n"); + fprintf(stderr, "\t ZeroFrames: keep\n"); } if (jconf->preprocess.use_zmean) { - fprintf(stderr," remove DC: on\n"); + fprintf(stderr, "\t DCRemoval: on\n"); } else { - fprintf(stderr," remove DC: off\n"); + fprintf(stderr, "\t DCRemoval: off\n"); } if (pause_each) { - fprintf(stderr," Autopause: on\n"); + fprintf(stderr, "\t AutoPause: on\n"); } else { - fprintf(stderr," Autopause: off\n"); + fprintf(stderr, "\t Auto`ause: off\n"); } if (loose_sync) { - fprintf(stderr," LooseSync: on\n"); + fprintf(stderr, "\t LooseSync: on\n"); } else { - fprintf(stderr," LooseSync: off\n"); + fprintf(stderr, "\t LooseSync: off\n"); } if (rewind_msec > 0) { - fprintf(stderr," Rewind: %d msec\n", rewind_msec); + fprintf(stderr, "\t Rewind: %d msec\n", rewind_msec); } else { - fprintf(stderr," Rewind: no\n"); + fprintf(stderr, "\t Rewind: no\n"); } - fprintf(stderr," Output to: "); + fprintf(stderr, "OUTPUT\n"); switch(speech_output) { case SPOUT_FILE: + fprintf(stderr, "\t OutputType: waveform\n"); + fprintf(stderr, "\t OutputTo: file\n"); + fprintf(stderr, "\t FileName: "); if (jconf->detect.silence_cut) { if (continuous_segment) { if (use_raw) { @@ -457,18 +490,48 @@ } break; case SPOUT_STDOUT: - fprintf(stderr,"STDOUT\n"); + fprintf(stderr, "\t OutputType: waveform\n"); + fprintf(stderr, "\t OutputTo: standard output\n"); use_raw = TRUE; break; case SPOUT_ADINNET: - fprintf(stderr, "adinnet server"); + fprintf(stderr, "\t OutputType: waveform\n"); + fprintf(stderr, "\t OutputTo: adinnet server\n"); + fprintf(stderr, "\t SendTo:"); + for(i=0;imfcclist; mfcc; mfcc = mfcc->next) { + fprintf(stderr, "[MFCC%02d]\n", mfcc->id); + print_mfcc_info(stderr, mfcc, recog->jconf); + } + fprintf(stderr, "----------------------------------------\n"); + } + } static char * @@ -707,6 +770,251 @@ return(0); } +boolean +vecnet_init(Recog *recog) +{ + Jconf *jconf = recog->jconf; + JCONF_AM *amconf = jconf->am_root; + MFCCCalc *mfcc; + PROCESS_AM *am; + + am = j_process_am_new(recog, amconf); + calc_para_from_header(&(jconf->am_root->analysis.para), vecnet_paramtype, vecnet_veclen); + + /* from j_final_fusion() */ + if (recog->jconf->input.type == INPUT_WAVEFORM) { + create_mfcc_calc_instances(recog); + } + for(mfcc=recog->mfcclist;mfcc;mfcc=mfcc->next) { + mfcc->param = new_param(); + } + if (recog->jconf->input.type == INPUT_WAVEFORM) { + for(mfcc=recog->mfcclist;mfcc;mfcc=mfcc->next) { + if (mfcc->frontend.sscalc) { + mfcc->frontend.mfccwrk_ss = WMP_work_new(mfcc->para); + if (mfcc->frontend.mfccwrk_ss == NULL) { + return FALSE; + } + if (mfcc->frontend.sscalc_len * recog->jconf->input.sfreq / 1000 < mfcc->para->framesize) { + return FALSE; + } + } + } + } + if (recog->jconf->input.type == INPUT_WAVEFORM) { + if (RealTimeInit(recog) == FALSE) { + return FALSE; + } + } +} + +int vecnet_send_data(int sd, void *buf, int bytes) +{ + /* send data size header (4 byte) */ + if (send(sd, &bytes, sizeof(int), 0) != sizeof(int)) { + fprintf(stderr, "Error: failed to send %lu bytes\n", sizeof(int)); + return -1; + } + + /* send data body */ + if (send(sd, buf, bytes, 0) != bytes) { + fprintf(stderr, "Error: failed to send %lu bytes\n", sizeof(int)); + return -1; + } + + return 0; +} + +typedef struct { + int veclen; ///< (4 byte)Vector length of an input + int fshift; ///< (4 byte) Frame shift in msec of the vector + char outprob_p; ///< (1 byte) != 0 if input is outprob vector +} ConfigurationHeader; + +void +vecnet_send_header(Recog *recog) +{ + ConfigurationHeader conf; + int i; + + conf.veclen = recog->jconf->am_root->analysis.para.veclen; + conf.fshift = 1000.0 * recog->jconf->am_root->analysis.para.frameshift / recog->jconf->am_root->analysis.para.smp_freq; + conf.outprob_p = 0; /* feature output */ + for (i=0;ireal); + MFCCCalc *mfcc; + + r->windownum = 0; + for(mfcc = recog->mfcclist; mfcc; mfcc = mfcc->next) { + mfcc->param->veclen = vecnet_veclen; + if (mfcc->para->cmn || mfcc->para->cvn) CMN_realtime_prepare(mfcc->cmn.wrk); + param_alloc(mfcc->param, 1, mfcc->param->veclen); + mfcc->f = 0; + } + if (recog->jconf->input.type == INPUT_WAVEFORM) { + reset_mfcc(recog); + } + recog->triggered = FALSE; + + return TRUE; + +} + +void +vecnet_sub(SP16 *Speech, int nowlen, Recog *recog) +{ + int i, j, k, now, ret; + MFCCCalc *mfcc; + RealBeam *r = &(recog->real); + + now = 0; + + while (now < nowlen) { + for(i = min(r->windowlen - r->windownum, nowlen - now); i > 0 ; i--) + r->window[r->windownum++] = (float) Speech[now++]; + if (r->windownum < r->windowlen) break; + for (mfcc = recog->mfcclist; mfcc; mfcc = mfcc->next) { + mfcc->valid = FALSE; + if (RealTimeMFCC(mfcc, r->window, r->windowlen)) { + mfcc->valid = TRUE; + param_alloc(mfcc->param, mfcc->f + 1, mfcc->param->veclen); + memcpy(mfcc->param->parvec[mfcc->f], mfcc->tmpmfcc, sizeof(VECT) * mfcc->param->veclen); + { + int i; + for (i = 0; i < vecnet_veclen; i++) { + printf(" %f", mfcc->tmpmfcc[i]); + } + printf("\n"); + } + /* send 1 frame */ + for (j=0;jtmpmfcc, sizeof(VECT) * vecnet_veclen); + } + } + mfcc->f++; + } + /* shift window */ + memmove(r->window, &(r->window[recog->jconf->input.frameshift]), sizeof(SP16) * (r->windowlen - recog->jconf->input.frameshift)); + r->windownum -= recog->jconf->input.frameshift; + } +} + +void +vecnet_param_update(Recog *recog) +{ + MFCCCalc *mfcc; + + for (mfcc = recog->mfcclist; mfcc; mfcc = mfcc->next) { + mfcc->param->header.samplenum = mfcc->f; + mfcc->param->samplenum = mfcc->f; + } + if (recog->jconf->input.type == INPUT_WAVEFORM) { + for(mfcc=recog->mfcclist;mfcc;mfcc=mfcc->next) { + if (mfcc->f > 0 && mfcc->para && mfcc->para->cmn) { + if (mfcc->cmn.update) { + CMN_realtime_update(mfcc->cmn.wrk, mfcc->param); + } + if (mfcc->cmn.save_filename) { + CMN_save_to_file(mfcc->cmn.wrk, mfcc->cmn.save_filename); + } + } + } + } +} + + +static int +adin_callback_vecnet(SP16 *now, int len, Recog *recog) +{ + int count; + int start, w; + int i; + + start = 0; + + if (recog->jconf->input.speech_input == SP_MIC && speechlen == 0) { + /* this is first up-trigger */ + if (rewind_msec > 0 && !recog->adin->is_valid_data) { + /* not spoken currently but has data to process at first trigger */ + /* it means that there are old spoken segments */ + /* disgard them */ + printf("disgard already recorded %d samples\n", len); + return 0; + } + /* erase "<<>>" text on tty */ + fprintf(stderr, "\r \r"); + if (rewind_msec > 0) { + /* when -rewind value set larger than 0, the speech data spoken + while pause will be considered back to the specified msec. + */ + printf("buffered samples=%d\n", len); + w = rewind_msec * sfreq / 1000; + if (len > w) { + start = len - w; + len = w; + } else { + start = 0; + } + printf("will process from %d\n", start); + } + } + + vecnet_sub(&(now[start]), len, recog); + + /* accumulate sample num of this segment */ + speechlen += len; +#ifdef HAVE_PTHREAD + if (recog->adin->enable_thread) { + /* if input length reaches limit, rehash the ad-in buffer */ + if (recog->adin->speechlen > MAXSPEECHLEN - 16000) { + recog->adin->rehash = TRUE; + fprintf(stderr, "+"); + } + } +#endif + + /* display progress in dots */ + fprintf(stderr, "."); + return(0); +} + +static void +vecnet_send_end_of_segment() +{ + int i, j; + + /* send header value of '0' as an end-of-utterance marker */ + i = 0; + for (j=0;j @@ -965,6 +1273,9 @@ /* close files */ close_files(); } + if (speech_output == SPOUT_VECTORNET) { + vecnet_send_end_of_session(); + } /* terminate program */ exit(1); } @@ -1018,6 +1329,8 @@ j_add_option("-port", 1, 1, "port number (-out adinnet)", opt_port); j_add_option("-inport", 1, 1, "port number (-in adinnet)", opt_inport); j_add_option("-filename", 1, 1, "(base) filename to record (-out file)", opt_filename); + j_add_option("-paramtype", 1, 1, "feature parameter type in HTK format", opt_paramtype); + j_add_option("-veclen", 1, 1, "feature parameter vector length", opt_veclen); j_add_option("-startid", 1, 1, "recording start id (-out file)", opt_startid); j_add_option("-freq", 1, 1, "sampling frequency in Hz", opt_freq); j_add_option("-nosegment", 0, 0, "not segment input speech, record all", opt_nosegment); @@ -1048,12 +1361,12 @@ fprintf(stderr, "Error: output filename not specified\n"); return(-1); } - if (speech_output == SPOUT_ADINNET && adinnet_servnum < 1) { - fprintf(stderr, "Error: adinnet server name for output not specified\n"); + if ((speech_output == SPOUT_ADINNET || speech_output == SPOUT_VECTORNET) && adinnet_servnum < 1) { + fprintf(stderr, "Error: server name for output not specified\n"); return(-1); } if (jconf->input.speech_input == SP_ADINNET && - speech_output != SPOUT_ADINNET && + speech_output != SPOUT_ADINNET && speech_output != SPOUT_VECTORNET && adinnet_servnum >= 1) { fprintf(stderr, "Warning: you specified port num by -port, but it's for output\n"); fprintf(stderr, "Warning: you may specify input port by -inport instead.\n"); @@ -1068,7 +1381,11 @@ if (adinnet_portnum != adinnet_servnum) { /* if only one server, use default */ if (adinnet_servnum == 1) { - adinnet_port[0] = ADINNET_PORT; + if (speech_output == SPOUT_ADINNET) { + adinnet_port[0] = ADINNET_PORT; + } else if (speech_output == SPOUT_VECTORNET) { + adinnet_port[0] = VECINNET_PORT; + } adinnet_portnum = 1; } else { fprintf(stderr, "Error: you should specify both server names and different port for each!\n"); @@ -1081,7 +1398,17 @@ } } + if (speech_output == SPOUT_VECTORNET) { + if (vecnet_paramtype == F_ERR_INVALID || vecnet_veclen == 0) { + fprintf(stderr, "Error: with \"-out vecnet\", \"-paramtype\" and \"-veclen\" is required\n"); + return -1; + } + } + /* set Julius default parameters for unspecified acoustic parameters */ + if (jconf->am_root->analysis.para_htk.loaded == 1) { + apply_para(&(jconf->am_root->analysis.para), &(jconf->am_root->analysis.para_htk)); + } apply_para(&(jconf->am_root->analysis.para), &(jconf->am_root->analysis.para_default)); /* set some values */ @@ -1090,6 +1417,10 @@ jconf->input.frameshift = jconf->am_root->analysis.para.frameshift; jconf->input.framesize = jconf->am_root->analysis.para.framesize; + if (speech_output == SPOUT_VECTORNET) { + if (vecnet_init(recog) == FALSE) exit(1); + } + /* disable successive segmentation when no segmentation available */ if (!jconf->detect.silence_cut) continuous_segment = FALSE; /* store sampling rate locally */ @@ -1109,7 +1440,17 @@ outpath = new_output_filename(filename, ".wav"); } } - } else if (speech_output == SPOUT_ADINNET) { + } + + /**************************************/ + /* display input/output configuration */ + /**************************************/ + put_status(recog); + + /*********************/ + /* connect to server */ + /*********************/ + if (speech_output == SPOUT_ADINNET || speech_output == SPOUT_VECTORNET) { /* connect to adinnet server(s) */ for(i=0;i 0) { + if (ret >= 0 || stop_at_next) { /* segmented by adin-cut or end of stream or server-side command */ + /* send end-of-segment ack to client */ + vecnet_send_end_of_segment(); + vecnet_param_update(recog); + } + /* output info */ + printf("sent: %d samples (%.2f sec.) [%6d (%5.2fs) - %6d (%5.2fs)]\n", + speechlen, (float)speechlen / (float)sfreq, + trigger_sample, (float)trigger_sample / (float)sfreq, + trigger_sample + speechlen, (float)(trigger_sample + speechlen) / (float)sfreq); + } } /*************************************/ @@ -1295,14 +1653,14 @@ if (pause_each) { /* pause at each end */ //if (speech_output == SPOUT_ADINNET && speechlen > 0) { - if (speech_output == SPOUT_ADINNET) { + if (speech_output == SPOUT_ADINNET || speech_output == SPOUT_VECTORNET) { if (adinnet_wait_command() < 0) { /* command error: terminate program here */ return 1; } } } else { - if (speech_output == SPOUT_ADINNET && stop_at_next) { + if ((speech_output == SPOUT_ADINNET || speech_output == SPOUT_VECTORNET) && stop_at_next) { if (adinnet_wait_command() < 0) { /* command error: terminate program here */ return 1; @@ -1333,5 +1691,10 @@ } } + if (speech_output == SPOUT_VECTORNET) { + vecnet_send_end_of_session(); + vecnet_param_update(recog); + } + return 0; } From sumomo @ users.sourceforge.jp Wed Dec 18 12:55:21 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Wed, 18 Dec 2013 12:55:21 +0900 Subject: [Julius-cvs 873] CVS update: julius4/libsent/include/sent Message-ID: <1387338921.280746.10278.nullmailer@users.sourceforge.jp> Index: julius4/libsent/include/sent/adin.h diff -u julius4/libsent/include/sent/adin.h:1.14 julius4/libsent/include/sent/adin.h:1.15 --- julius4/libsent/include/sent/adin.h:1.14 Wed Dec 4 19:13:00 2013 +++ julius4/libsent/include/sent/adin.h Wed Dec 18 12:55:21 2013 @@ -19,7 +19,7 @@ * @author Akinobu LEE * @date Thu Feb 10 17:22:36 2005 * - * $Revision: 1.14 $ + * $Revision: 1.15 $ */ /* * Copyright (c) 1991-2013 Kawahara Lab., Kyoto University @@ -48,7 +48,8 @@ SP_MFCFILE, ///< HTK parameter file SP_NETAUDIO, ///< Live NetAudio/DatLink input SP_STDIN, ///< Standard input - SP_MFCMODULE ///< parameter module + SP_MFCMODULE, ///< parameter module + SP_OUTPROBFILE }; /// Input device Index: julius4/libsent/include/sent/hmm.h diff -u julius4/libsent/include/sent/hmm.h:1.6 julius4/libsent/include/sent/hmm.h:1.7 --- julius4/libsent/include/sent/hmm.h:1.6 Fri Jun 21 02:14:20 2013 +++ julius4/libsent/include/sent/hmm.h Wed Dec 18 12:55:21 2013 @@ -21,7 +21,7 @@ * @author Akinobu LEE * @date Thu Feb 10 14:54:06 2005 * - * $Revision: 1.6 $ + * $Revision: 1.7 $ * */ /* @@ -111,6 +111,7 @@ /* hmminfo/outprob.c */ LOGPROB outprob(HMMWork *wrk, int t, HMM_STATE *hmmstate, HTK_Param *param); + /* hmminfo/put_htkdata_info */ void put_hmm_arc(FILE *fp, HMM *d); void put_hmm_outprob(FILE *fp, HMM *d); Index: julius4/libsent/include/sent/hmm_calc.h diff -u julius4/libsent/include/sent/hmm_calc.h:1.10 julius4/libsent/include/sent/hmm_calc.h:1.11 --- julius4/libsent/include/sent/hmm_calc.h:1.10 Fri Jun 21 02:14:20 2013 +++ julius4/libsent/include/sent/hmm_calc.h Wed Dec 18 12:55:21 2013 @@ -13,7 +13,7 @@ * @author Akinobu LEE * @date Thu Feb 10 14:54:06 2005 * - * $Revision: 1.10 $ + * $Revision: 1.11 $ * */ /* @@ -154,6 +154,8 @@ /* GMS gprune local cache */ int **gms_last_max_id_list; ///< maximum mixture id of last call for each states + boolean batch_computation; + } HMMWork; @@ -174,6 +176,7 @@ ); boolean outprob_prepare(HMMWork *wrk, int framenum); void outprob_free(HMMWork *wrk); +void outprob_set_batch_computation(HMMWork *wrk, boolean flag); /* outprob.c */ boolean outprob_cache_init(HMMWork *wrk); boolean outprob_cache_prepare(HMMWork *wrk); @@ -182,6 +185,8 @@ void outprob_cd_nbest_init(HMMWork *wrk, int num); void outprob_cd_nbest_free(HMMWork *wrk); LOGPROB outprob_cd(HMMWork *wrk, int t, CD_State_Set *lset, HTK_Param *param); +boolean outprob_cache_output(FILE *fp, HMMWork *wrk, int framenum); + /* gms.c */ boolean gms_init(HMMWork *wrk); boolean gms_prepare(HMMWork *wrk, int framelen); Index: julius4/libsent/include/sent/htk_hmm.h diff -u julius4/libsent/include/sent/htk_hmm.h:1.11 julius4/libsent/include/sent/htk_hmm.h:1.12 --- julius4/libsent/include/sent/htk_hmm.h:1.11 Fri Jun 21 02:14:20 2013 +++ julius4/libsent/include/sent/htk_hmm.h Wed Dec 18 12:55:21 2013 @@ -16,7 +16,7 @@ * @author Akinobu LEE * @date Thu Feb 10 19:36:47 2005 * - * $Revision: 1.11 $ + * $Revision: 1.12 $ * */ /* @@ -40,7 +40,7 @@ #define NoTokErr(S) if (!rdhmmdef_token) rderr(S) /// Delimiter string for parsing %HMM definition file -#define HMMDEF_DELM " \t\n<>" +#define HMMDEF_DELM " \t\r\n<>" /** * @defgroup hmminfo HTK HMM definition @@ -433,6 +433,7 @@ #ifdef ENABLE_MSD void htk_hmm_check_msd(HTK_HMM_INFO *hmm); #endif +boolean htk_hmm_check_sid(HTK_HMM_INFO *hmm); /* rdhmmdef_options.c */ boolean set_global_opt(FILE *fp, HTK_HMM_INFO *hmm); char *get_cov_str(short covtype); Index: julius4/libsent/include/sent/htk_param.h diff -u julius4/libsent/include/sent/htk_param.h:1.6 julius4/libsent/include/sent/htk_param.h:1.7 --- julius4/libsent/include/sent/htk_param.h:1.6 Fri Jun 21 02:14:20 2013 +++ julius4/libsent/include/sent/htk_param.h Wed Dec 18 12:55:21 2013 @@ -48,7 +48,7 @@ * @author Akinobu LEE * @date Fri Feb 11 02:52:52 2005 * - * $Revision: 1.6 $ + * $Revision: 1.7 $ * */ /* @@ -81,6 +81,7 @@ short veclen_alloc; ///< Allocated vector length of a sample unsigned int samplenum_alloc; ///< Alllocated number of samples BMALLOC_BASE *mroot; ///< Pointer for block memory allocation + boolean is_outprob; ///< TRUE if this is outprob vector } HTK_Param; /** Index: julius4/libsent/include/sent/tcpip.h diff -u julius4/libsent/include/sent/tcpip.h:1.6 julius4/libsent/include/sent/tcpip.h:1.7 --- julius4/libsent/include/sent/tcpip.h:1.6 Fri Jun 21 02:14:20 2013 +++ julius4/libsent/include/sent/tcpip.h Wed Dec 18 12:55:21 2013 @@ -11,7 +11,7 @@ * @author Akinobu LEE * @date Sat Feb 12 12:26:15 2005 * - * $Revision: 1.6 $ + * $Revision: 1.7 $ * */ /* @@ -45,6 +45,9 @@ /// Default port number of A/D-in server (adinnet) #define ADINNET_PORT 5530 +/// Default port number of feature server (vecin_net) +#define VECINNET_PORT 5531 + /// Default Host/unit name for NetAudio/DatLink input #define NETAUDIO_DEVNAME "localhost:0" @@ -69,6 +72,17 @@ int close_socket(int sd); void cleanup_socket(); +/* vecin_net.c */ +boolean vecin_standby(); +boolean vecin_open(); +int vecin_get_configuration(int opcode); +int vecin_read(float *vecbuf, int veclen); +boolean vecin_close(); +boolean vecin_terminate(); +boolean vecin_pause(); +boolean vecin_resume(); +char *vecin_input_name(); + #ifdef __cplusplus } #endif From sumomo @ users.sourceforge.jp Wed Dec 18 12:55:20 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Wed, 18 Dec 2013 12:55:20 +0900 Subject: [Julius-cvs 874] CVS update: julius4/julius Message-ID: <1387338920.818592.10195.nullmailer@users.sourceforge.jp> Index: julius4/julius/main.c diff -u julius4/julius/main.c:1.6 julius4/julius/main.c:1.7 --- julius4/julius/main.c:1.6 Fri Jun 21 02:14:18 2013 +++ julius4/julius/main.c Wed Dec 18 12:55:20 2013 @@ -12,7 +12,7 @@ * @author Akinobu Lee * @date Wed May 18 15:02:55 2005 * - * $Revision: 1.6 $ + * $Revision: 1.7 $ * */ /* @@ -178,7 +178,7 @@ /* if -outfile option specified, callbacks for file output will be regitered */ if (outfile_enabled) { - if (jconf->input.speech_input == SP_MFCFILE || jconf->input.speech_input == SP_RAWFILE) { + if (jconf->input.speech_input == SP_MFCFILE || jconf->input.speech_input == SP_RAWFILE || jconf->input.speech_input == SP_OUTPROBFILE) { setup_output_file(recog, NULL); } else { fprintf(stderr, "Warning: -outfile works only for file input, disabled now\n"); Index: julius4/julius/recogloop.c diff -u julius4/julius/recogloop.c:1.6 julius4/julius/recogloop.c:1.7 --- julius4/julius/recogloop.c:1.6 Fri Jun 21 02:14:18 2013 +++ julius4/julius/recogloop.c Wed Dec 18 12:55:20 2013 @@ -12,7 +12,7 @@ * @author Akinobu Lee * @date Sun Sep 02 21:12:52 2007 * - * $Revision: 1.6 $ + * $Revision: 1.7 $ * */ /* @@ -35,13 +35,14 @@ int ret; FILE *mfclist; static char speechfilename[MAXPATHLEN]; /* pathname of speech file or MFCC file */ + char *p; jconf = recog->jconf; /* reset file count */ file_counter = 0; - if (jconf->input.speech_input == SP_MFCFILE) { + if (jconf->input.speech_input == SP_MFCFILE || jconf->input.speech_input == SP_OUTPROBFILE) { if (jconf->input.inputlist_filename != NULL) { /* open filelist for mfc input */ if ((mfclist = fopen(jconf->input.inputlist_filename, "r")) == NULL) { /* open error */ @@ -63,9 +64,16 @@ /*********************/ /* open input stream */ /*********************/ - if (jconf->input.speech_input == SP_MFCFILE) { + if (jconf->input.speech_input == SP_MFCFILE || jconf->input.speech_input == SP_OUTPROBFILE) { /* from MFCC parameter file (in HTK format) */ - VERMES("### read analyzed parameter\n"); + switch(jconf->input.speech_input) { + case SP_MFCFILE: + VERMES("### read analyzed parameter\n"); + break; + case SP_OUTPROBFILE: + VERMES("### read output probabilities\n"); + break; + } if (jconf->input.inputlist_filename != NULL) { /* has filename list */ do { if (getl_fp(speechfilename, MAXPATHLEN, mfclist) == NULL) { @@ -78,7 +86,15 @@ } } while (speechfilename[0] == '\0' || speechfilename[0] == '#'); } else { - if (get_line_from_stdin(speechfilename, MAXPATHLEN, "enter MFCC filename->") == NULL) { + switch(jconf->input.speech_input) { + case SP_MFCFILE: + p = get_line_from_stdin(speechfilename, MAXPATHLEN, "enter MFCC filename->"); + break; + case SP_OUTPROBFILE: + p = get_line_from_stdin(speechfilename, MAXPATHLEN, "enter OUTPROB filename->"); + break; + } + if (p == NULL) { fprintf(stderr, "%d files processed\n", file_counter); #ifdef REPORT_MEMORY_USAGE print_mem(); From sumomo @ users.sourceforge.jp Wed Dec 18 12:55:21 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Wed, 18 Dec 2013 12:55:21 +0900 Subject: [Julius-cvs 875] CVS update: julius4/plugin Message-ID: <1387338921.585539.10324.nullmailer@users.sourceforge.jp> Index: julius4/plugin/fvin.c diff -u julius4/plugin/fvin.c:1.3 julius4/plugin/fvin.c:1.4 --- julius4/plugin/fvin.c:1.3 Sat Nov 14 14:09:44 2009 +++ julius4/plugin/fvin.c Wed Dec 18 12:55:21 2013 @@ -12,7 +12,7 @@ * @author Akinobu Lee * @date Mon Aug 11 17:05:17 2008 * - * $Revision: 1.3 $ + * $Revision: 1.4 $ * */ @@ -184,6 +184,9 @@ * checking the input parameter type against acousitc model, and * you can disable the checking by returning "0xffff" to this opcode. * + * When opcode = 3, should return 0 if the input vector is feature + * vector, and 1 if the input is outprob vector. + * * @param opcode [in] requested operation code * * @return values required for the opcode as described. @@ -204,6 +207,8 @@ * エンコードされた値を返す.型チェックを行わない場合は, * 0xffff を返すこと. * + * opcode =3 のとき特徴量ベクトル入力なら 0, 出力確率ベクトルなら1を返す. + * * @param opcode [in] 要求動作コード (現在 0 のみ実装) * * @return opcode ごとに要求された値を返す. @@ -220,6 +225,8 @@ case 2:/* return parameter type specification in HTK format */ /* return 0xffff to disable checking */ return(0xffff); + case 3:/* return 0 if feature vector input, 1 if outprob vector input */ + return(0); } } From sumomo @ users.sourceforge.jp Wed Dec 18 12:55:20 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Wed, 18 Dec 2013 12:55:20 +0900 Subject: [Julius-cvs 876] CVS update: julius4/julius-simple Message-ID: <1387338920.882660.10203.nullmailer@users.sourceforge.jp> Index: julius4/julius-simple/julius-simple.c diff -u julius4/julius-simple/julius-simple.c:1.4 julius4/julius-simple/julius-simple.c:1.5 --- julius4/julius-simple/julius-simple.c:1.4 Wed Jun 12 18:02:36 2013 +++ julius4/julius-simple/julius-simple.c Wed Dec 18 12:55:20 2013 @@ -23,7 +23,7 @@ * @author Akinobu Lee * @date Tue Dec 11 14:40:04 2007 * - * $Revision: 1.4 $ + * $Revision: 1.5 $ * */ @@ -325,7 +325,7 @@ /* Open input stream and recognize */ /***********************************/ - if (jconf->input.speech_input == SP_MFCFILE) { + if (jconf->input.speech_input == SP_MFCFILE || jconf->input.speech_input == SP_OUTPROBFILE) { /* MFCC file input */ while (get_line_from_stdin(speechfilename, MAXPATHLEN, "enter MFCC filename->") != NULL) { From sumomo @ users.sourceforge.jp Wed Dec 18 12:55:21 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Wed, 18 Dec 2013 12:55:21 +0900 Subject: [Julius-cvs 877] CVS update: julius4/libsent/src/anlz Message-ID: <1387338921.349438.10288.nullmailer@users.sourceforge.jp> Index: julius4/libsent/src/anlz/param_malloc.c diff -u julius4/libsent/src/anlz/param_malloc.c:1.5 julius4/libsent/src/anlz/param_malloc.c:1.6 --- julius4/libsent/src/anlz/param_malloc.c:1.5 Fri Jun 21 02:14:20 2013 +++ julius4/libsent/src/anlz/param_malloc.c Wed Dec 18 12:55:21 2013 @@ -12,7 +12,7 @@ * @author Akinobu Lee * @date Fri Aug 3 14:09:39 2007 * - * $Revision: 1.5 $ + * $Revision: 1.6 $ * */ @@ -125,6 +125,7 @@ new->mroot = NULL; new->parvec = NULL; new->samplenum_alloc = 0; + new->is_outprob = FALSE; param_init_content(new); return(new); } Index: julius4/libsent/src/anlz/vecin_net.c diff -u /dev/null julius4/libsent/src/anlz/vecin_net.c:1.1 --- /dev/null Wed Dec 18 12:55:21 2013 +++ julius4/libsent/src/anlz/vecin_net.c Wed Dec 18 12:55:21 2013 @@ -0,0 +1,396 @@ +/** + * @file vecin_net.c + * + * @brief Feature input from network + * + * + * $Revision: 1.1 $ + * + */ + +/** + * feature input functions + * + * Required: + * - vecin_standby() + * - vecin_open() + * - vecin_get_configuration() + * - vecin_read() + * - vecin_close() + * - vecin_terminate() + * - vecin_pause() + * - vecin_resume() + * - vecin_input_name() + * + */ + +#include +#include + +/// Return code of vecin_read() +#define ADIN_NOERROR 0 +#define ADIN_EOF -1 +#define ADIN_ERROR -2 +#define ADIN_SEGMENT -3 + +/// Return code of local_read_data() +#define LRD_NOERROR 0 +#define LRD_ENDOFSEGMENT 1 +#define LRD_ENDOFSTREAM 2 +#define LRD_ERROR 3 + +static int vecin_sd = -1; ///< Listening socket +static int vecin_asd = -1; ///< Accepted socket + +typedef struct { + int veclen; ///< (4 byte)Vector length of an input + int fshift; ///< (4 byte) Frame shift in msec of the vector + char outprob_p; ///< (1 byte) TRUE if input is outprob vector +} ConfigurationHeader; + +ConfigurationHeader conf; + +/************************************************************************/ +int +local_read_data(int sd, void *buf, int bytes) +{ + int len; + int ret; + int toread, offset; + + /* get header */ + toread = sizeof(int); + offset = 0; + while (toread > 0) { + ret = recv(sd, ((char *)&len) + offset, toread, 0); + if (ret < 0) { + /* error */ + jlog("Error: vecin_net: failed to read length data %d/%d\n", offset, sizeof(int)); + return LRD_ERROR; + } + toread -= ret; + offset += ret; + } + if (len == 0) { + /* end of segment mark */ + return LRD_ENDOFSEGMENT; + } + if (len < 0) { + /* end of input, mark */ + return LRD_ENDOFSTREAM; + } + + if (len != bytes) { + jlog("Error: vecin_net: protocol error: length not match: %d, %d\n", bytes, len); + return LRD_ERROR; + } + + /* get body */ + toread = len; + offset = 0; + while (toread > 0) { + ret = recv(sd, ((char *)buf) + offset, toread, 0); + if (ret < 0) { + /* error */ + jlog("Error: vecin_net: failed to read data: %d / %d\n", offset, len); + return LRD_ERROR; + } + toread -= ret; + offset += ret; + } + + return LRD_NOERROR; +} + + +/************************************************************************/ + +/** + * @brief Initialize input device (required) + * + * This will be called only once at start up of Julius. You can + * check if the input file exists or prepare a socket for connection. + * + * If this function returns FALSE, Julius will exit. + * + * JuliusLib: this function will be called at j_adin_init(). + * + * @return TRUE on success, FALSE on failure. + * + */ +boolean +vecin_standby() +{ + vecin_sd = -1; + vecin_asd = -1; + conf.veclen = 0; + conf.fshift = 0; + conf.outprob_p = FALSE; + + if ((vecin_sd = ready_as_server(VECINNET_PORT)) < 0) { + jlog("Error: vecin_net: cannot listen port %d to be a server\n", VECINNET_PORT); + return FALSE; + } + + jlog("Stat: vecin_net: listening port %d\n", VECINNET_PORT); + + return TRUE; +} + +/** + * @brief Open an input (required) + * + * This function should open a new input. You may open a feature + * vector file, or wait for connection at this function. + * + * If this function returns FALSE, Julius will exit recognition loop. + * + * JuliusLib: this will be called at j_open_stream(). + * + * @return TRUE on success, FALSE on failure. + */ +boolean +vecin_open() +{ + if (vecin_sd == -1) { + jlog("Error: vecin_net: socket not ready\n"); + return FALSE; + } + if (vecin_asd != -1) { + vecin_close(); + } + jlog("Stat: vecin_net: waiting connection...\n"); + if ((vecin_asd = accept_from(vecin_sd)) < 0) { + jlog("Error: vecin_net: failed to accept connection\n"); + return FALSE; + } + jlog("Stat: vecin_net: connected\n"); + + /* receive configuration parameters from client */ + if (local_read_data(vecin_asd, &conf, sizeof(ConfigurationHeader)) != LRD_NOERROR) { + jlog("Error: vecin_net: failed to receive first configuration data\n"); + return FALSE; + } + + return TRUE; +} + +/** + * @brief Return configuration parameters for this input (required) + * + * This function should return configuration parameters about the input. + * + * When opcode = 0, return the dimension (length) of input vector. + * + * When opcode = 1, return the frame interval (time between frames) in + * milliseconds. + * + * When opcode = 2, parameter type code can be returned. The code should + * the same format as used in HTK parameter file header. This is for + * checking the input parameter type against acousitc model, and + * you can disable the checking by returning "0xffff" to this opcode. + * + * When opcode = 3, should return 0 if the input vector is feature + * vector, and 1 if the input is outprob vector. + * + * @param opcode [in] requested operation code + * + * @return values required for the opcode as described. + */ +int +vecin_get_configuration(int opcode) +{ + if (vecin_asd == -1) { + jlog("Error: vecin_net: vecin_get_configuration() called without connection\n"); + return 0; + } + switch(opcode) { + case 0: /* return number of elements in a vector */ + return(conf.veclen); + case 1:/* return msec per frame */ + return(conf.fshift); + case 2:/* return parameter type specification in HTK format */ + /* return 0xffff to disable checking */ + return(0xffff); + case 3:/* return 0 if feature vector input, 1 if outprob vector input */ + return(conf.outprob_p ? 1 : 0); + } +} + +/** + * @brief Read a vector from input (required) + * + * This will be called repeatedly at each frame, and the read vector + * will be processed immediately, and then this function is called again. + * + * Return value of ADIN_EOF tells end of stream to Julius, which + * causes Julius to finish current recognition and close stream. + * ADIN_SEGMENT requests Julius to segment the current input. The + * current recognition will be stopped at this point, recognition + * result will be output, and then Julius continues to the next input. + * The behavior of ADIN_SEGMENT is similar to ADIN_EOF except that + * ADIN_SEGMENT does not close/open input, but just stop and restart + * the recognition. At last, return value should be ADIN_ERROR on + * error, in which Julius exits itself immediately. + * + * @param vecbuf [out] store a vector obtained in this function + * @param veclen [in] vector length + * + * @return 0 on success, ADIN_EOF on end of stream, ADIN_SEGMENT to + * request segmentation to Julius, or ADIN_ERROR on error. + */ +int +vecin_read(float *vecbuf, int veclen) +{ + int ret; + + if (vecin_asd == -1) { + jlog("Error: vecin_net: vecin_read() called without connection\n"); + return ADIN_ERROR; + } + + ret = local_read_data(vecin_asd, vecbuf, sizeof(float) * veclen); + + switch(ret) { + case LRD_ENDOFSEGMENT: /* received an end of segment */ + jlog("Stat: vecin_net: received end of segment\n"); + return ADIN_SEGMENT; + case LRD_ENDOFSTREAM: /* received an end of stream */ + jlog("Stat: vecin_net: received end of stream\n"); + return ADIN_EOF; + case LRD_ERROR: /* some error has occured */ + jlog("Error: vecin_net: error in receiving data\n"); + return ADIN_ERROR; + } + + return(ADIN_NOERROR); /* success */ +} + +/** + * @brief Close the current input (required) + * + * This function will be called when the input has reached end of file + * (i.e. the last call of vecin_read() returns ADIN_EOF) + * + * You may close a file or disconnect network client here. + * + * If this function returns TRUE, Julius will go again to adin_open() + * to open another stream. If returns FALSE, Julius will exit + * the recognition loop. + * + * JuliusLib: This will be called at the end of j_recognize_stream(). + * + * @return TRUE on success, FALSE on failure. + */ +boolean +vecin_close() +{ + if (vecin_asd == -1) return TRUE; + + /* end of connection */ + close_socket(vecin_asd); + vecin_asd = -1; + + jlog("Stat: vecin_net: connection closed\n"); + + return TRUE; +} + +/************************************************************************/ + +/** + * @brief A hook for Termination request (optional) + * + * This function will be called when Julius receives a Termination + * request to stop running. This can be used to synchronize input + * facility with Julius's running status. + * + * Termination will occur when Julius is running on module mode and + * received TERMINATE command from client, or j_request_terminate() + * is called inside application. On termination, Julius will stop + * recognition immediately (discard current input if in process), + * and wait until received RESUME command or call of j_request_resume(). + * + * This hook function will be called just after a Termination request. + * Please note that this will be called when Julius receives request, + * not on actual termination. + * + * @return TRUE on success, FALSE on failure. + * + */ +boolean +vecin_terminate() +{ + printf("terminate request\n"); + return TRUE; +} + +/** + * @brief A hook for Pause request (optional) + * + * This function will be called when Julius receives a Pause request + * to stop running. This can be used to synchronize input facility + * with Julius's running status. + * + * Pause will occur when Julius is running on module mode and + * received PAUSE command from client, or j_request_pause() + * is called inside application. On pausing, Julius will + * stop recognition and then wait until it receives RESUME command + * or j_request_resume() is called. When pausing occurs while recognition is + * running, Julius will process it to the end before stops. + * + * This hook function will be called just after a Pause request. + * Please note that this will be called when Julius receives request, + * not on actual pause. + * + * @return TRUE on success, FALSE on failure. + * + */ +boolean +vecin_pause() +{ + printf("pause request\n"); + return TRUE; +} + +/** + * @brief A hook for Resume request (optional) + * + * This function will be called when Julius received a resume request + * to recover from pause/termination status. + * + * Resume will occur when Julius has been stopped by receiving RESUME + * command from client on module mode, or j_request_resume() is called + * inside application. + * + * This hook function will be called just after a resume request. + * This can be used to make this A/D-in plugin cooperate with the + * pause/resume status, for example to tell audio client to restart + * audio streaming. + * + * This function is totally optional. + * + * @return TRUE on success, FALSE on failure. + * + */ +boolean +vecin_resume() +{ + printf("resume request\n"); + return TRUE; +} + +/** + * @brief A function to return current device name for information (optional) + * + * This function is totally optional. + * + * @return pointer to the device name string + * + */ +char * +vecin_input_name() +{ + return("vector input"); +} +/* end of file */ From sumomo @ users.sourceforge.jp Wed Dec 18 12:55:21 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Wed, 18 Dec 2013 12:55:21 +0900 Subject: [Julius-cvs 878] CVS update: julius4/libsent/src/phmm Message-ID: <1387338921.521336.10316.nullmailer@users.sourceforge.jp> Index: julius4/libsent/src/phmm/outprob.c diff -u julius4/libsent/src/phmm/outprob.c:1.6 julius4/libsent/src/phmm/outprob.c:1.7 --- julius4/libsent/src/phmm/outprob.c:1.6 Fri Jun 21 02:14:25 2013 +++ julius4/libsent/src/phmm/outprob.c Wed Dec 18 12:55:21 2013 @@ -46,7 +46,7 @@ * @author Akinobu LEE * @date Fri Feb 18 18:45:21 2005 * - * $Revision: 1.6 $ + * $Revision: 1.7 $ * */ /* @@ -186,6 +186,7 @@ LOGPROB outp; int sid; int i, d; + HTK_HMM_State *s; sid = stateinfo->id; @@ -204,6 +205,29 @@ outprob_cache_extend(wrk, t); /* extend cache if needed */ wrk->last_cache = wrk->outprob_cache[t]; /* reduce 2-d array access */ } + + if (param->is_outprob) { + /* return the param as output probability */ + if (sid >= param->veclen) { + jlog("Error: state id in the dummy HMM exceeds vector length (%d > %d)\n", sid, param->veclen); + return(LOG_ZERO); + } + return(param->parvec[t][sid]); + } + + if (wrk->batch_computation) { + /* batch computation: if the frame is not computed yet, pre-compute all */ + s = wrk->OP_hmminfo->ststart; + if (wrk->last_cache[s->id] == LOG_UNDEF) { + for (; s; s = s->next) { + wrk->OP_state = s; + wrk->OP_state_id = s->id; + wrk->last_cache[s->id] = (*(wrk->calc_outprob_state))(wrk); + } + } + wrk->OP_state = stateinfo; + wrk->OP_state_id = sid; + } /* consult cache */ if ((outp = wrk->last_cache[sid]) == LOG_UNDEF) { @@ -383,3 +407,67 @@ return(outprob_state(wrk, t, hmmstate->out.state, param)); } } + + + + +static boolean +mywrite(char *buf, size_t unitbyte, int unitnum, FILE *fp, boolean needswap) +{ + size_t tmp; + + int i; + if (needswap) swap_bytes(buf, unitbyte, unitnum); + if ((tmp = myfwrite(buf, unitbyte, unitnum, fp)) < (size_t)unitnum) { + jlog("Error: outprob_cache_output: failed to write %d bytes\n", unitbyte * unitnum); + return(FALSE); + } + // if (needswap) swap_bytes(buf, unitbyte, unitnum); + return(TRUE); +} + +boolean +outprob_cache_output(FILE *fp, HMMWork *wrk, int framenum) +{ + int s,t; + boolean needswap; + +#ifdef WORDS_BIGENDIAN + needswap = FALSE; +#else /* LITTLE ENDIAN */ + needswap = TRUE; +#endif + + needswap = TRUE; + + if (wrk->outprob_allocframenum < framenum) { + jlog("Error: outprob_cache_output: framenum > allocated (%d > %d)\n", framenum, wrk->outprob_allocframenum); + return FALSE; + } + + { + unsigned int ui; + unsigned short us; + short st; + float f; + + jlog("Stat: outprob_cache_output: %d states, %d samples\n", wrk->statenum, framenum); + + ui = framenum; + if (!mywrite((char *)&ui, sizeof(unsigned int), 1, fp, needswap)) return FALSE; + ui = wrk->OP_param->header.wshift; + if (!mywrite((char *)&ui, sizeof(unsigned int), 1, fp, needswap)) return FALSE; + us = wrk->statenum * sizeof(float); + if (!mywrite((char *)&us, sizeof(unsigned short), 1, fp, needswap)) return FALSE; + st = F_USER; + if (!mywrite((char *)&st, sizeof(short), 1, fp, needswap)) return FALSE; + + for (t = 0; t < framenum; t++) { + for (s = 0; s < wrk->statenum; s++) { + f = wrk->outprob_cache[t][s]; + if (!mywrite((char *)&f, sizeof(float), 1, fp, needswap)) return FALSE; + } + } + } + +} Index: julius4/libsent/src/phmm/outprob_init.c diff -u julius4/libsent/src/phmm/outprob_init.c:1.7 julius4/libsent/src/phmm/outprob_init.c:1.8 --- julius4/libsent/src/phmm/outprob_init.c:1.7 Fri Jun 21 02:14:25 2013 +++ julius4/libsent/src/phmm/outprob_init.c Wed Dec 18 12:55:21 2013 @@ -34,7 +34,7 @@ * @author Akinobu LEE * @date Thu Feb 17 13:35:37 2005 * - * $Revision: 1.7 $ + * $Revision: 1.8 $ * */ /* @@ -186,9 +186,17 @@ outprob_cd_nbest_init(wrk, hmminfo->cdmax_num); } + wrk->batch_computation = FALSE; + return TRUE; } +void +outprob_set_batch_computation(HMMWork *wrk, boolean flag) +{ + wrk->batch_computation = flag; +} + /** * Prepare for the next input of given frame length. * From sumomo @ users.sourceforge.jp Wed Dec 18 12:55:21 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Wed, 18 Dec 2013 12:55:21 +0900 Subject: [Julius-cvs 879] CVS update: julius4/libsent Message-ID: <1387338921.179089.10260.nullmailer@users.sourceforge.jp> Index: julius4/libsent/Makefile.in diff -u julius4/libsent/Makefile.in:1.13 julius4/libsent/Makefile.in:1.14 --- julius4/libsent/Makefile.in:1.13 Fri Jun 21 02:14:20 2013 +++ julius4/libsent/Makefile.in Wed Dec 18 12:55:21 2013 @@ -3,7 +3,7 @@ # Copyright (c) 2005-2013 Julius project team, Nagoya Institute of Technology # All rights reserved # -# $Id: Makefile.in,v 1.13 2013/06/20 17:14:20 sumomo Exp $ +# $Id: Makefile.in,v 1.14 2013/12/18 03:55:21 sumomo Exp $ # SHELL=/bin/sh @@ -48,6 +48,7 @@ src/anlz/strip_mfcc.o \ src/anlz/wrsamp.o \ src/anlz/wrwav.o \ +src/anlz/vecin_net.o \ src/dfa/init_dfa.o \ src/dfa/rddfa.o \ src/dfa/dfa_lookup.o \ From sumomo @ users.sourceforge.jp Wed Dec 18 12:55:21 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Wed, 18 Dec 2013 12:55:21 +0900 Subject: [Julius-cvs 880] CVS update: julius4/libsent/src/hmminfo Message-ID: <1387338921.451958.10305.nullmailer@users.sourceforge.jp> Index: julius4/libsent/src/hmminfo/put_htkdata_info.c diff -u julius4/libsent/src/hmminfo/put_htkdata_info.c:1.8 julius4/libsent/src/hmminfo/put_htkdata_info.c:1.9 --- julius4/libsent/src/hmminfo/put_htkdata_info.c:1.8 Fri Jun 21 02:14:21 2013 +++ julius4/libsent/src/hmminfo/put_htkdata_info.c Wed Dec 18 12:55:21 2013 @@ -12,7 +12,7 @@ * @author Akinobu LEE * @date Tue Feb 15 23:36:00 2005 * - * $Revision: 1.8 $ + * $Revision: 1.9 $ * */ /* @@ -148,6 +148,7 @@ fprintf(fp, "no output state\n"); } else { if (s->name != NULL) fprintf(fp, "[~s \"%s\"]\n", s->name); + fprintf(fp, "id: %d\n", s->id); for (st=0;stnstream;st++) { fprintf(fp, "stream %d:", st + 1); if (s->w != NULL) { Index: julius4/libsent/src/hmminfo/rdhmmdef.c diff -u julius4/libsent/src/hmminfo/rdhmmdef.c:1.8 julius4/libsent/src/hmminfo/rdhmmdef.c:1.9 --- julius4/libsent/src/hmminfo/rdhmmdef.c:1.8 Fri Jun 21 02:14:21 2013 +++ julius4/libsent/src/hmminfo/rdhmmdef.c Wed Dec 18 12:55:21 2013 @@ -30,7 +30,7 @@ * @author Akinobu LEE * @date Wed Feb 16 00:17:18 2005 * - * $Revision: 1.8 $ + * $Revision: 1.9 $ * */ /* @@ -43,10 +43,14 @@ #include #include #include +#ifdef HAVE_ZLIB +#include +#endif #define MAXBUFLEN 4096 ///< Maximum length of a line in the input char *rdhmmdef_token; ///< Current token string (GLOBAL) +static boolean last_line_full = FALSE; static char buf[MAXBUFLEN]; ///< Local work area for token reading static int line; ///< Input Line count @@ -79,17 +83,52 @@ char * read_token(FILE *fp) { + int len; + int bp = 0; + int maxlen = MAXBUFLEN; + static char delims[] = HMMDEF_DELM; + if ((rdhmmdef_token = mystrtok_quote(NULL, HMMDEF_DELM)) != NULL) { - /* return next token */ - return rdhmmdef_token; + /* has token */ + if (mystrtok_movetonext(NULL, HMMDEF_DELM) != NULL || last_line_full == FALSE) { + /* return the current token, if this is not a last token, or + last is newline terminated */ + return rdhmmdef_token; + } else { + /* concatinate the last token with next line */ + len = strlen(rdhmmdef_token); + memmove(buf, rdhmmdef_token, len); + bp = len; + maxlen -= len; + } } - /* read new 1 line */ - if (getl(buf, MAXBUFLEN, fp) == NULL) { - rdhmmdef_token = NULL; - } else { - rdhmmdef_token = mystrtok_quote(buf, HMMDEF_DELM); - line++; + + /* read new 1 line a*/ + while( +#ifdef HAVE_ZLIB + gzgets((gzFile)fp, &(buf[bp]), maxlen) != Z_NULL +#else + fgets(&(buf[bp]), maxlen, fp) != NULL +#endif + ) { + /* chop delimiters at end of line (incl. newline) */ + /* if no delimiter at end of line, last_line_full is TRUE */ + last_line_full = TRUE; + len = strlen(buf)-1; + while (len >= 0 && strchr(delims, buf[len])) { + last_line_full = FALSE; + buf[len--] = '\0'; + } + if (buf[0] != '\0') { + /* start getting next token */ + rdhmmdef_token = mystrtok_quote(buf, HMMDEF_DELM); + /* increment line */ + line++; + return rdhmmdef_token; + } } + /* when reading error, return NULL */ + rdhmmdef_token = NULL; return rdhmmdef_token; } @@ -162,6 +201,52 @@ } #endif +boolean +htk_hmm_check_sid(HTK_HMM_INFO *hmm) +{ + HTK_HMM_State *stmp; + boolean *check; + int i; + boolean ok_p; + + /* check if each state is assigned a valid sid */ + check = (boolean *)mymalloc(sizeof(boolean) * hmm->totalstatenum); + for(i = 0; i < hmm->totalstatenum; i++) check[i] = FALSE; + for (stmp = hmm->ststart; stmp; stmp = stmp->next) { + if (stmp->id == -1) { + jlog("Error: rdhmmdef: no SID on some states\n"); + free(check); + return FALSE; + } + if (stmp->id < 0) { + jlog("Error: rdhmmdef: invalid SID value: %d\n", stmp->id); + free(check); + return FALSE; + } + if (stmp->id >= hmm->totalstatenum) { + jlog("Error: rdhmmdef: SID value exceeds the number of states? (%d > %d)\n", stmp->id, hmm->totalstatenum); + free(check); + return FALSE; + } + if (check[stmp->id] == TRUE) { + jlog("Error: rdhmmdef: duplicate definition to the same SID: %d\n", stmp->id); + free(check); + return FALSE; + } + check[stmp->id] = TRUE; + } + ok_p = TRUE; + for(i = 0; i < hmm->totalstatenum; i++) { + if (check[i] == FALSE) { + jlog("Error: rdhmmdef: missing SID: %d\n", i); + ok_p = FALSE; + } + } + free(check); + + return ok_p; +} + /** * @brief Main top routine to read in HTK %HMM definition file. * @@ -288,25 +373,54 @@ return FALSE; } - /* add ID number for all HTK_HMM_State */ - /* also calculate the maximum number of mixture */ + /* add ID number for all HTK_HMM_State if not assigned */ { HTK_HMM_State *stmp; - int n, max, s, mix; + int n; + boolean has_sid; + + /* caclculate total num and check if has sid */ + has_sid = FALSE; n = 0; - max = 0; for (stmp = hmm->ststart; stmp; stmp = stmp->next) { - for(s=0;snstream;s++) { - mix = stmp->pdf[s]->mix_num; - if (max < mix) max = mix; - } - stmp->id = n++; + n++; if (n >= MAX_STATE_NUM) { jlog("Error: rdhmmdef: too much states in a model > %d\n", MAX_STATE_NUM); return FALSE; } + if (stmp->id != -1) { + has_sid = TRUE; + } } hmm->totalstatenum = n; + if (has_sid) { + jlog("Stat: rdhmmdef: found in the definition\n"); + /* check if each state is assigned a valid sid */ + if (htk_hmm_check_sid(hmm) == FALSE) { + jlog("Error: rdhmmdef: error in SID\n"); + return FALSE; + } + } else { + /* assign internal sid (will not be saved) */ + jlog("Stat: rdhmmdef: no embedded\n"); + jlog("Stat: rdhmmdef: assign SID by the order of appearance\n"); + n = hmm->totalstatenum; + for (stmp = hmm->ststart; stmp; stmp = stmp->next) { + stmp->id = --n; + } + } + } + /* calculate the maximum number of mixture */ + { + HTK_HMM_State *stmp; + int max, s, mix; + max = 0; + for (stmp = hmm->ststart; stmp; stmp = stmp->next) { + for(s=0;snstream;s++) { + mix = stmp->pdf[s]->mix_num; + if (max < mix) max = mix; + } + } hmm->maxmixturenum = max; } /* compute total number of HMM models and maximum length */ Index: julius4/libsent/src/hmminfo/rdhmmdef_state.c diff -u julius4/libsent/src/hmminfo/rdhmmdef_state.c:1.7 julius4/libsent/src/hmminfo/rdhmmdef_state.c:1.8 --- julius4/libsent/src/hmminfo/rdhmmdef_state.c:1.7 Fri Jun 21 02:14:21 2013 +++ julius4/libsent/src/hmminfo/rdhmmdef_state.c Wed Dec 18 12:55:21 2013 @@ -12,7 +12,7 @@ * @author Akinobu LEE * @date Wed Feb 16 03:07:44 2005 * - * $Revision: 1.7 $ + * $Revision: 1.8 $ * */ /* @@ -46,7 +46,7 @@ for(i=0;instream;i++) { new->pdf[i] = NULL; } - new->id = 0; + new->id = -1; new->next = NULL; return(new); @@ -128,6 +128,13 @@ new = state_new(hmm); + if (currentis("SID")) { + read_token(fp); + NoTokErr("missing SID value"); + new->id = atoi(rdhmmdef_token); + read_token(fp); + } + if (currentis("NUMMIXES")) { if (hmm->tmp_mixnum == NULL) { hmm->tmp_mixnum = (int *)mybmalloc2(sizeof(int) * hmm->opt.stream_info.num, &(hmm->mroot)); @@ -188,7 +195,7 @@ { HTK_HMM_State *tmp; - if (currentis("NUMMIXES")||currentis("SWEIGHTS")||currentis("~w")||currentis("STREAM")||currentis("MIXTURE")||currentis("TMIX")||currentis("MEAN")||currentis("~m")||currentis("RCLASS")) { + if (currentis("SID")||currentis("NUMMIXES")||currentis("SWEIGHTS")||currentis("~w")||currentis("STREAM")||currentis("MIXTURE")||currentis("TMIX")||currentis("MEAN")||currentis("~m")||currentis("RCLASS")) { /* definition: define state data, and return the pointer */ tmp = state_read(fp, hmm); tmp->name = NULL; /* no name */ Index: julius4/libsent/src/hmminfo/read_binhmm.c diff -u julius4/libsent/src/hmminfo/read_binhmm.c:1.10 julius4/libsent/src/hmminfo/read_binhmm.c:1.11 --- julius4/libsent/src/hmminfo/read_binhmm.c:1.10 Fri Jun 21 02:14:21 2013 +++ julius4/libsent/src/hmminfo/read_binhmm.c Wed Dec 18 12:55:21 2013 @@ -22,7 +22,7 @@ * @author Akinobu LEE * @date Wed Feb 16 05:23:59 2005 * - * $Revision: 1.10 $ + * $Revision: 1.11 $ * */ /* @@ -862,13 +862,22 @@ hmm->totalpdfnum = n; } - /* re-number state id */ + /* check state id */ { HTK_HMM_State *stmp; - int n = 0; + int n; + boolean has_sid; + + /* check if each state is assigned a valid sid */ + if (htk_hmm_check_sid(hmm) == FALSE) { + jlog("Error: rdhmmdef: error in SID\n"); + return FALSE; + } +#if 0 for (stmp = hmm->ststart; stmp; stmp = stmp->next) { stmp->id = n++; } +#endif } /* assign ID number for all HTK_HMM_Trans */ { Index: julius4/libsent/src/hmminfo/write_binhmm.c diff -u julius4/libsent/src/hmminfo/write_binhmm.c:1.8 julius4/libsent/src/hmminfo/write_binhmm.c:1.9 --- julius4/libsent/src/hmminfo/write_binhmm.c:1.8 Fri Jun 21 02:14:21 2013 +++ julius4/libsent/src/hmminfo/write_binhmm.c Wed Dec 18 12:55:21 2013 @@ -22,7 +22,7 @@ * @author Akinobu LEE * @date Wed Feb 16 06:03:36 2005 * - * $Revision: 1.8 $ + * $Revision: 1.9 $ * */ /* @@ -31,7 +31,7 @@ * All rights reserved */ -/* $Id: write_binhmm.c,v 1.8 2013/06/20 17:14:21 sumomo Exp $ */ +/* $Id: write_binhmm.c,v 1.9 2013/12/18 03:55:21 sumomo Exp $ */ #include #include @@ -823,8 +823,9 @@ static int qsort_st_index(HTK_HMM_State **s1, HTK_HMM_State **s2) { - if (*s1 > *s2) return 1; - else if (*s1 < *s2) return -1; + /* keep ID order */ + if ((*s1)->id > (*s2)->id) return 1; + else if ((*s1)->id < (*s2)->id) return -1; else return 0; } @@ -918,7 +919,8 @@ while (left < right) { mid = (left + right) / 2; - if (st_index[mid] < s) { + /* search by id */ + if (st_index[mid]->id < s->id) { left = mid + 1; } else { right = mid; From sumomo @ users.sourceforge.jp Wed Dec 18 12:55:20 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Wed, 18 Dec 2013 12:55:20 +0900 Subject: [Julius-cvs 881] CVS update: julius4/libjulius/include/julius Message-ID: <1387338920.952422.10213.nullmailer@users.sourceforge.jp> Index: julius4/libjulius/include/julius/extern.h diff -u julius4/libjulius/include/julius/extern.h:1.23 julius4/libjulius/include/julius/extern.h:1.24 --- julius4/libjulius/include/julius/extern.h:1.23 Fri Jun 21 02:14:19 2013 +++ julius4/libjulius/include/julius/extern.h Wed Dec 18 12:55:20 2013 @@ -12,7 +12,7 @@ * @author Akinobu LEE * @date Mon Mar 7 23:19:14 2005 * - * $Revision: 1.23 $ + * $Revision: 1.24 $ * */ /* @@ -179,6 +179,7 @@ int set_beam_width(WCHMM_INFO *wchmm, int specified); /* m_info.c */ void print_jconf_overview(Jconf *jconf); +void print_mfcc_info(FILE *fp, MFCCCalc *mfcc, Jconf *jconf); void print_engine_info(Recog *recog); /* m_bootup.c */ void system_bootup(Recog *recog); Index: julius4/libjulius/include/julius/jconf.h diff -u julius4/libjulius/include/julius/jconf.h:1.19 julius4/libjulius/include/julius/jconf.h:1.20 --- julius4/libjulius/include/julius/jconf.h:1.19 Fri Jun 21 02:14:19 2013 +++ julius4/libjulius/include/julius/jconf.h Wed Dec 18 12:55:20 2013 @@ -23,7 +23,7 @@ * @author Akinobu Lee * @date Fri Feb 16 13:42:28 2007 * - * $Revision: 1.19 $ + * $Revision: 1.20 $ * */ /* @@ -1101,6 +1101,11 @@ */ boolean optsectioning; + /* + * Filename to save state probability output + * + */ + char *outprob_outfile; } Jconf; From sumomo @ users.sourceforge.jp Wed Dec 18 12:56:56 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Wed, 18 Dec 2013 12:56:56 +0900 Subject: [Julius-cvs 882] CVS update: julius4/dnntools Message-ID: <1387339016.223894.15783.nullmailer@users.sourceforge.jp> Index: julius4/dnntools/00readme.txt diff -u /dev/null julius4/dnntools/00readme.txt:1.1 --- /dev/null Wed Dec 18 12:56:56 2013 +++ julius4/dnntools/00readme.txt Wed Dec 18 12:56:56 2013 @@ -0,0 +1,39 @@ +This directory contains a sample script and tools + +1. sendvec.c +============== + +This is a sample stand-alone program to send input vectors to Julius +via TCP/IP network. You can compile like this: + + % cc -o sendvec sendvec.c + +Usage: "paramfile" is a HTK parameter file to be sent. + + % ./sendvec paramfile hostname [portnum] + +Define OUTPROBVECTOR at the top of the code to send the parameter +vector as outprob vectors. Remove the definition if you want to send +vectors as feature vector. Please note that the parameter type and +vector length will not be checked at the server side so you should +send the same type and size of the vector as assumed in the server side. + + +2. embed_sid.pl +================= + +This perl script embeds "" tags to HMM definition file, to make +correspondence between frontend outprob calculator and recognizer +(Julius) for DNN-HMM recognition. + + Usage: + + % ./embed_sid.pl < source_hmmdefs > embedded_hmmdefs + + +The script will embed " value" tags to all states, increasing the +"value" from 0, according to the order of appearance in the source +hmmdefs. + +The input format should be in HTK ASCII format, and the output is the +same, with the extra "" tag embedded. Index: julius4/dnntools/embed_sid.pl diff -u /dev/null julius4/dnntools/embed_sid.pl:1.1 --- /dev/null Wed Dec 18 12:56:56 2013 +++ julius4/dnntools/embed_sid.pl Wed Dec 18 12:56:56 2013 @@ -0,0 +1,52 @@ +#!/usr/bin/perl +# +# " number" is inserted just at the head of "stateinfo" definition +# +# More detail: +# case 1: direct definition +# short HERE stateinfo(not_macro_ref) ... +# case 2: macro definition +# ~s macro HERE stateinfo... +# +$mode = 0; +$id = 0; +while(<>) { + $op = 0; + $modstr = ""; + foreach $tok (split(/[ \r\n]+/)) { + if ($mode == 0) { + if ($tok =~ /\~s/i) { + $mode = 10; + } + if ($tok =~ /\/i) { + $mode = 1; + } + } elsif ($mode == 1) { + $mode = 2; + } elsif ($mode == 2) { + if (! ($tok =~ /\~s/i)) { + $tok = " " . $id . " " . $tok; + $id++; + $op = 1; + } + $mode = 0; + } elsif ($mode == 10) { + $mode = 11; + } elsif ($mode == 11) { + $tok = " " . $id . " " . $tok; + $id++; + $op = 1; + $mode = 0; + } + $modstr .= " " . $tok; + } + if ($op != 0) { + # output the modified version of this line + print $modstr . "\n"; + } else { + # output the original to minimize space diff + print $_; + } +} + +# end of probram Index: julius4/dnntools/sendvec.c diff -u /dev/null julius4/dnntools/sendvec.c:1.1 --- /dev/null Wed Dec 18 12:56:56 2013 +++ julius4/dnntools/sendvec.c Wed Dec 18 12:56:56 2013 @@ -0,0 +1,348 @@ +/* + * Define this to send parameter file as outprob vector + * + */ +#define OUTPROBVECTOR + +/* + * Define this to send 26 dim. data as 25 dim. excluding abs. power + * for feature vector + * + */ +#define SEND26TO25 + +#include +#include +#if defined(_WIN32) && !defined(__CYGWIN32__) +#define WINSOCK +#endif + +/**********************************************************************/ +/**********************************************************************/ +/**********************************************************************/ +/** + * Generic byte-swapping functions for any size of unit. + * + * @param buf [i/o] data buffer + * @param unitbyte [in] size of unit in bytes + * @param unitnum [in] number of unit in the buffer + */ +void +swap_bytes(char *buf, size_t unitbyte, size_t unitnum) +{ + char *p, c; + int i, j; + + p = buf; + while (unitnum > 0) { + i=0; j=unitbyte-1; + while(i +#else +#include +#include +#include +#include +#include +#include +#include +#include +#endif + +#ifdef WINSOCK +boolean winsock_initialized = FALSE; ///< TRUE if once initialized +#endif + +/* make connection to server */ +/* return socket descriptor, -1 on socket error, -2 on connection error, -3 on invalid host name */ +int make_connection(char *hostname, int port_num) +{ + static struct hostent *hp; + static struct sockaddr_in sin; + int sd; + int trynum; + +#ifdef WINSOCK + /* init winsock */ + if (!winsock_initialized) { + WSADATA data; + WSAStartup(0x1010, &data); + winsock_initialized = TRUE; + } + +#endif + + /* host existence check */ + if ((hp = gethostbyname(hostname)) == NULL) { + fprintf(stderr, "Error: failed to resolve host: %s\n", hostname); + return -3; + } + + /* create socket */ +#ifdef WINSOCK + if((sd = socket(PF_INET, SOCK_STREAM, 0)) == INVALID_SOCKET){ + fprintf(stderr, "Error: failed to create socket\n") ; + fprintf(stderr, "Error: error code: %d\n", WSAGetLastError()); + switch(WSAGetLastError()) { + case WSANOTINITIALISED: fprintf(stderr, "Error: reason: A successful WSAStartup must occur before using this function.\n"); break; + case WSAENETDOWN: fprintf(stderr, "Error: reason: The network subsystem or the associated service provider has failed.\n"); break; + case WSAEAFNOSUPPORT: fprintf(stderr, "Error: reason: The specified address family is not supported. \n"); break; + case WSAEINPROGRESS: fprintf(stderr, "Error: reason: A blocking Windows Sockets 1.1 call is in progress, or the service provider is still processing a callback function. \n"); break; + case WSAEMFILE: fprintf(stderr, "Error: reason: No more socket descriptors are available. \n"); break; + case WSAENOBUFS: fprintf(stderr, "Error: reason: No buffer space is available. The socket cannot be created. \n"); break; + case WSAEPROTONOSUPPORT: fprintf(stderr, "Error: reason: The specified protocol is not supported. \n"); break; + case WSAEPROTOTYPE: fprintf(stderr, "Error: reason: The specified protocol is the wrong type for this socket. \n"); break; + case WSAESOCKTNOSUPPORT: fprintf(stderr, "Error: reason: The specified socket type is not supported in this address family. \n"); break; + } + return -1; + } + +#else + if((sd = socket(PF_INET, SOCK_STREAM, 0)) < 0){ + fprintf(stderr, "Error: failed to create socket\n") ; + return -1; + } +#endif + + /* make connection */ + memset((char *)&sin, 0, sizeof(sin)); + memcpy(&sin.sin_addr, hp->h_addr, hp->h_length); + sin.sin_family = hp->h_addrtype; + sin.sin_port = htons((unsigned short)port_num); + if (connect(sd, (struct sockaddr *)&sin, sizeof(sin)) < 0) { + /* failure */ + fprintf(stderr, "Error: failed to connect to %s:%d\n", hostname, port_num); + return -2; + } + + return sd; +} + +/* close socket */ +/* return -1 on failure, 0 on success */ +int close_socket(int sd) +{ + int ret; + +#ifdef WINSOCK + ret = closesocket(sd); +#else + ret = close(sd); +#endif + + return(ret); +} + +/* clean up socket at end of program */ +void cleanup_socket() +{ +#ifdef WINSOCK + if (winsock_initialized) { + WSACleanup(); + } +#endif +} + +/**********************************************************************/ +/**********************************************************************/ +/**********************************************************************/ +/* data structure and global variables */ + +typedef struct { + int veclen; ///< (4 byte)Vector length of an input + int fshift; ///< (4 byte) Frame shift in msec of the vector + char outprob_p; ///< (1 byte) != 0 if input is outprob vector +} ConfigurationHeader; + +#define VECINNET_PORT 5531 ///< Port number to send the data + +/**********************************************************************/ +/**********************************************************************/ +/**********************************************************************/ +/* data transfer function */ +/* return -1 on error, 0 on success */ +int send_data(int sd, void *buf, int bytes) +{ + /* send data size header (4 byte) */ + if (send(sd, &bytes, sizeof(int), 0) != sizeof(int)) { + fprintf(stderr, "Error: failed to send %lu bytes\n", sizeof(int)); + return -1; + } + + /* send data body */ + if (send(sd, buf, bytes, 0) != bytes) { + fprintf(stderr, "Error: failed to send %lu bytes\n", sizeof(int)); + return -1; + } + + return 0; +} + +/* end-of-utterance transfer function */ +/* return -1 on error, 0 on success */ +int send_end_of_utterance(int sd) +{ + int i; + + /* send header value of '0' as an end-of-utterance marker */ + i = 0; + if (send(sd, &i, sizeof(int), 0) != sizeof(int)) { + fprintf(stderr, "Error: failed to send %lu bytes\n", sizeof(int)); + return -1; + } + + return 0; +} + +/* end-of-session transfer function */ +/* return -1 on error, 0 on success */ +int send_end_of_session(int sd) +{ + int i; + + /* send negative header value as an end-of-session marker */ + i = -1; + if (send(sd, &i, sizeof(int), 0) != sizeof(int)) { + fprintf(stderr, "Error: failed to send %lu bytes\n", sizeof(int)); + return -1; + } + + return 0; +} + +/**********************************************************************/ +/**********************************************************************/ +/**********************************************************************/ +/* usage: exename paramfile host [port] */ +int main(int argc, char *argv[]) +{ + int portnum; ///< Port number + int sd; + ConfigurationHeader conf; ///< Configuration of vector to be sent + + FILE *fp; + int framelen; ///< Number of frames in source + int fshift; ///< Frame shift of source + unsigned short vecdim; ///< Vector dimension + + + /* application argument check */ + if (argc < 3) { + fprintf(stderr, "usage: %s paramfile hostname [portnum]\n", argv[0]); + return -1; + } + + /* open HTK parameter file and read header */ + if ((fp = fopen(argv[1], "r")) == NULL) { + fprintf(stderr, "Error: failed to open %s\n", argv[1]); + close_socket(sd); cleanup_socket(); return -1; + } + if (fread(&framelen, sizeof(int), 1, fp) != 1) { + fprintf(stderr, "Error: failed to read header in %s\n", argv[1]); + close_socket(sd); cleanup_socket(); return -1; + } + swap_bytes((char *)&framelen, sizeof(int), 1); + if (fread(&fshift, sizeof(int), 1, fp) != 1) { + fprintf(stderr, "Error: failed to read header in %s\n", argv[1]); + close_socket(sd); cleanup_socket(); return -1; + } + swap_bytes((char *)&fshift, sizeof(int), 1); + if (fread(&vecdim, sizeof(unsigned short), 1, fp) != 1) { + fprintf(stderr, "Error: failed to read header in %s\n", argv[1]); + close_socket(sd); cleanup_socket(); return -1; + } + swap_bytes((char *)&vecdim, sizeof(unsigned short), 1); + vecdim /= sizeof(float); + fseek(fp, sizeof(short), SEEK_CUR); + + printf("%d frames, %d fshift, %d vecdim\n", framelen, fshift, vecdim); + + /* prepare configuration header */ + /* Warning: no parameter type/size check performed at server side */ + conf.veclen = vecdim; /* dimension */ + conf.fshift = (float)fshift / 10000.0; /* msec/frame */ +#ifdef OUTPROBVECTOR + conf.outprob_p = 1; /* outprob vector */ +#else + conf.outprob_p = 0; /* feature vector */ +#ifdef SEND26TO25 + conf.veclen--; +#endif +#endif + + /* port number: use VECINNET_PORT (= Julius default) if not specified */ + portnum = (argc >= 4) ? atoi(argv[3]) : VECINNET_PORT; + + + /* connect to server */ + if ((sd = make_connection(argv[2], portnum)) < 0) { + return -1; + } + + /* send configuration header */ + if (send_data(sd, &conf, sizeof(ConfigurationHeader)) == -1) { + return -1; + } + + /* send data, frame by frame*/ + { + int i; + float *buf; + + buf = (float *)malloc(sizeof(float) * vecdim); + for (i = 0; i < framelen; i++) { + if (fread(buf, sizeof(float), vecdim, fp) != vecdim) { + fprintf(stderr, "Error: failed to read vectors in %s\n", argv[1]); + close_socket(sd); cleanup_socket(); return -1; + } + swap_bytes((char *)buf, sizeof(float), vecdim); + +#if !defined(OUTPROBVECTOR) && defined(SEND26TO25) + /* send 26 dim data as 25 dim */ + { + int j; + for (j = 13; j < vecdim; j++) { + buf[j-1] = buf[j]; + } + if (send_data(sd, buf, sizeof(float) * (vecdim - 1)) == -1) { + close_socket(sd); cleanup_socket(); return -1; + } + } +#else + if (send_data(sd, buf, sizeof(float) * vecdim) == -1) { + close_socket(sd); cleanup_socket(); return -1; + } +#endif + printf("frame %d\n", i); + } + } + /* send end-of-utterance at each end of utterance unit */ + if (send_end_of_utterance(sd) == -1) { + close_socket(sd); cleanup_socket(); return -1; + } + + /* send end-of-session when input was ended */ + if (send_end_of_session(sd) == -1) { + close_socket(sd); cleanup_socket(); return -1; + } + + /* close socket */ + close_socket(sd); + cleanup_socket(); + + return 0; +} From sumomo @ users.sourceforge.jp Wed Dec 18 12:56:24 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Wed, 18 Dec 2013 12:56:24 +0900 Subject: [Julius-cvs 883] CVS update: julius4/dnntools Message-ID: <1387338984.198010.12934.nullmailer@users.sourceforge.jp> From sumomo @ users.sourceforge.jp Fri Dec 20 01:26:21 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Fri, 20 Dec 2013 01:26:21 +0900 Subject: [Julius-cvs 884] CVS update: julius4/adinrec Message-ID: <1387470381.940072.29007.nullmailer@users.sourceforge.jp> Index: julius4/adinrec/adinrec.c diff -u julius4/adinrec/adinrec.c:1.12 julius4/adinrec/adinrec.c:1.13 --- julius4/adinrec/adinrec.c:1.12 Fri Jun 21 02:14:16 2013 +++ julius4/adinrec/adinrec.c Fri Dec 20 01:26:21 2013 @@ -12,7 +12,7 @@ * @author Akinobu LEE * @date Wed Mar 23 20:33:01 2005 * - * $Revision: 1.12 $ + * $Revision: 1.13 $ * */ /* @@ -142,7 +142,7 @@ return -1; } if (count < len * sizeof(SP16)) { - fprintf(stderr, "adinrec: cannot write more %d bytes\ncurrent length = %d\n", count, speechlen * sizeof(SP16)); + fprintf(stderr, "adinrec: cannot write more %d bytes\ncurrent length = %lu\n", count, speechlen * sizeof(SP16)); return -1; } } else { From sumomo @ users.sourceforge.jp Fri Dec 20 01:26:22 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Fri, 20 Dec 2013 01:26:22 +0900 Subject: [Julius-cvs 885] CVS update: julius4/libsent/src/util Message-ID: <1387470382.336041.29048.nullmailer@users.sourceforge.jp> Index: julius4/libsent/src/util/confout.c diff -u julius4/libsent/src/util/confout.c:1.12 julius4/libsent/src/util/confout.c:1.13 --- julius4/libsent/src/util/confout.c:1.12 Fri Jun 21 14:24:26 2013 +++ julius4/libsent/src/util/confout.c Fri Dec 20 01:26:22 2013 @@ -12,7 +12,7 @@ * @author Akinobu LEE * @date Thu Feb 17 15:34:39 2005 * - * $Revision: 1.12 $ + * $Revision: 1.13 $ * */ /* @@ -94,9 +94,9 @@ fprintf(strm, " MBR weight support : no\n"); #endif #ifdef WORDS_INT - fprintf(strm, " word id unit : integer (%d bytes)\n", sizeof(WORD_ID)); + fprintf(strm, " word id unit : integer (%lu bytes)\n", sizeof(WORD_ID)); #else - fprintf(strm, " word id unit : short (%d bytes)\n", sizeof(WORD_ID)); + fprintf(strm, " word id unit : short (%lu bytes)\n", sizeof(WORD_ID)); #endif } From sumomo @ users.sourceforge.jp Fri Dec 20 01:26:22 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Fri, 20 Dec 2013 01:26:22 +0900 Subject: [Julius-cvs 886] CVS update: julius4/adintool Message-ID: <1387470382.053477.29016.nullmailer@users.sourceforge.jp> Index: julius4/adintool/adintool.c diff -u julius4/adintool/adintool.c:1.18 julius4/adintool/adintool.c:1.19 --- julius4/adintool/adintool.c:1.18 Wed Dec 18 12:55:20 2013 +++ julius4/adintool/adintool.c Fri Dec 20 01:26:21 2013 @@ -35,7 +35,7 @@ * @author Akinobu LEE * @date Wed Mar 23 20:43:32 2005 * - * $Revision: 1.18 $ + * $Revision: 1.19 $ * */ /* @@ -655,7 +655,7 @@ return -1; } if (count < len * sizeof(SP16)) { - fprintf(stderr, "adinrec: cannot write more %d bytes\ncurrent length = %d\n", count, speechlen * sizeof(SP16)); + fprintf(stderr, "adinrec: cannot write more %d bytes\ncurrent length = %lu\n", count, speechlen * sizeof(SP16)); return -1; } } else { From sumomo @ users.sourceforge.jp Fri Dec 20 01:26:22 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Fri, 20 Dec 2013 01:26:22 +0900 Subject: [Julius-cvs 887] CVS update: julius4/libjulius/src Message-ID: <1387470382.197267.29032.nullmailer@users.sourceforge.jp> Index: julius4/libjulius/src/plugin.c diff -u julius4/libjulius/src/plugin.c:1.10 julius4/libjulius/src/plugin.c:1.11 --- julius4/libjulius/src/plugin.c:1.10 Wed Dec 18 12:55:20 2013 +++ julius4/libjulius/src/plugin.c Fri Dec 20 01:26:22 2013 @@ -12,7 +12,7 @@ * @author Akinobu Lee * @date Sat Aug 2 09:46:09 2008 * - * $Revision: 1.10 $ + * $Revision: 1.11 $ * */ /* @@ -531,7 +531,7 @@ mfcc->func.fv_resume = (boolean (*)()) vecin_resume; mfcc->func.fv_pause = (boolean (*)()) vecin_pause; mfcc->func.fv_terminate = (boolean (*)()) vecin_terminate; - mfcc->func.fv_input_name = (boolean (*)()) vecin_input_name; + mfcc->func.fv_input_name = (char * (*)()) vecin_input_name; #ifdef ENABLE_PLUGIN mfcc->plugin_source = recog->jconf->input.plugin_source; From sumomo @ users.sourceforge.jp Fri Dec 20 01:26:22 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Fri, 20 Dec 2013 01:26:22 +0900 Subject: [Julius-cvs 888] CVS update: julius4/julius Message-ID: <1387470382.123649.29024.nullmailer@users.sourceforge.jp> Index: julius4/julius/record.c diff -u julius4/julius/record.c:1.7 julius4/julius/record.c:1.8 --- julius4/julius/record.c:1.7 Fri Jun 21 02:14:19 2013 +++ julius4/julius/record.c Fri Dec 20 01:26:22 2013 @@ -29,7 +29,7 @@ * @author Akinobu Lee * @date Tue Sep 06 14:13:54 2005 * - * $Revision: 1.7 $ + * $Revision: 1.8 $ * */ /* @@ -242,7 +242,7 @@ return; } if (verbose_flag) { - fprintf(stderr, "recorded to \"%s\" (%d bytes, %.2f sec.)\n", recordfilename, recordlen * sizeof(SP16), (float)recordlen / (float) recog->jconf->input.sfreq); + fprintf(stderr, "recorded to \"%s\" (%lu bytes, %.2f sec.)\n", recordfilename, recordlen * sizeof(SP16), (float)recordlen / (float) recog->jconf->input.sfreq); } } From sumomo @ users.sourceforge.jp Fri Dec 20 01:26:22 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Fri, 20 Dec 2013 01:26:22 +0900 Subject: [Julius-cvs 889] CVS update: julius4/libsent/src/adin Message-ID: <1387470382.273192.29040.nullmailer@users.sourceforge.jp> Index: julius4/libsent/src/adin/adin_mic_linux_oss.c diff -u julius4/libsent/src/adin/adin_mic_linux_oss.c:1.10 julius4/libsent/src/adin/adin_mic_linux_oss.c:1.11 --- julius4/libsent/src/adin/adin_mic_linux_oss.c:1.10 Fri Jun 21 02:14:20 2013 +++ julius4/libsent/src/adin/adin_mic_linux_oss.c Fri Dec 20 01:26:22 2013 @@ -51,7 +51,7 @@ * @author Akinobu LEE * @date Sun Feb 13 16:18:26 2005 * - * $Revision: 1.10 $ + * $Revision: 1.11 $ * */ /* @@ -359,6 +359,7 @@ { char buf[4]; char *p; + size_t ret; /* set device name */ if (pathname != NULL) { @@ -378,9 +379,9 @@ /* Read 1 sample (and ignore it) to tell the audio device start recording. (If you knows better way, teach me...) */ if (stereo_rec) { - read(audio_fd, buf, 4); + ret = read(audio_fd, buf, 4); } else { - read(audio_fd, buf, 2); + ret = read(audio_fd, buf, 2); } return(TRUE); } From sumomo @ users.sourceforge.jp Fri Dec 20 01:26:22 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Fri, 20 Dec 2013 01:26:22 +0900 Subject: [Julius-cvs 890] CVS update: julius4/mkss Message-ID: <1387470382.399852.29056.nullmailer@users.sourceforge.jp> Index: julius4/mkss/mkss.c diff -u julius4/mkss/mkss.c:1.8 julius4/mkss/mkss.c:1.9 --- julius4/mkss/mkss.c:1.8 Fri Jun 21 02:14:28 2013 +++ julius4/mkss/mkss.c Fri Dec 20 01:26:22 2013 @@ -8,7 +8,7 @@ /* * mkss --- compute average spectrum of mic input for SS in Julius * - * $Id: mkss.c,v 1.8 2013/06/20 17:14:28 sumomo Exp $ + * $Id: mkss.c,v 1.9 2013/12/19 16:26:22 sumomo Exp $ * */ @@ -190,7 +190,7 @@ /* close device */ adin_end(recog->adin); - fprintf(stderr, "\n%d samples (%d bytes, %.1f sec) recorded\n", samples, samples * sizeof(SP16), (float)samples / (float)sfreq); + fprintf(stderr, "\n%d samples (%lu bytes, %.1f sec) recorded\n", samples, samples * sizeof(SP16), (float)samples / (float)sfreq); /* compute SS */ fprintf(stderr, "compute SS:\n"); From sumomo @ users.sourceforge.jp Fri Dec 20 01:27:47 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Fri, 20 Dec 2013 01:27:47 +0900 Subject: [Julius-cvs 891] CVS update: julius4 Message-ID: <1387470467.852303.32717.nullmailer@users.sourceforge.jp> Index: julius4/00readme-ja.txt diff -u julius4/00readme-ja.txt:1.20 julius4/00readme-ja.txt:1.21 --- julius4/00readme-ja.txt:1.20 Tue Jun 25 14:59:55 2013 +++ julius4/00readme-ja.txt Fri Dec 20 01:27:47 2013 @@ -4,6 +4,7 @@ Julius + (Rev 4.3 2013/12/25) (Rev 4.2.3 2013/06/30) (Rev 4.2.2 2012/08/01) (Rev 4.2.1 2011/12/25) @@ -37,18 +38,36 @@ http://julius.sourceforge.jp/ -Julius-4.2.3 +Julius-4.3 ============= -????? 4.2.3 ???????????ォ???????A??????? -?????????????????????????T????????? -????????????????N-gram???????????????? -???????????????B +????? 4.3 ???DNN-HMM (Deep Neural-Network HMM) ???????? +???????????????????????????????o??? +????"outprob vector" ??????????????????????? +?????????????o????????????????????? +????? CVN (cepstral variance normalization), ?????????? +????(FBANK/MELSPEC)?????????????? adintool ???? +?????l??????????????????????????? ??????? - -lvscale - -rejectlong - -mbr, -nombr, -mbr_wwer, -mbr_weight + [-input vecnet] ???????????/??m?????????? + [-input outprob] HTK????????????m???????????? + [-outprobout [file]] ???????m????HTK?ョ???????(debug) + +?????????????????????????????????????? + + [???] + % julius -C file.jconf -input vecnet + + [?????????????] + % adintool -in mic -out vecnet -paramtype MFCC_E_D_N_Z -veclen 25 -C file.jconf + +adintool ?????????????? ("-paramtype TYPE") ????? +?"-veclen length"??????????????????????????? Julius???????Julius?????????????????? +adintool ? Julius ???????????? Jconf ?????????? +????Julius ????ッ???????? Jconf ????????? +adintool ? "-C" ???????????????L??? ??????????Release-ja.txt ???????? ?? "-help" ????タ???????????????????????B @@ -79,6 +98,8 @@ plugin/ ????????????????????? man/ ?????? support/ ???????? + (new) dnntools/ Sample programs for dnn and vecnet client + ??????????? Index: julius4/00readme.txt diff -u julius4/00readme.txt:1.18 julius4/00readme.txt:1.19 --- julius4/00readme.txt:1.18 Tue Jun 25 14:59:55 2013 +++ julius4/00readme.txt Fri Dec 20 01:27:47 2013 @@ -4,6 +4,7 @@ Julius + (Rev 4.3 2013/12/25) (Rev 4.2.3 2013/06/30) (Rev 4.2.2 2012/08/01) (Rev 4.2.1 2011/12/25) @@ -49,24 +50,42 @@ together with source codes. -What's new in Julius-4.2.3 +What's new in Julius-4.3 =========================== -Version 4.2.3 includes new features: dictionary reloading, audio input -scaling, long input rejection, minimum bayes risk decoding -(contributed by Hiroaki Nanjo and Ryo Furutani), and character set -conversion of binary N-gram. Several bugs has also been fixed. +Version 4.3 includes several new features to support on-line DNN-HMM +decoding: decoding with state output probability vectors ("outprob +vectors") as input, network-based feature / outprob vector input, +improved cepstral variance normalization (CVN) for real-time +recognition, FBANK/MELSPEC feature support and so on. Also the tool +"adintool" is now capable of extracting and sending feature vectors in +real-time via network. New options: - -lvscale - -rejectlong - -mbr, -nombr, -mbr_wwer, -mbr_weight + [-input vecnet] read feature / outprob vectors from network + [-input outprob] read outprob vectors from HTK parameter file + [-outprobout [file]] save computed outprob vectors to HTK file (for debug) + +A short test of network-based feature transmission: + + [server] + % julius -C file.jconf -input vecnet + + [client with microphone] + % adintool -in mic -out vecnet -paramtype MFCC_E_D_N_Z -veclen 25 -C file.jconf + +You should set appropriate feature vector's type and length to +adintool with "-paramtype TYPE", "-veclen length". You should also +set feature extraction parameters as the same as Julius. Since +adintool uses JuliusLib for the extraction, it accepts Jconf file and +setting options as same as Julis. So the easier way is to apply the +same Jconf file to adintool with "-C" option as shown above. See the "Release.txt" file for the full list of updates. Run with "-help" to see full list of options. -Contents of Julius-4.2.3 +Contents of Julius-4.3 ========================= (Documents with suffix "ja" are written in Japanese) @@ -94,6 +113,7 @@ plugin/ Several plugin source codes and documentation man/ Unix online manuals msvc/ Files to compile on Microsoft VC++ 2008 + (new) dnntools/ Sample programs for dnn and vecnet client Documentation Index: julius4/Release-ja.txt diff -u julius4/Release-ja.txt:1.20 julius4/Release-ja.txt:1.21 --- julius4/Release-ja.txt:1.20 Tue Jun 25 14:59:55 2013 +++ julius4/Release-ja.txt Fri Dec 20 01:27:47 2013 @@ -1,3 +1,23 @@ +4.3 (2013.12.25) +================= +???? +- ?????????iFBANK ??? MELSPEC?????? +- ???????????????????????m??????? +- DNN-HMM?????????????o????????outprob vector??? +- DNN-HMM???????????hmmdefs?? "" ????? +- adintool ??????????????l??????????? + +???? +- mkbinhmm ????hmmdefs????????D?""???? +- Portaudio ????????pause/resume??????????????? +- CMN/CVN?????????????? HTK ?????ョ???????? + +??????? + [-input vecnet] ???????????/??m?????????? + [-input outprob] HTK????????????m???????????? + [-outprobout [file]] ???????m????HTK?ョ???????(debug) + + 4.2.3 (2013.06.30) ================== Index: julius4/Release.txt diff -u julius4/Release.txt:1.18 julius4/Release.txt:1.19 --- julius4/Release.txt:1.18 Fri Jun 21 14:24:26 2013 +++ julius4/Release.txt Fri Dec 20 01:27:47 2013 @@ -1,3 +1,24 @@ +4.3 (2013.12.25) +================= +New features: +- FBANK and MELSPEC support. +- Network-based feature vector and outprob vector input. +- Static mean/variance for cepstral mean/variance normalization. +- State output probability (i.e. outprob) vector input for DNN-HMM decoding. +- State ID "" extension of hmmdefs for DNN-HMM decoding. +- Real-time feature extraction and network transmittion by 'adintool'. + +Modified: +- "mkbinhmm" now keeps the state order and id of the original hmmdefs. +- For portaudio, pause / resume operation synced between engine and audio I/O +- Load / save cepstral mean/variance of CMN/CVN in HTK text format. + +New options: + [-input vecnet] read feature / outprob vectors from network + [-input outprob] read outprob vectors from HTK parameter file + [-outprobout [file]] save computed outprob vectors to HTK file (for debug) + + 4.2.3 (2013.06.30) ================== Index: julius4/Sample.jconf diff -u julius4/Sample.jconf:1.9 julius4/Sample.jconf:1.10 --- julius4/Sample.jconf:1.9 Fri Jun 21 02:02:27 2013 +++ julius4/Sample.jconf Fri Dec 20 01:27:47 2013 @@ -1,6 +1,6 @@ # # Sample Jconf configuration file -# for Julius library rev.4.2 +# for Julius library rev.4.3 # # 1) Options can also be specified in command line option. # The values are default values in Julius. @@ -43,17 +43,28 @@ #-demo # same as "-quiet -progout" #### -#### Audio Input +#### Stream Input #### + +## Feature vector input +#-input mfcfile # feature vector in HTK parameter file +#-input htkparam # (same as "mfcfile") +#-input outprob # outprob vector in HTK parameter file +#-input vecet # feature / outprob vector via network client + +## Raw audio input #-input mic # live microphone #-input rawfile # wavefile -#-input mfcfile # MFCC file (HTK Parameter file) +#-input file # (same as "rawfile") #-input stdin # waveform from standard input #-input adinnet # waveform via network client -#-input netaudio # DatLink server +#-input netaudio # DatLink server #-input oss # OSS API input (if available) #-input alsa # ALSA API input (if available) #-input esd # ESounD daemon input (if available) +#-input portaudio # PortAudio API +#-input pulseaudio # PulseAudio API + #-filelist filename # input file list #-notypecheck # does not check parameter type of input @@ -80,6 +91,7 @@ #-zc 60 # zero-cross threshold (times in sec.) #-headmargin 300 # head silence margin (msec) #-tailmargin 400 # tail silence margin (msec) +#-chunk_size 1000 # processing segment unit length in samples #-rejectshort 0 # reject shorter input (msec) #-rejectlong -1 # reject longer input (msec) -1 to disable @@ -393,4 +405,9 @@ #-palign # enable alignment for result at phoneme level #-salign # enable alignment for result at state level +#### +#### misc. +#### +-outprobout filename # save computed outprob vectors to HTK file (for debug) + ################################################################# end of file From sumomo @ users.sourceforge.jp Fri Dec 20 01:28:09 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Fri, 20 Dec 2013 01:28:09 +0900 Subject: [Julius-cvs 892] CVS update: julius4/support Message-ID: <1387470489.103485.1765.nullmailer@users.sourceforge.jp> Index: julius4/support/build-all.sh diff -u julius4/support/build-all.sh:1.14 julius4/support/build-all.sh:1.15 --- julius4/support/build-all.sh:1.14 Fri Jun 21 02:02:30 2013 +++ julius4/support/build-all.sh Fri Dec 20 01:28:09 2013 @@ -6,7 +6,7 @@ # # argument: any configure options except "--enable-setup=..." is allowed. # -JULIUS_VERSION=4.2.3 +JULIUS_VERSION=4.3 ###################################################################### Index: julius4/support/cflags.x86_64-unknown-linux-gnu diff -u /dev/null julius4/support/cflags.x86_64-unknown-linux-gnu:1.1 --- /dev/null Fri Dec 20 01:28:09 2013 +++ julius4/support/cflags.x86_64-unknown-linux-gnu Fri Dec 20 01:28:09 2013 @@ -0,0 +1 @@ +CFLAGS='-O6 -fomit-frame-pointer' Index: julius4/support/makeman.sh diff -u julius4/support/makeman.sh:1.2 julius4/support/makeman.sh:1.3 --- julius4/support/makeman.sh:1.2 Thu Oct 2 17:23:49 2008 +++ julius4/support/makeman.sh Fri Dec 20 01:28:09 2013 @@ -6,5 +6,7 @@ # # nroff -man man/$1.1 | sed -e 's/.//g' | nkf -c > $2/00readme.txt -LANG=ja_JP.eucJP nroff -Tnippon -man man/ja/$1.1 | sed -e 's/.//g' | nkf -s -c > $2/00readme-ja.txt +groff -Dutf8 -Tutf8 -mandoc -mja -E man/ja/$1.1 | sed -e 's/.//g' | nkf -s -c > $2/00readme-ja.txt echo $1 "->" $2 + + Index: julius4/support/modrev.sh diff -u julius4/support/modrev.sh:1.1.1.1 julius4/support/modrev.sh:1.2 --- julius4/support/modrev.sh:1.1.1.1 Fri Sep 28 11:50:56 2007 +++ julius4/support/modrev.sh Fri Dec 20 01:28:09 2013 @@ -3,10 +3,6 @@ # change version # (should be executed in the parent directory) # -if [[ $# == 0 ]]; then - echo usage: $0 newversionname - exit -fi newver=$1 for i in ./libjulius/configure.in ./support/build-all.sh; do Index: julius4/support/update-mantxt.sh diff -u julius4/support/update-mantxt.sh:1.3 julius4/support/update-mantxt.sh:1.4 --- julius4/support/update-mantxt.sh:1.3 Thu Oct 2 17:23:49 2008 +++ julius4/support/update-mantxt.sh Fri Dec 20 01:28:09 2013 @@ -23,6 +23,9 @@ ./support/makeman.sh jcontrol jcontrol ./support/makeman.sh julius julius ./support/makeman.sh mkbingram mkbingram +./support/makeman.sh mkbinhmmlist mkbinhmm +mv mkbinhmm/00readme.txt mkbinhmm/00readme-mkbinhmmlist.txt +mv mkbinhmm/00readme-ja.txt mkbinhmm/00readme-mkbinhmmlist-ja.txt ./support/makeman.sh mkbinhmm mkbinhmm ./support/makeman.sh mkdfa.pl gramtools/mkdfa ./support/makeman.sh mkgshmm mkgshmm From sumomo @ users.sourceforge.jp Fri Dec 20 01:28:45 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Fri, 20 Dec 2013 01:28:45 +0900 Subject: [Julius-cvs 893] CVS update: julius4/adinrec Message-ID: <1387470525.404149.2350.nullmailer@users.sourceforge.jp> Index: julius4/adinrec/00readme-ja.txt diff -u julius4/adinrec/00readme-ja.txt:1.4 julius4/adinrec/00readme-ja.txt:1.5 --- julius4/adinrec/00readme-ja.txt:1.4 Mon Dec 5 14:39:51 2011 +++ julius4/adinrec/00readme-ja.txt Fri Dec 20 01:28:45 2013 @@ -31,104 +31,105 @@ adinrec specific options -freq Hz - ???????????? (Hz) ??????(default: 16,000) + ???????????? (Hz) ??????(default: 16,000) -raw - RAW?????ョ?????D + RAW?????ョ?????D Concerning Julius options -input {mic|rawfile|adinnet|stdin|netaudio|esd|alsa|oss} - ?????????????????????????file??? - ?rawfile?? ?????????????????????????? - ??? ????????adinnet ??? adintool ?????????? - ??????? ???????????????????????? - netaudio ?DatLink??????? stdin????????????s?? - esd??????????????????? Linux?????????? - ??????? EsounD daemon ??????? - - -chunk_size samples - ???????o?????????????????????? - ??(default: 1000) + ?????????????????????????file??? + ?rawfile?? ?????????????????????????? + ??? ????????adinnet ??? adintool ?????????? + ??????? ???????????????????????? + netaudio ?DatLink??????? stdin????????????s + ?? esd??????????????????? Linux??????? + ?????????? EsounD daemon ??????? -lv thres - ????????????? 0 ?? 32767 ????????? (default: - 2000) + ????????????? 0 ?? 32767 ????????? + (default: 2000) -zc thres - ??????????????????????????? (default: 60) + ??????????????????????????? (default: + 60) -headmargin msec - ???????????????????? (default: 300) + ???????????????????? (default: 300) -tailmargin msec - ????????}??????????? (default: 400) + ????????}??????????? (default: 400) -zmean - ????????????????????s???????????? - ?????????D + ????????????????????s???????????? + ?????????D -smpFreq Hz - ???????????? (Hz) ??????(default: 16,000) + ???????????? (Hz) ??????(default: 16,000) -48 - 48kHz???????16kHz????????????? ??? 16kHz ?? - ??????????????????? ?????????????? - ? sptk ?? ?????? (Rev. 4.0) + 48kHz???????16kHz????????????? ??? 16kHz ? + ???????????????????? ????????????? + ?? sptk ?? ?????? (Rev. 4.0) -NA devicename - DatLink ????????? (-input netaudio). + DatLink ????????? (-input netaudio). -adport port_number - -input adinnet ???????????? adinnet ?????????? - ??(default: 5530) + -input adinnet ???????????? adinnet ????????? + ???(default: 5530) -nostrip - ??????????????????????????????? ? - "0" ??????????????????Julius ???C?? ???? - ?????????????????D??????????????? - ????C???????????????ゥ???????????? - ???? + ??????????????????????????????? ? + "0" ??????????????????Julius ???C?? ??? + ??????????????????D?????????????? + ?????C???????????????ゥ??????????? + ????? -C jconffile - jconf?????????????????????????W????? + jconf?????????????????????????W????? -plugindir dirlist - ????????????????????????????????? - ??????????? + ????????????????????????????????? + ??????????? ENVIRONMENT VARIABLES ALSADEV - (?????? alsa ???????) ????????????? ??? - ?????"default"? + (?????? alsa ???????) ????????????? ?? + ??????"default"? AUDIODEV - (?????? oss ???????) ????????????? ??? - ?????"/dev/dsp"? + (?????? oss ???????) ????????????? ??? + ?????"/dev/dsp"? + + PORTAUDIO_DEV + (portaudio V19 ???) ????????????? ???????? + ? adinrec ???????O????????Q????D LATENCY_MSEC - Linux (alsa/oss) ??? Windows ??????????????? ?? - ????????????????????????????????CPU - ????????????????????????OS? ??????? - ?????????????OS ????????? ?????????? - ???????????? + Linux (alsa/oss) ??? Windows ??????????????? ?? + ?????????????????????????????? + ??CPU ????????????????????????OS? ??? + ?????????????????OS ????????? ??? + ??????????????????? SEE ALSO julius ( 1 ) , adintool ( 1 ) COPYRIGHT - Copyright (c) 1991-2008 ???? ????コ + Copyright (c) 1991-2013 ???? ????コ Copyright (c) 1997-2000 ????U?????(IPA) - Copyright (c) 2000-2008 ?????????w??? ュ???コ + Copyright (c) 2000-2005 ?????????w??? ュ???コ - Copyright (c) 2005-2008 ??????? Julius????? + Copyright (c) 2005-2013 ??????? Julius????? LICENSE Julius ??????????D - 10/02/2008 ADINREC(1) + 19/12/2013 ADINREC(1) Index: julius4/adinrec/00readme.txt diff -u julius4/adinrec/00readme.txt:1.4 julius4/adinrec/00readme.txt:1.5 --- julius4/adinrec/00readme.txt:1.4 Mon Dec 5 14:39:51 2011 +++ julius4/adinrec/00readme.txt Fri Dec 20 01:28:45 2013 @@ -30,99 +30,100 @@ adinrec specific options -freq Hz - Set sampling rate in Hz. (default: 16,000) + Set sampling rate in Hz. (default: 16,000) -raw - Output in raw file format. + Output in raw file format. JuliusLib options -input {mic|rawfile|adinnet|stdin|netaudio|esd|alsa|oss} - Choose speech input source. Specify 'file' or 'rawfile' for waveform - file. On file input, users will be prompted to enter the file name - from stdin. - - 'mic' is to get audio input from a default live microphone device, - and 'adinnet' means receiving waveform data via tcpip network from - an adinnet client. 'netaudio' is from DatLink/NetAudio input, and - 'stdin' means data input from standard input. + Choose speech input source. Specify 'file' or 'rawfile' for + waveform file. On file input, users will be prompted to enter the + file name from stdin. + + 'mic' is to get audio input from a default live microphone device, + and 'adinnet' means receiving waveform data via tcpip network from + an adinnet client. 'netaudio' is from DatLink/NetAudio input, and + 'stdin' means data input from standard input. - At Linux, you can choose API at run time by specifying alsa, oss and - esd. - - -chunk_size samples - Audio fragment size in number of samples. (default: 1000) + At Linux, you can choose API at run time by specifying alsa, oss + and esd. -lv thres - Level threshold for speech input detection. Values should be in - range from 0 to 32767. (default: 2000) + Level threshold for speech input detection. Values should be in + range from 0 to 32767. (default: 2000) -zc thres - Zero crossing threshold per second. Only input that goes over the - level threshold (-lv) will be counted. (default: 60) + Zero crossing threshold per second. Only input that goes over the + level threshold (-lv) will be counted. (default: 60) -headmargin msec - Silence margin at the start of speech segment in milliseconds. - (default: 300) + Silence margin at the start of speech segment in milliseconds. + (default: 300) -tailmargin msec - Silence margin at the end of speech segment in milliseconds. - (default: 400) + Silence margin at the end of speech segment in milliseconds. + (default: 400) -zmean - This option enables DC offset removal. + This option enables DC offset removal. -smpFreq Hz - Set sampling rate in Hz. (default: 16,000) + Set sampling rate in Hz. (default: 16,000) -48 - Record input with 48kHz sampling, and down-sample it to 16kHz - on-the-fly. This option is valid for 16kHz model only. The - down-sampling routine was ported from sptk. (Rev. 4.0) + Record input with 48kHz sampling, and down-sample it to 16kHz + on-the-fly. This option is valid for 16kHz model only. The + down-sampling routine was ported from sptk. (Rev. 4.0) -NA devicename - Host name for DatLink server input (-input netaudio). + Host name for DatLink server input (-input netaudio). -adport port_number - With -input adinnet, specify adinnet port number to listen. - (default: 5530) + With -input adinnet, specify adinnet port number to listen. + (default: 5530) -nostrip - Julius by default removes successive zero samples in input speech - data. This option stop it. + Julius by default removes successive zero samples in input speech + data. This option stop it. -C jconffile - Load a jconf file at here. The content of the jconffile will be - expanded at this point. + Load a jconf file at here. The content of the jconffile will be + expanded at this point. -plugindir dirlist - Specify which directories to load plugin. If several direcotries - exist, specify them by colon-separated list. + Specify which directories to load plugin. If several direcotries + exist, specify them by colon-separated list. ENVIRONMENT VARIABLES ALSADEV - Device name string for ALSA. (default: "default") + Device name string for ALSA. (default: "default") AUDIODEV - Device name string for OSS. (default: "/dev/dsp") + Device name string for OSS. (default: "/dev/dsp") + + PORTAUDIO_DEV + (portaudio V19) specify the name of capture device to use. See the + instruction output of log at start up how to specify it. LATENCY_MSEC - Input latency of microphone input in milliseconds. Smaller value - will shorten latency but sometimes make process unstable. Default - value will depend on the running OS. + Input latency of microphone input in milliseconds. Smaller value + will shorten latency but sometimes make process unstable. Default + value will depend on the running OS. SEE ALSO julius ( 1 ) , adintool ( 1 ) COPYRIGHT - Copyright (c) 1997-2000 Information-technology Promotion Agency, Japan + Copyright (c) 1991-2013 Kawahara Lab., Kyoto University - Copyright (c) 1991-2008 Kawahara Lab., Kyoto University + Copyright (c) 1997-2000 Information-technology Promotion Agency, Japan Copyright (c) 2000-2005 Shikano Lab., Nara Institute of Science and Technology - Copyright (c) 2005-2008 Julius project team, Nagoya Institute of + Copyright (c) 2005-2013 Julius project team, Nagoya Institute of Technology LICENSE @@ -130,4 +131,4 @@ - 10/02/2008 ADINREC(1) + 12/19/2013 ADINREC(1) From sumomo @ users.sourceforge.jp Fri Dec 20 01:28:45 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Fri, 20 Dec 2013 01:28:45 +0900 Subject: [Julius-cvs 894] CVS update: julius4/adintool Message-ID: <1387470525.505664.2369.nullmailer@users.sourceforge.jp> Index: julius4/adintool/00readme-ja.txt diff -u julius4/adintool/00readme-ja.txt:1.4 julius4/adintool/00readme-ja.txt:1.5 --- julius4/adintool/00readme-ja.txt:1.4 Mon Dec 5 14:39:51 2011 +++ julius4/adintool/00readme-ja.txt Fri Dec 20 01:28:45 2013 @@ -38,157 +38,167 @@ OPTIONS Julius ????????????????????????????? ?? - ???????????????????????adintool ? ?????? - ?????? Julius ??????????? + ???????????????????????adintool ? ???? + ???????? Julius ??????????? adintool specific options -freq Hz - ???????????? (Hz) ??????(default: 16,000) + ???????????? (Hz) ??????(default: 16,000) -in inputdev - ???????????????????"mic" ??????? "file" ? - ??????, "stdin" ??????????????D ??????? - ??C??????????????v?????? ???????? - ??"adinnet" ? adintool ? adinnet ???? ????adinnet ??? - ??????????? tcp/ip ??? ??????????? 5530 ? - ???"-inport" ??????? + ???????????????????"mic" ??????? "file" + ???????, "stdin" ??????????????D ?????? + ???C??????????????v?????? ???????? + ??"adinnet" ? adintool ? adinnet ???? ????adinnet ?? + ???????????? tcp/ip ??? ??????????? 5530 + ????"-inport" ??????? - ???????????? Julius ? "-input" ??????????? - ????????C????????????????? + ???????????? Julius ? "-input" ??????????? + ????????C????????????????? -out outputdev - ???????f?????????"file" ???????C stdout ? - ??o??????D???????C??t????? ????? - "-filename" ???????t??? ?ョ? 16bit WAV ?ョ???? ? - ??"adinnet" ? adintool ? adinnet ?????? ????adinnet - ??????????????? tcp/ip ??? ??????????? - ?? "-server" ?????? ?????? 5530 ????"-port" ??? - ???? + ???????f?????????"file" ???????C stdout ? + ??o??????D???????C??t????? ????? + "-filename" ???????t??? ?ョ? 16bit WAV ?ョ???? ? + ??"adinnet" ? adintool ? adinnet ?????? ????adinnet + ??????????????? tcp/ip ??? ??????????? + ?? "-server" ?????? ?????? 5530 ????"-port" ?? + ????? "vecnet" ????????????????x?????? + ???????? -inport num - ??? adinnet ???(-in adinnet)???????????? ???? - ??????????f????? 5530 ???? + ??? adinnet ???(-in adinnet)???????????? ??? + ???????????f????? 5530 ???? -server [host] [,host...] - ???adinnet ???(-out adinnet)??????????????? - ???????C????????????? + ???adinnet ???(-out adinnet)??????????????? + ???????C????????????? -port [num] [,num...] - ???adinnet ???(-out adinnet)??????????????? - ??????????????f????? 5530 ???? -server ?? - ??????????????C ???????ヲ?????????? - ???????? + ???adinnet ???(-out adinnet)??????????????? + ??????????????f????? 5530 ???? -server ?? + ??????????????C ???????ヲ?????????? + ???????? -filename file - ??????(-out file) ????t????? ?????????? - ????????????o???? "file.0000.wav" , "file.0001.wav" - ... ???????????? ???????????l? 0 ??? - ?-startid? ?????????????? -oneshot ???? ????- ???? "file" ?????????? + ??????(-out file) ????t????? ?????????? + ????????????o???? "file.0000.wav" , + "file.0001.wav" ... ???????????? ???????????+ ?? 0 ????-startid? ?????????????? -oneshot ? + ??? ????????"file" ?????????? -startid number - ???????C??????????????l??????? ??? - ???0? + ???????C??????????????l??????? ??? + ???0? -oneshot - ????????I????????D + ????????I????????D -nosegment - ???????????i???????????????????? ? - ???? + ???????????i???????????????????? ? + ???? -raw - RAW?????ョ?????D + RAW?????ョ?????D -autopause - ???adinnet ???i-out adinnet???????????????? - ???????????s???????adinnet ???? ?????? - ??????????????? + ???adinnet ???i-out adinnet??????????????? + ????????????s???????adinnet ???? ???? + ????????????????? -loosesync - ???adinnet ?-out adinnet????????T??????????- ?????????????J???????????????adintool - ? ?????????????????????????????? ?? - ?????????????????P??????????? ???? - ????????????? + ???adinnet ?-out adinnet????????T?????????+ ??C???????????J????????????? + ??adintool ? ????????????????????????? + ????? ???????????????????P???????? + ??? ????????????????? -rewind msec - ????????????????????J?????????? ?? - ????????????C????????????????? ??? - ????? + ????????????????????J?????????? ?? + ????????????C????????????????? ??? + ????? + + -paramtype parameter_type + ???vecnet ???-out vecnet????????????HTK?ョ?? + ?????:"MFCC_E_D_N_Z"?? + + -veclen vector_length + ???vecnet ???-out vecnet??????x ?????????? + ????? Concerning Julius options -input {mic|rawfile|adinnet|stdin|netaudio|esd|alsa|oss} - ?????????????"-in" ?????????????? ??? - ??????????????????esd ????????? ???? - ???? - - -chunk_size samples - ???????o?????????????????????? - ??(default: 1000) + ?????????????"-in" ?????????????? ??? + ??????????????????esd ????????? ???? + ???? -lv thres - ????????????? 0 ?? 32767 ????????? (default: - 2000) + ????????????? 0 ?? 32767 ????????? + (default: 2000) -zc thres - ??????????????????????????? (default: 60) + ??????????????????????????? (default: + 60) -headmargin msec - ???????????????????? (default: 300) + ???????????????????? (default: 300) -tailmargin msec - ????????}??????????? (default: 400) + ????????}??????????? (default: 400) -zmean - ????????????????????s???????????? - ?????????D + ????????????????????s???????????? + ?????????D -smpFreq Hz - ???????????? (Hz) ??????(default: 16,000) + ???????????? (Hz) ??????(default: 16,000) -48 - 48kHz???????16kHz????????????? ??? 16kHz ?? - ??????????????????? ?????????????? - ? sptk ?? ?????? (Rev. 4.0) + 48kHz???????16kHz????????????? ??? 16kHz ? + ???????????????????? ????????????? + ?? sptk ?? ?????? (Rev. 4.0) -NA devicename - DatLink ????????? (-input netaudio). + DatLink ????????? (-input netaudio). -adport port_number - -input adinnet ???????????? adinnet ?????????? - ??(default: 5530) + -input adinnet ???????????? adinnet ????????? + ???(default: 5530) -nostrip - ??????????????????????????????? ? - "0" ??????????????????Julius ???C?? ???? - ?????????????????D??????????????? - ????C???????????????ゥ???????????? - ???? + ??????????????????????????????? ? + "0" ??????????????????Julius ???C?? ??? + ??????????????????D?????????????? + ?????C???????????????ゥ??????????? + ????? -C jconffile - jconf?????????????????????????W????? + jconf?????????????????????????W????? -plugindir dirlist - ????????????????????????????????? - ??????????? + ????????????????????????????????? + ??????????? ENVIRONMENT VARIABLES ALSADEV - (?????? alsa ???????) ????????????? ??? - ?????"default"? + (?????? alsa ???????) ????????????? ?? + ??????"default"? AUDIODEV - (?????? oss ???????) ????????????? ??? - ?????"/dev/dsp"? + (?????? oss ???????) ????????????? ??? + ?????"/dev/dsp"? + + PORTAUDIO_DEV + (portaudio V19 ???) ????????????? ???????? + ? adinrec ???????O????????Q????D LATENCY_MSEC - Linux (alsa/oss) ??? Windows ??????????????? ?? - ????????????????????????????????CPU - ????????????????????????OS? ??????? - ?????????????OS ????????? ?????????? - ???????????? + Linux (alsa/oss) ??? Windows ??????????????? ?? + ?????????????????????????????? + ??CPU ????????????????????????OS? ??? + ?????????????????OS ????????? ??? + ??????????????????? EXAMPLES ????????????????? "data.0000.wav" ????L???? @@ -202,17 +212,17 @@ adinrec ( 1 ) COPYRIGHT - Copyright (c) 1991-2008 ???? ????コ + Copyright (c) 1991-2013 ???? ????コ Copyright (c) 1997-2000 ????U?????(IPA) - Copyright (c) 2000-2008 ?????????w??? ュ???コ + Copyright (c) 2000-2005 ?????????w??? ュ???コ - Copyright (c) 2005-2008 ??????? Julius????? + Copyright (c) 2005-2013 ??????? Julius????? LICENSE Julius ??????????D - 10/02/2008 ADINTOOL(1) + 19/12/2013 ADINTOOL(1) Index: julius4/adintool/00readme.txt diff -u julius4/adintool/00readme.txt:1.4 julius4/adintool/00readme.txt:1.5 --- julius4/adintool/00readme.txt:1.4 Mon Dec 5 14:39:51 2011 +++ julius4/adintool/00readme.txt Fri Dec 20 01:28:45 2013 @@ -17,7 +17,6 @@ detection based on zerocross number and power (level), and records the detected parts to files or other output devices sucessively. - adintool is a upper version of adinrec with various functions. Supported input device are: microphone input, a speech file, standard tty input, and network socket (called adin-net server mode). Julius @@ -35,156 +34,167 @@ adintool specific options -freq Hz - Set sampling rate in Hz. (default: 16,000) + Set sampling rate in Hz. (default: 16,000) -in inputdev - Audio input device. "mic" to capture via microphone input, "file" - for audio file input, and "stdin" to read raw data from - standard-input. For file input, file name prompt will appear after - startup. Use "adinnet" to make adintool as "adinnet server", - receiving data from client via network socket. Default port number - is 5530, which can be altered by option "-inport". + Audio input device. "mic" to capture via microphone input, "file" + for audio file input, and "stdin" to read raw data from + standard-input. For file input, file name prompt will appear after + startup. Use "adinnet" to make adintool as "adinnet server", + receiving data from client via network socket. Default port number + is 5530, which can be altered by option "-inport". - Alternatively, input device can be set by "-input" option, in which - case you can use plugin input. + Alternatively, input device can be set by "-input" option, in which + case you can use plugin input. -out outputdev - Audio output device store the data. Specify "file" to save to file, - in which the output filename should be given by "-filename". Use - "stdout" to standard out. "adinnet" will make adintool to be an - adinnet client, sending speech data to a server via tcp/ip socket. - When using "adinnet" output, the server name to send data should be - specified by "-server". The default port number is 5530, which can - be changed by "-port" option. + Audio output device store the data. Specify "file" to save to file, + in which the output filename should be given by "-filename". Use + "stdout" to standard out. "adinnet" will make adintool to be an + adinnet client, sending speech data to a server via tcp/ip socket. + "vecnet" will make adintool to be a vecnet client, sending feature + vectors extracted from input to a server via tcp/ip socket. When + using "adinnet" and "vecnet" output, the server name to send data + should be specified by "-server". The default port number is 5530, + which can be changed by "-port" option. -inport num - When adintool becomes adinnet server to receive data (-in adinnet), - set the port number to listen. (default: 5530) + When adintool becomes adinnet server to receive data (-in adinnet), + set the port number to listen. (default: 5530) -server [host] [,host...] - When output to adinnet server (-out adinnet), set the hostname. You - can send to multiple hosts by specifying their hostnames as - comma-delimited list like "host1,host2,host3". + When output to adinnet server (-out adinnet), set the hostname. You + can send to multiple hosts by specifying their hostnames as + comma-delimited list like "host1,host2,host3". -port [num] [,num...] - When adintool send a data to adinnet server (-out adinnet), set the - port number to connect. (default: 5530) For multiple servers, - specify port numbers for all servers like "5530,5530,5531". + When adintool send a data to adinnet server (-out adinnet), set the + port number to connect. (default: 5530) For multiple servers, + specify port numbers for all servers like "5530,5530,5531". -filename file - When output to file (-out file), set the output filename. The actual - file name will be as "file.0000.wav" , "file.0001.wav" and so on, - where the four digit number increases as speech segment detected. - The initial number will be set to 0 by default, which can be changed - by "-startid" option. When using "-oneshot" option to save only the - first segment, the input will be saved as "file". + When output to file (-out file), set the output filename. The + actual file name will be as "file.0000.wav" , "file.0001.wav" and + so on, where the four digit number increases as speech segment + detected. The initial number will be set to 0 by default, which can + be changed by "-startid" option. When using "-oneshot" option to + save only the first segment, the input will be saved as "file". -startid number - At file output, set the initial file number. (default: 0) + At file output, set the initial file number. (default: 0) -oneshot - Exit after the end of first speech segment. + Exit after the end of first speech segment. -nosegment - Do not perform speech detection for input, just treat all the input - as a single valid segment. + Do not perform speech detection for input, just treat all the input + as a single valid segment. -raw - Output as RAW file (no header). + Output as RAW file (no header). -autopause - When output to adinnet server, adintool enter pause state at every - end of speech segment. It will restart when the destination adinnet - server sends it a resume signal. + When output to adinnet server, adintool enter pause state at every + end of speech segment. It will restart when the destination adinnet + server sends it a resume signal. -loosesync - When output to multiple adinnet server, not to do strict - synchronization for restart. By default, when adintool has entered - pause state, it will not restart until resume commands are received - from all servers. This option will allow restart at least one - restart command has arrived. + When output to multiple adinnet server, not to do strict + synchronization for restart. By default, when adintool has entered + pause state, it will not restart until resume commands are received + from all servers. This option will allow restart at least one + restart command has arrived. -rewind msec - When input is a live microphone device, and there has been some - continuing input at the moment adintool resumes, it start recording - backtracking by the specified milliseconds. + When input is a live microphone device, and there has been some + continuing input at the moment adintool resumes, it start recording + backtracking by the specified milliseconds. + + -paramtype parameter_type + When output is a vecnet (-out vecnet), specify parameter type in + HTK format like "MFCC_E_D_N_Z". + + -veclen vector_length + When output is a vecnet (-out vecnet), specify vector length + (dim.). Concerning Julius options -input {mic|rawfile|adinnet|stdin|netaudio|esd|alsa|oss} - Choose speech input source. Specify 'file' or 'rawfile' for waveform - file. On file input, users will be prompted to enter the file name - from stdin. - - 'mic' is to get audio input from a default live microphone device, - and 'adinnet' means receiving waveform data via tcpip network from - an adinnet client. 'netaudio' is from DatLink/NetAudio input, and - 'stdin' means data input from standard input. - - At Linux, you can choose API at run time by specifying alsa, oss and - esd. + Choose speech input source. Specify 'file' or 'rawfile' for + waveform file. On file input, users will be prompted to enter the + file name from stdin. + + 'mic' is to get audio input from a default live microphone device, + and 'adinnet' means receiving waveform data via tcpip network from + an adinnet client. 'netaudio' is from DatLink/NetAudio input, and + 'stdin' means data input from standard input. - -chunk_size samples - Audio fragment size in number of samples. (default: 1000) + At Linux, you can choose API at run time by specifying alsa, oss + and esd. -lv thres - Level threshold for speech input detection. Values should be in - range from 0 to 32767. (default: 2000) + Level threshold for speech input detection. Values should be in + range from 0 to 32767. (default: 2000) -zc thres - Zero crossing threshold per second. Only input that goes over the - level threshold (-lv) will be counted. (default: 60) + Zero crossing threshold per second. Only input that goes over the + level threshold (-lv) will be counted. (default: 60) -headmargin msec - Silence margin at the start of speech segment in milliseconds. - (default: 300) + Silence margin at the start of speech segment in milliseconds. + (default: 300) -tailmargin msec - Silence margin at the end of speech segment in milliseconds. - (default: 400) + Silence margin at the end of speech segment in milliseconds. + (default: 400) -zmean - This option enables DC offset removal. + This option enables DC offset removal. -smpFreq Hz - Set sampling rate in Hz. (default: 16,000) + Set sampling rate in Hz. (default: 16,000) -48 - Record input with 48kHz sampling, and down-sample it to 16kHz - on-the-fly. This option is valid for 16kHz model only. The - down-sampling routine was ported from sptk. (Rev. 4.0) + Record input with 48kHz sampling, and down-sample it to 16kHz + on-the-fly. This option is valid for 16kHz model only. The + down-sampling routine was ported from sptk. (Rev. 4.0) -NA devicename - Host name for DatLink server input (-input netaudio). + Host name for DatLink server input (-input netaudio). -adport port_number - With -input adinnet, specify adinnet port number to listen. - (default: 5530) + With -input adinnet, specify adinnet port number to listen. + (default: 5530) -nostrip - Julius by default removes successive zero samples in input speech - data. This option stop it. + Julius by default removes successive zero samples in input speech + data. This option stop it. -C jconffile - Load a jconf file at here. The content of the jconffile will be - expanded at this point. + Load a jconf file at here. The content of the jconffile will be + expanded at this point. -plugindir dirlist - Specify which directories to load plugin. If several direcotries - exist, specify them by colon-separated list. + Specify which directories to load plugin. If several direcotries + exist, specify them by colon-separated list. ENVIRONMENT VARIABLES ALSADEV - (using mic input with alsa device) specify a capture device name. If - not specified, "default" will be used. + (using mic input with alsa device) specify a capture device name. + If not specified, "default" will be used. AUDIODEV - (using mic input with oss device) specify a capture device path. If - not specified, "/dev/dsp" will be used. + (using mic input with oss device) specify a capture device path. If + not specified, "/dev/dsp" will be used. + + PORTAUDIO_DEV + (portaudio V19) specify the name of capture device to use. See the + instruction output of log at start up how to specify it. LATENCY_MSEC - Try to set input latency of microphone input in milliseconds. - Smaller value will shorten latency but sometimes make process - unstable. Default value will depend on the running OS. + Try to set input latency of microphone input in milliseconds. + Smaller value will shorten latency but sometimes make process + unstable. Default value will depend on the running OS. EXAMPLES Record microphone input to files: "data.0000.wav", "data.0001.wav" and @@ -199,14 +209,14 @@ adinrec ( 1 ) COPYRIGHT - Copyright (c) 1997-2000 Information-technology Promotion Agency, Japan + Copyright (c) 1991-2013 Kawahara Lab., Kyoto University - Copyright (c) 1991-2008 Kawahara Lab., Kyoto University + Copyright (c) 1997-2000 Information-technology Promotion Agency, Japan Copyright (c) 2000-2005 Shikano Lab., Nara Institute of Science and Technology - Copyright (c) 2005-2008 Julius project team, Nagoya Institute of + Copyright (c) 2005-2013 Julius project team, Nagoya Institute of Technology LICENSE @@ -214,4 +224,4 @@ - 10/02/2008 ADINTOOL(1) + 12/19/2013 ADINTOOL(1) From sumomo @ users.sourceforge.jp Fri Dec 20 01:28:46 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Fri, 20 Dec 2013 01:28:46 +0900 Subject: [Julius-cvs 895] CVS update: julius4/libsent Message-ID: <1387470526.785329.2516.nullmailer@users.sourceforge.jp> Index: julius4/libsent/configure diff -u julius4/libsent/configure:1.35 julius4/libsent/configure:1.36 --- julius4/libsent/configure:1.35 Wed Dec 4 19:24:28 2013 +++ julius4/libsent/configure Fri Dec 20 01:28:46 2013 @@ -565,7 +565,7 @@ ac_configure=$ac_aux_dir/configure # This should be Cygnus configure. -LIBSENT_VERSION=4.2.3 +LIBSENT_VERSION=4.3 # specify mic type # Check whether --with-mictype or --without-mictype was given. Index: julius4/libsent/configure.in diff -u julius4/libsent/configure.in:1.35 julius4/libsent/configure.in:1.36 --- julius4/libsent/configure.in:1.35 Wed Dec 4 19:13:00 2013 +++ julius4/libsent/configure.in Fri Dec 20 01:28:46 2013 @@ -3,7 +3,7 @@ dnl Copyright (c) 2005-2013 Julius project team, Nagoya Institute of Technology dnl All rights reserved dnl -dnl $Id: configure.in,v 1.35 2013/12/04 10:13:00 sumomo Exp $ +dnl $Id: configure.in,v 1.36 2013/12/19 16:28:46 sumomo Exp $ dnl dnl Process this file with autoconf to produce a configure script. @@ -11,7 +11,7 @@ AC_CONFIG_HEADER(include/sent/config.h) AC_CONFIG_AUX_DIR(../support) -LIBSENT_VERSION=4.2.3 +LIBSENT_VERSION=4.3 dnl Checks for options # specify mic type From sumomo @ users.sourceforge.jp Fri Dec 20 01:28:46 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Fri, 20 Dec 2013 01:28:46 +0900 Subject: [Julius-cvs 896] CVS update: julius4/jcontrol Message-ID: <1387470526.198312.2487.nullmailer@users.sourceforge.jp> Index: julius4/jcontrol/00readme-ja.txt diff -u julius4/jcontrol/00readme-ja.txt:1.3 julius4/jcontrol/00readme-ja.txt:1.4 --- julius4/jcontrol/00readme-ja.txt:1.3 Thu Oct 2 17:23:47 2008 +++ julius4/jcontrol/00readme-ja.txt Fri Dec 20 01:28:46 2013 @@ -29,10 +29,10 @@ OPTIONS hostname - ???????? + ???????? portnum - ????????????10500? + ????????????10500? COMMANDS jcontrol ??????????????????????? ??????? @@ -40,68 +40,79 @@ ???? pause - Julius??ッ????????????????s?????????? - ???Julius???????????????ッ???s???? ??? - ?????ッ???r????????????????C Julius ??? - ?ッ???I?????????????s??? + Julius??ッ????????????????s?????????? + ???Julius???????????????ッ???s???? ??? + ?????ッ???r????????????????C Julius ?? + ??ッ???I?????????????s??? terminate - pause?????Julius??ッ???????? ????????s?? - ??????????ッ???r????? ???????????C? - ??????????????????????? + pause?????Julius??ッ???????? ????????s?? + ??????????ッ???r????? ???????????C? + ??????????????????????? resume - Julius ???????????????s????ッ??????? + Julius ???????????????s????ッ??????? inputparam arg - ????????????????????????????w?? - "TERMINATE", "PAUSE", "WAIT"??????????? + ????????????????????????????w?? + "TERMINATE", "PAUSE", "WAIT"??????????? version - Julius ??????????????? + Julius ??????????????? status - Julius ?????????(active / sleep) ??????? + Julius ?????????(active / sleep) ??????? ??????ッ?? + graminfo + ????????????????????????????????+ ?? + changegram prefix - ?ッ??? "prefix.dfa" ? "prefix.dict" ????????????? - ?????????????C?????????????? + ??????????ッ??? "prefix.dfa" ? "prefix.dict" ???? + ????????? ?????????????C?????????? + ???? + + ??????????????ッ???C "prefix" ?????ォ?t? + ????? "filename.dict" ???????? addgram prefix - ?ッ????? "prefix.dfa" ? "prefix.dict" ??????????? - ???? + ?ッ????? "prefix.dfa" ? "prefix.dict" ??????????? + ???? + + ??????????????ッ???C "prefix" ?????ォ?t? + ????? "filename.dict" ???????? deletegram gramlist - ??????????????????????D???????? ?? - ????? prefix??????? Julius ?????? GRAMINFO???? - ?? ID ????????????????????C???????ID? - ? ??????????????ID?????????????? + ??????????????????????D???????? ?? + ????? prefix??????? Julius ?????? GRAMINFO??? + ??? ID ????????????????????C?????? + ?ID?? ??????????????ID?????????????? deactivategram gramlist - ????????????????????????????????? - ???????????????????ッ???????I??O?? - ?? ????????? activategram ?????????? - - ??????????????? prefix???????Julius ???? - ?? GRAMINFO?????? ID ??????? ????????????- ?????????ID????????? ???????ID?????? - ???????? + ????????????????????????????????? + ???????????????????ッ???????I??O?? + ?? ????????? activategram ?????????? + + ??????????????? prefix???????Julius ???? + ?? GRAMINFO?????? ID ??????? ???????????+ ??????????ID????????? ???????ID????? + ????????? activategram gramlist - ?????????????????????????? ??????? - ???????? prefix???????Julius ???? ?? GRAMINFO? - ????? ID ??????? ?????????????C????? - ??ID????????? ???????ID??????????? - ??? + ?????????????????????????? ????? + ?????????? prefix???????Julius ???? ?? + GRAMINFO?????? ID ??????? ????????????+ ?????????ID????????? ???????ID?????? + ???????? addword grammar_name_or_id dictfile - dictfile ??????????????????????????? + dictfile ??????????????????????????? syncgram - addgram ? deletegram ????????????????? ????? - ???? + addgram ? deletegram ????????????????? ????? + ???? ??????????? Julius-4 ???????????ッ?????????C ?ッ???? @@ -112,35 +123,35 @@ ??????????????????????????????? listprocess - Julius ???????????ッ?????????????? + Julius ???????????ッ?????????????? currentprocess procname - ???????????????????????????? + ???????????????????????????? shiftprocess - ?????????????????D???????????????? - ??????????????? + ?????????????????D??????????????? + ? ??????????????? addprocess jconffile - ??????ッ???????????????? jconffile ?????- ?????? ?????? LM ??????????????????? - タ?????? ????????????????????Julius??? - ?????? ??????? Julius ????????w??????? - ?? + ??????ッ???????????????? jconffile ?????+ ?????? ?????? LM ????????????????? + ??タ?????? ????????????????????Julius? + ???????? ??????? Julius ????????w????? + ???? - ????? LM ????ッ??????jconffile ???? ?????? - ??? + ????? LM ????ッ??????jconffile ???? ?????? + ??? delprocess procname - ?????????ッ???????????????D + ?????????ッ???????????????D deactivateprocess procname - ?????????ッ????????????????????? ?? - ????????????????ッ????X??????? ???? - ??????? activateprocess ? ????????? + ?????????ッ????????????????????? ?? + ????????????????ッ????X??????? ???? + ??????? activateprocess ? ????????? activateprocess procname - ?????????ッ??????????? + ?????????ッ??????????? EXAMPLES Julius ????????? "> " ???????????????o????@@ -157,17 +168,17 @@ julius ( 1 ) COPYRIGHT - Copyright (c) 1991-2008 ???? ????コ + Copyright (c) 1991-2013 ???? ????コ Copyright (c) 1997-2000 ????U?????(IPA) - Copyright (c) 2000-2008 ?????????w??? ュ???コ + Copyright (c) 2000-2005 ?????????w??? ュ???コ - Copyright (c) 2005-2008 ??????? Julius????? + Copyright (c) 2005-2013 ??????? Julius????? LICENSE Julius ??????????D - 10/02/2008 JCONTROL(1) + 19/12/2013 JCONTROL(1) Index: julius4/jcontrol/00readme.txt diff -u julius4/jcontrol/00readme.txt:1.3 julius4/jcontrol/00readme.txt:1.4 --- julius4/jcontrol/00readme.txt:1.3 Thu Oct 2 17:23:47 2008 +++ julius4/jcontrol/00readme.txt Fri Dec 20 01:28:46 2013 @@ -28,10 +28,10 @@ OPTIONS hostname - Host name where Julius is runnning in module mode. + Host name where Julius is runnning in module mode. portnum - port number (default: 10500) + port number (default: 10500) COMMANDS jcontrol interprets commands from standard input. Below is a list of @@ -39,69 +39,80 @@ Engine control pause - Stop Julius and enter into paused status. In paused status, Julius - will not run recognition even if speech input occurs. When this - command is issued while recognition is running, Julius will stop - after the recognition has been finished. + Stop Julius and enter into paused status. In paused status, Julius + will not run recognition even if speech input occurs. When this + command is issued while recognition is running, Julius will stop + after the recognition has been finished. terminate - Same as pause, but discard the current speech input when received - command in the middle of recognition process. + Same as pause, but discard the current speech input when received + command in the middle of recognition process. resume - Restart Julius that has been paused or terminated. + Restart Julius that has been paused or terminated. inputparam arg - Tell Julius how to deal with speech input in case grammar is changed - just when recognition is running. Specify one: "TERMINATE", "PAUSE" - or "WAIT". + Tell Julius how to deal with speech input in case grammar is + changed just when recognition is running. Specify one: "TERMINATE", + "PAUSE" or "WAIT". version - Tell Julius to send version description string. + Tell Julius to send version description string. status - Tell Julius to send the system status (active / sleep) + Tell Julius to send the system status (active / sleep) Grammar handling + graminfo + Tell the current process to send the list of current grammars to + client. + changegram prefix - Send a new grammar "prefix.dfa" and "prefix.dict", and tell julius - to use it as a new grammar. All the current grammars used in the - current process of Julius will be deleted and replaced to the - specifed grammar. + Send a new grammar "prefix.dfa" and "prefix.dict", and tell julius + to use it as a new grammar. All the current grammars used in the + current process of Julius will be deleted and replaced to the + specifed grammar. + + On isolated word recognition, the dictionary alone should be + specified as "filename.dict" instead of prefix. addgram prefix - Send a new grammar "prefix.dfa" and "prefix.dict" and add it to the - current grammar. + Send a new grammar "prefix.dfa" and "prefix.dict" and add it to the + current grammar. + + On isolated word recognition, the dictionary alone should be + specified as "filename.dict" instead of prefix. deletegram gramlist - Tell Julius to delete existing grammar. The grammar can be specified - by either prefix name or number ID. The number ID can be determined - from the message sent from Julius at each time grammar information - has changed. When want to delete more than one grammar, specify all - of them as comma-sparated. + Tell Julius to delete existing grammar. The grammar can be + specified by either prefix name or number ID. The number ID can be + determined from the message sent from Julius at each time grammar + information has changed. When want to delete more than one grammar, + specify all of them as comma-sparated. deactivategram gramlist - Tell Julius to de-activate a specified grammar. The specified - grammar will still be kept but will not be used for recognition. + Tell Julius to de-activate a specified grammar. The specified + grammar will still be kept but will not be used for recognition. - The target grammar can be specified by either prefix name or number - ID. The number ID can be determined from the message sent from - Julius at each time grammar information has changed. When want to - delete more than one grammar, specify all of them as comma-sparated. + The target grammar can be specified by either prefix name or number + ID. The number ID can be determined from the message sent from + Julius at each time grammar information has changed. When want to + delete more than one grammar, specify all of them as + comma-sparated. activategram gramlist - Tell Julius to activate previously de-activated grammar. The target - grammar can be specified by either prefix name or number ID. The - number ID can be determined from the message sent from Julius at - each time grammar information has changed. When want to delete more - than one grammar, specify all of them as comma-sparated. + Tell Julius to activate previously de-activated grammar. The target + grammar can be specified by either prefix name or number ID. The + number ID can be determined from the message sent from Julius at + each time grammar information has changed. When want to delete more + than one grammar, specify all of them as comma-sparated. addword grammar_name_or_id dictfile - Add the recognition word entries in the specified dictfile to the - specified grammar on current process. + Add the recognition word entries in the specified dictfile to the + specified grammar on current process. syncgram - Force synchronize grammar status, like unix command "sync". + Force synchronize grammar status, like unix command "sync". Process management Julius-4 supports multi-model recognition nad multi decoding. In this @@ -113,34 +124,34 @@ the current process. listprocess - Tell Julius to send the list of existing recognition process. + Tell Julius to send the list of existing recognition process. currentprocess procname - Switch the current process to the process specified by the name. + Switch the current process to the process specified by the name. shiftprocess - Rotate the current process. At each call the current process will be - changed to the next one. + Rotate the current process. At each call the current process will + be changed to the next one. addprocess jconffile - Tell Julisu to load a new recognition process into engine. The - argument jconffile should be a jconf file that contains only one set - of LM options and one SR definition. Note that the file should be - visible on the running Julius, since jcontrol only send the path - name and Julius actually read the jconf file. + Tell Julisu to load a new recognition process into engine. The + argument jconffile should be a jconf file that contains only one + set of LM options and one SR definition. Note that the file should + be visible on the running Julius, since jcontrol only send the path + name and Julius actually read the jconf file. - The new LM and SR process will have the name of the jconffile. + The new LM and SR process will have the name of the jconffile. delprocess procname - Delete the specified recognition process from the engine. + Delete the specified recognition process from the engine. deactivateprocess procname - Tell Julius to temporary stop the specified recognition process. The - stopped process will not be executed for the input until activated - again. + Tell Julius to temporary stop the specified recognition process. + The stopped process will not be executed for the input until + activated again. activateprocess procname - Tell Julius to activate the temporarily stopped process. + Tell Julius to activate the temporarily stopped process. EXAMPLES The dump messages from Julius are output to tty with prefix ">" @@ -155,14 +166,14 @@ julius ( 1 ) COPYRIGHT - Copyright (c) 1997-2000 Information-technology Promotion Agency, Japan + Copyright (c) 1991-2013 Kawahara Lab., Kyoto University - Copyright (c) 1991-2008 Kawahara Lab., Kyoto University + Copyright (c) 1997-2000 Information-technology Promotion Agency, Japan Copyright (c) 2000-2005 Shikano Lab., Nara Institute of Science and Technology - Copyright (c) 2005-2008 Julius project team, Nagoya Institute of + Copyright (c) 2005-2013 Julius project team, Nagoya Institute of Technology LICENSE @@ -170,4 +181,4 @@ - 10/02/2008 JCONTROL(1) + 12/19/2013 JCONTROL(1) From sumomo @ users.sourceforge.jp Fri Dec 20 01:28:45 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Fri, 20 Dec 2013 01:28:45 +0900 Subject: [Julius-cvs 897] CVS update: julius4/gramtools/gram2sapixml Message-ID: <1387470525.927822.2447.nullmailer@users.sourceforge.jp> Index: julius4/gramtools/gram2sapixml/00readme-ja.txt diff -u julius4/gramtools/gram2sapixml/00readme-ja.txt:1.2 julius4/gramtools/gram2sapixml/00readme-ja.txt:1.3 --- julius4/gramtools/gram2sapixml/00readme-ja.txt:1.2 Fri Apr 29 14:09:13 2011 +++ julius4/gramtools/gram2sapixml/00readme-ja.txt Fri Dec 20 01:28:45 2013 @@ -1,6 +1,6 @@ gram2sapixml.pl -GRAM2SAPIXML.PL(1) GRAM2SAPIXML.PL(1) +GRAM2SAPIXML.(1) GRAM2SAPIXML.(1) @@ -37,11 +37,17 @@ ??????????? COPYRIGHT - Copyright (c) 2002 Takashi Sumiyoshi + Copyright (c) 1991-2013 ???? ????コ + + Copyright (c) 1997-2000 ????U?????(IPA) + + Copyright (c) 2000-2005 ?????????w??? ュ???コ + + Copyright (c) 2005-2013 ??????? Julius????? LICENSE Julius ??????????D - 10/02/2008 GRAM2SAPIXML.PL(1) + 19/12/2013 GRAM2SAPIXML.(1) Index: julius4/gramtools/gram2sapixml/00readme.txt diff -u julius4/gramtools/gram2sapixml/00readme.txt:1.2 julius4/gramtools/gram2sapixml/00readme.txt:1.3 --- julius4/gramtools/gram2sapixml/00readme.txt:1.2 Fri Apr 29 14:09:13 2011 +++ julius4/gramtools/gram2sapixml/00readme.txt Fri Dec 20 01:28:45 2013 @@ -1,6 +1,6 @@ gram2sapixml.pl -GRAM2SAPIXML.PL(1) GRAM2SAPIXML.PL(1) +GRAM2SAPIXML.(1) GRAM2SAPIXML.(1) @@ -37,11 +37,19 @@ application. COPYRIGHT - Copyright (c) 2002 Takashi Sumiyoshi + Copyright (c) 1991-2013 Kawahara Lab., Kyoto University + + Copyright (c) 1997-2000 Information-technology Promotion Agency, Japan + + Copyright (c) 2000-2005 Shikano Lab., Nara Institute of Science and + Technology + + Copyright (c) 2005-2013 Julius project team, Nagoya Institute of + Technology LICENSE The same as Julius. - 10/02/2008 GRAM2SAPIXML.PL(1) + 12/19/2013 GRAM2SAPIXML.(1) From sumomo @ users.sourceforge.jp Fri Dec 20 01:28:45 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Fri, 20 Dec 2013 01:28:45 +0900 Subject: [Julius-cvs 898] CVS update: julius4/gramtools/dfa_minimize Message-ID: <1387470525.794217.2427.nullmailer@users.sourceforge.jp> Index: julius4/gramtools/dfa_minimize/00readme-ja.txt diff -u julius4/gramtools/dfa_minimize/00readme-ja.txt:1.1 julius4/gramtools/dfa_minimize/00readme-ja.txt:1.2 --- julius4/gramtools/dfa_minimize/00readme-ja.txt:1.1 Thu Oct 2 17:23:46 2008 +++ julius4/gramtools/dfa_minimize/00readme-ja.txt Fri Dec 20 01:28:45 2013 @@ -23,7 +23,7 @@ OPTIONS -o outfile - ??t?????????? + ??t?????????? EXAMPLES foo.dfa ??????bar.dfa ? ????? @@ -33,17 +33,17 @@ mkdfa.pl ( 1 ) COPYRIGHT - Copyright (c) 1991-2008 ???? ????コ + Copyright (c) 1991-2013 ???? ????コ Copyright (c) 1997-2000 ????U?????(IPA) - Copyright (c) 2000-2008 ?????????w??? ュ???コ + Copyright (c) 2000-2005 ?????????w??? ュ???コ - Copyright (c) 2005-2008 ??????? Julius????? + Copyright (c) 2005-2013 ??????? Julius????? LICENSE Julius ??????????D - 10/02/2008 DFA_MINIMIZE(1) + 19/12/2013 DFA_MINIMIZE(1) Index: julius4/gramtools/dfa_minimize/00readme.txt diff -u julius4/gramtools/dfa_minimize/00readme.txt:1.1 julius4/gramtools/dfa_minimize/00readme.txt:1.2 --- julius4/gramtools/dfa_minimize/00readme.txt:1.1 Thu Oct 2 17:23:46 2008 +++ julius4/gramtools/dfa_minimize/00readme.txt Fri Dec 20 01:28:45 2013 @@ -21,7 +21,7 @@ OPTIONS -o outfile - Output file. If not specified output to standard output. + Output file. If not specified output to standard output. EXAMPLES Minimize foo.dfa to bar.dfa: @@ -31,14 +31,14 @@ mkdfa.pl ( 1 ) COPYRIGHT - Copyright (c) 1997-2000 Information-technology Promotion Agency, Japan + Copyright (c) 1991-2013 Kawahara Lab., Kyoto University - Copyright (c) 1991-2008 Kawahara Lab., Kyoto University + Copyright (c) 1997-2000 Information-technology Promotion Agency, Japan Copyright (c) 2000-2005 Shikano Lab., Nara Institute of Science and Technology - Copyright (c) 2005-2008 Julius project team, Nagoya Institute of + Copyright (c) 2005-2013 Julius project team, Nagoya Institute of Technology LICENSE @@ -46,4 +46,4 @@ - 10/02/2008 DFA_MINIMIZE(1) + 12/19/2013 DFA_MINIMIZE(1) From sumomo @ users.sourceforge.jp Fri Dec 20 01:28:45 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Fri, 20 Dec 2013 01:28:45 +0900 Subject: [Julius-cvs 899] CVS update: julius4/gramtools/dfa_determinize Message-ID: <1387470525.719805.2417.nullmailer@users.sourceforge.jp> Index: julius4/gramtools/dfa_determinize/00readme-ja.txt diff -u julius4/gramtools/dfa_determinize/00readme-ja.txt:1.1 julius4/gramtools/dfa_determinize/00readme-ja.txt:1.2 --- julius4/gramtools/dfa_determinize/00readme-ja.txt:1.1 Thu Oct 2 17:23:46 2008 +++ julius4/gramtools/dfa_determinize/00readme-ja.txt Fri Dec 20 01:28:45 2013 @@ -15,13 +15,12 @@ dfa_determinize ??.dfa ??????????? .dfa ????????? ??o???????D????? -o ????????????????? - mkdfa.pl ?????DFA???????????C ??Cmkdfa.pl ???? ?? .dfa ???????? ????????????????? OPTIONS -o outfile - ??t?????????? + ??t?????????? EXAMPLES foo.dfa ?????? bar.dfa ? ????? @@ -32,17 +31,17 @@ dfa_minimize ( 1 ) COPYRIGHT - Copyright (c) 1991-2008 ???? ????コ + Copyright (c) 1991-2013 ???? ????コ Copyright (c) 1997-2000 ????U?????(IPA) - Copyright (c) 2000-2008 ?????????w??? ュ???コ + Copyright (c) 2000-2005 ?????????w??? ュ???コ - Copyright (c) 2005-2008 ??????? Julius????? + Copyright (c) 2005-2013 ??????? Julius????? LICENSE Julius ??????????D - 10/02/2008 DFA_DETERMINIZE(1) + 19/12/2013 DFA_DETERMINIZE(1) Index: julius4/gramtools/dfa_determinize/00readme.txt diff -u julius4/gramtools/dfa_determinize/00readme.txt:1.1 julius4/gramtools/dfa_determinize/00readme.txt:1.2 --- julius4/gramtools/dfa_determinize/00readme.txt:1.1 Thu Oct 2 17:23:46 2008 +++ julius4/gramtools/dfa_determinize/00readme.txt Fri Dec 20 01:28:45 2013 @@ -22,7 +22,7 @@ OPTIONS -o outfile - Outout file. If not specified, output to stdout. + Outout file. If not specified, output to stdout. EXAMPLES Determinize foo.dfa to bar.dfa: @@ -33,14 +33,14 @@ dfa_minimize ( 1 ) COPYRIGHT - Copyright (c) 1997-2000 Information-technology Promotion Agency, Japan + Copyright (c) 1991-2013 Kawahara Lab., Kyoto University - Copyright (c) 1991-2008 Kawahara Lab., Kyoto University + Copyright (c) 1997-2000 Information-technology Promotion Agency, Japan Copyright (c) 2000-2005 Shikano Lab., Nara Institute of Science and Technology - Copyright (c) 2005-2008 Julius project team, Nagoya Institute of + Copyright (c) 2005-2013 Julius project team, Nagoya Institute of Technology LICENSE @@ -48,4 +48,4 @@ - 10/02/2008 DFA_DETERMINIZE(1) + 12/19/2013 DFA_DETERMINIZE(1) From sumomo @ users.sourceforge.jp Fri Dec 20 01:28:47 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Fri, 20 Dec 2013 01:28:47 +0900 Subject: [Julius-cvs 900] CVS update: julius4/mkgshmm Message-ID: <1387470527.245681.2634.nullmailer@users.sourceforge.jp> Index: julius4/mkgshmm/00readme-ja.txt diff -u julius4/mkgshmm/00readme-ja.txt:1.3 julius4/mkgshmm/00readme-ja.txt:1.4 --- julius4/mkgshmm/00readme-ja.txt:1.3 Thu Oct 2 17:23:49 2008 +++ julius4/mkgshmm/00readme-ja.txt Fri Dec 20 01:28:47 2013 @@ -35,17 +35,17 @@ julius ( 1 ) COPYRIGHT - Copyright (c) 1991-2008 ???? ????コ + Copyright (c) 1991-2013 ???? ????コ Copyright (c) 1997-2000 ????U?????(IPA) - Copyright (c) 2000-2008 ?????????w??? ュ???コ + Copyright (c) 2000-2005 ?????????w??? ュ???コ - Copyright (c) 2005-2008 ??????? Julius????? + Copyright (c) 2005-2013 ??????? Julius????? LICENSE Julius ??????????D - 10/02/2008 MKGSHMM(1) + 19/12/2013 MKGSHMM(1) Index: julius4/mkgshmm/00readme.txt diff -u julius4/mkgshmm/00readme.txt:1.2 julius4/mkgshmm/00readme.txt:1.3 --- julius4/mkgshmm/00readme.txt:1.2 Thu Oct 2 17:23:49 2008 +++ julius4/mkgshmm/00readme.txt Fri Dec 20 01:28:47 2013 @@ -32,14 +32,14 @@ julius ( 1 ) COPYRIGHT - Copyright (c) 1997-2000 Information-technology Promotion Agency, Japan + Copyright (c) 1991-2013 Kawahara Lab., Kyoto University - Copyright (c) 1991-2008 Kawahara Lab., Kyoto University + Copyright (c) 1997-2000 Information-technology Promotion Agency, Japan Copyright (c) 2000-2005 Shikano Lab., Nara Institute of Science and Technology - Copyright (c) 2005-2008 Julius project team, Nagoya Institute of + Copyright (c) 2005-2013 Julius project team, Nagoya Institute of Technology LICENSE @@ -47,4 +47,4 @@ - 10/02/2008 MKGSHMM(1) + 12/19/2013 MKGSHMM(1) From sumomo @ users.sourceforge.jp Fri Dec 20 01:28:47 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Fri, 20 Dec 2013 01:28:47 +0900 Subject: [Julius-cvs 901] CVS update: julius4/mkbingram Message-ID: <1387470527.100709.2610.nullmailer@users.sourceforge.jp> Index: julius4/mkbingram/00readme-ja.txt diff -u julius4/mkbingram/00readme-ja.txt:1.4 julius4/mkbingram/00readme-ja.txt:1.5 --- julius4/mkbingram/00readme-ja.txt:1.4 Mon Dec 5 14:39:51 2011 +++ julius4/mkbingram/00readme-ja.txt Fri Dec 20 01:28:47 2013 @@ -41,6 +41,9 @@ ???mkbingram ? gzip ?????ARPA ?????????????? ?? + ???????? 4.2.3??????N-gram???????????? ??? + ????? + ????? 3.x ???????????N-gram?????? 4.0 ????? ??mkbingram ? -d ???????????????ョ ????????? ョ????????????????4.0 ??? mkbingram ???????? @@ -49,19 +52,23 @@ OPTIONS -nlr forward_ngram.arpa - ????left-to-right??ARPA?ョ N-gram ????????? + ????left-to-right??ARPA?ョ N-gram ????????? -nrl backward_ngram.arpa - ?????right-to-left??ARPA?ョ N-gram ????????? + ?????right-to-left??ARPA?ョ N-gram ????????? -d old_bingram_file - ????N-gram?????????????ョ????? + ????N-gram?????????????ョ????? -swap - ???? ????? ??????? + ???? ????? ??????? + + -c from to + ????N-gram??????????????from, to???????? + ????? output_bingram_file - ????o???N-gram????? + ????o???N-gram????? EXAMPLES ARPA?ョ? N-gram ??????ョ?????????+?????? @@ -73,17 +80,17 @@ mkbinhmm ( 1 ) COPYRIGHT - Copyright (c) 1991-2008 ???? ????コ + Copyright (c) 1991-2013 ???? ????コ Copyright (c) 1997-2000 ????U?????(IPA) - Copyright (c) 2000-2008 ?????????w??? ュ???コ + Copyright (c) 2000-2005 ?????????w??? ュ???コ - Copyright (c) 2005-2008 ??????? Julius????? + Copyright (c) 2005-2013 ??????? Julius????? LICENSE Julius ??????????D - 02/11/2009 MKBINGRAM(1) + 19/12/2013 MKBINGRAM(1) Index: julius4/mkbingram/00readme.txt diff -u julius4/mkbingram/00readme.txt:1.4 julius4/mkbingram/00readme.txt:1.5 --- julius4/mkbingram/00readme.txt:1.4 Mon Dec 5 14:39:51 2011 +++ julius4/mkbingram/00readme.txt Fri Dec 20 01:28:47 2013 @@ -42,6 +42,9 @@ be trained in the same corpus with same parameters (i.e. cut-off thresholds), with same vocabulary. + The character code in binary N-gram can be converted from version 4.2.3 + or later + The old binary N-gram produced by mkbingram of version 3.x and earlier can be used in Julius-4, but you can convert the old version to the new version by specifying it as input of current mkbingram by option "-d". @@ -51,21 +54,25 @@ OPTIONS -nlr forward_ngram.arpa - Read in a forward (left-to-right) word N-gram file in ARPA standard - format. + Read in a forward (left-to-right) word N-gram file in ARPA standard + format. -nrl backward_ngram.arpa - Read in a backward (right-to-left) word N-gram file in ARPA standard - format. + Read in a backward (right-to-left) word N-gram file in ARPA + standard format. -d old_bingram_file - Read in a binary N-gram file. + Read in a binary N-gram file. -swap - Swap BOS word and EOS word in N-gram. + Swap BOS word and EOS word in N-gram. + + -c from to + Convert character code in binary N-gram. ("from", "to" are string + that intend character code) output_bingram_file - binary N-gram file name to output. + binary N-gram file name to output. EXAMPLES Convert a set of forward and backward N-gram in ARPA format into Julius @@ -79,14 +86,14 @@ mkbinhmmlist ( 1 ) COPYRIGHT - Copyright (c) 1997-2000 Information-technology Promotion Agency, Japan + Copyright (c) 1991-2013 Kawahara Lab., Kyoto University - Copyright (c) 1991-2008 Kawahara Lab., Kyoto University + Copyright (c) 1997-2000 Information-technology Promotion Agency, Japan Copyright (c) 2000-2005 Shikano Lab., Nara Institute of Science and Technology - Copyright (c) 2005-2008 Julius project team, Nagoya Institute of + Copyright (c) 2005-2013 Julius project team, Nagoya Institute of Technology LICENSE @@ -94,4 +101,4 @@ - 02/11/2009 MKBINGRAM(1) + 12/19/2013 MKBINGRAM(1) From sumomo @ users.sourceforge.jp Fri Dec 20 01:28:45 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Fri, 20 Dec 2013 01:28:45 +0900 Subject: [Julius-cvs 902] CVS update: julius4/generate-ngram Message-ID: <1387470525.574589.2391.nullmailer@users.sourceforge.jp> Index: julius4/generate-ngram/00readme-ja.txt diff -u julius4/generate-ngram/00readme-ja.txt:1.1 julius4/generate-ngram/00readme-ja.txt:1.2 --- julius4/generate-ngram/00readme-ja.txt:1.1 Thu Oct 2 17:23:45 2008 +++ julius4/generate-ngram/00readme-ja.txt Fri Dec 20 01:28:45 2013 @@ -1,4 +1,4 @@ - generate-ngram + generate?ngram GENERATE-NGRAM(1) GENERATE-NGRAM(1) @@ -18,43 +18,43 @@ OPTIONS -n num - ??????????????????10? + ??????????????????10? -N - ???? N-gram ?????????????????????????? - ?????????3-gram ?? 3?? + ???? N-gram ????????????????????????? + ??????????3-gram ?? 3?? -bos - ?????????????????? + ?????????????????? -eos - ???L?????????????? + ???L?????????????? -ignore - ?????????P?????????????? + ?????????P?????????????? -v - ???o????? + ???o????? -debug - ????????s?? + ????????s?? SEE ALSO julius ( 1 ) , mkbingram ( 1 ) COPYRIGHT - Copyright (c) 1991-2008 ???? ????コ + Copyright (c) 1991-2013 ???? ????コ Copyright (c) 1997-2000 ????U?????(IPA) - Copyright (c) 2000-2008 ?????????w??? ュ???コ + Copyright (c) 2000-2005 ?????????w??? ュ???コ - Copyright (c) 2005-2008 ??????? Julius????? + Copyright (c) 2005-2013 ??????? Julius????? LICENSE Julius ??????????D - 10/02/2008 GENERATE-NGRAM(1) + 19/12/2013 GENERATE-NGRAM(1) Index: julius4/generate-ngram/00readme.txt diff -u julius4/generate-ngram/00readme.txt:1.1 julius4/generate-ngram/00readme.txt:1.2 --- julius4/generate-ngram/00readme.txt:1.1 Thu Oct 2 17:23:45 2008 +++ julius4/generate-ngram/00readme.txt Fri Dec 20 01:28:45 2013 @@ -1,4 +1,4 @@ - generate-ngram + generate??gram GENERATE-NGRAM(1) GENERATE-NGRAM(1) @@ -18,40 +18,40 @@ OPTIONS -n num - Number of sentences to generate (default: 10) + Number of sentences to generate (default: 10) -N - Specify which length of N-gram to use (default: available max in the - given model) + Specify which length of N-gram to use (default: available max in + the given model) -bos - Beginning-of-sentence word (default: "") + Beginning-of-sentence word (default: "") -eos - End-of-sentence word (default: "") + End-of-sentence word (default: "") -ignore - Specify a word to be supressed from output (default: " Index: julius4/mkbinhmm/00readme-ja.txt diff -u julius4/mkbinhmm/00readme-ja.txt:1.3 julius4/mkbinhmm/00readme-ja.txt:1.4 --- julius4/mkbinhmm/00readme-ja.txt:1.3 Thu Oct 2 17:23:48 2008 +++ julius4/mkbinhmm/00readme-ja.txt Fri Dec 20 01:28:47 2013 @@ -29,16 +29,16 @@ OPTIONS -htkconf HTKConfigFile - ????????o?????HTK Config????????????? ? - ???C??????????t??????????????? ??? - ????????????????D + ????????o?????HTK Config????????????? ? + ???C??????????t??????????????? ??? + ????????????????D hmmdefs_file - ??????????????? (MMF)?HTK ASCII ?ョ????? - Julius ?????ョ? + ??????????????? (MMF)?HTK ASCII ?ョ????? + Julius ?????ョ? hmmdefs_file - Julius??????ョ????????D + Julius??????ョ????????D EXAMPLES HTK ASCII ?ョ? HMM ????????ョ?????? @@ -50,17 +50,17 @@ mkbingram ( 1 ) COPYRIGHT - Copyright (c) 1991-2008 ???? ????コ + Copyright (c) 1991-2013 ???? ????コ Copyright (c) 1997-2000 ????U?????(IPA) - Copyright (c) 2000-2008 ?????????w??? ュ???コ + Copyright (c) 2000-2005 ?????????w??? ュ???コ - Copyright (c) 2005-2008 ??????? Julius????? + Copyright (c) 2005-2013 ??????? Julius????? LICENSE Julius ??????????D - 10/02/2008 MKBINHMM(1) + 19/12/2013 MKBINHMM(1) Index: julius4/mkbinhmm/00readme-mkbinhmmlist-ja.txt diff -u /dev/null julius4/mkbinhmm/00readme-mkbinhmmlist-ja.txt:1.1 --- /dev/null Fri Dec 20 01:28:47 2013 +++ julius4/mkbinhmm/00readme-mkbinhmmlist-ja.txt Fri Dec 20 01:28:47 2013 @@ -0,0 +1,69 @@ + mkbinhmmlist + +MKBINHMMLIST(1) MKBINHMMLIST(1) + + + +?? + mkbinhmmlist + - HMMList ??????????ョ??? + +?? + mkbinhmmlist {hmmdefs_file} {HMMList_file} {output_binhmmlist_file} + +DESCRIPTION + mkbinhmmlist ??????????????????? HMMList ????? + ?????ョ??????????e????ョ????????????? + Julius????????????????? + + ?????HMMList ????????????g???????????? + hmmdefs_file ??????HTK ASCII?ョ / Julius?????ョ????? + ??? + + Julius ????????????e????ョ???? "-hlist" ????? + ??????? ?????ョ??????ョ????? Julius ??ゥ??? + ?????? + + ????? 4.2?????????????pseudo phone ???????? + ?????????????Julius?????????????????? ? + ?????????????????????????????????? + ?????? mkbinhmmlist ????? binhmmlist ?????????? + ?? ??????????? + + mkbinhmmlist ? gzip ?????t??????????????? + +OPTIONS + hmmdefs_file + ????????????HTK ASCII ?ョ?????Julius ??? ?? + ョ? + + HMMList_file + ?????HMMList ????? + + output_binhmmlist_file + ??????ulius??????ョHMMList???????? ?????+ ??????D + +EXAMPLES + HMMList ???? logicalTri??????ョ????? logicalTri.bin ?? + ???? + +SEE ALSO + julius ( 1 ) , + mkbinhmm ( 1 ) + +COPYRIGHT + Copyright (c) 1991-2013 ???? ????コ + + Copyright (c) 1997-2000 ????U?????(IPA) + + Copyright (c) 2000-2005 ?????????w??? ュ???コ + + Copyright (c) 2005-2013 ??????? Julius????? + +LICENSE + Julius ??????????D + + + + 19/12/2013 MKBINHMMLIST(1) Index: julius4/mkbinhmm/00readme-mkbinhmmlist.txt diff -u /dev/null julius4/mkbinhmm/00readme-mkbinhmmlist.txt:1.1 --- /dev/null Fri Dec 20 01:28:47 2013 +++ julius4/mkbinhmm/00readme-mkbinhmmlist.txt Fri Dec 20 01:28:47 2013 @@ -0,0 +1,69 @@ + mkbinhmmlist + +MKBINHMMLIST(1) MKBINHMMLIST(1) + + + +NAME + mkbinhmmlist + - convert HMMList file into binary format + +SYNOPSIS + mkbinhmmlist {hmmdefs_file} {HMMList_file} {output_binhmmlist_file} + +DESCRIPTION + mkbinhmmlist converts a HMMList file to binary format. Since the index + trees for lookup are also stored in the binary format, it will speed up + the startup of Julius, namely when using big HMMList file. + + For conversion, HMM definition file hmmdefs_file that will be used + together at Julius needs to be specified. The format of the HMM + definition file can be either ascii or Julius binary format. + + The output binary file can be used in Julius as the same by "-hlist". + The format wil be auto-detected by Julius. + + The pseudo phone extracted form acoustic model is outputed by version + 4.2 or later. This cause faster starting Julius. However, It is + required that using it with created acoustic model. Also, binhmmlist + file created by mkbinhmmlist of this version or later cannot be used in + earlier version. + + mkbinhmmlist can read gzipped file. + +OPTIONS + hmmdefs_file + Acoustic HMM definition file, in HMM ascii format or Julius binary + format. + + HMMList_file + Source HMMList file + + output_binhmmlist_file + Output file, will be overwritten if already exist. + +EXAMPLES + Convert a HMMList file logicalTri into binary format and store to + logicalTri.bin: + +SEE ALSO + julius ( 1 ) , + mkbinhmm ( 1 ) + +COPYRIGHT + Copyright (c) 1991-2013 Kawahara Lab., Kyoto University + + Copyright (c) 1997-2000 Information-technology Promotion Agency, Japan + + Copyright (c) 2000-2005 Shikano Lab., Nara Institute of Science and + Technology + + Copyright (c) 2005-2013 Julius project team, Nagoya Institute of + Technology + +LICENSE + The same as Julius. + + + + 12/19/2013 MKBINHMMLIST(1) Index: julius4/mkbinhmm/00readme.txt diff -u julius4/mkbinhmm/00readme.txt:1.3 julius4/mkbinhmm/00readme.txt:1.4 --- julius4/mkbinhmm/00readme.txt:1.3 Thu Oct 2 17:23:48 2008 +++ julius4/mkbinhmm/00readme.txt Fri Dec 20 01:28:47 2013 @@ -33,20 +33,19 @@ already has acoustic analysis parameters embedded, they will be overridden by the specified values. - mkbinhmm can read gzipped file as input. OPTIONS -htkconf HTKConfigFile - HTK Config file you used at training time. If specified, the values - are embedded to the output file. + HTK Config file you used at training time. If specified, the values + are embedded to the output file. hmmdefs_file - The source HMm definitino file in HTK ascii format or Julius binary - format. + The source HMm definitino file in HTK ascii format or Julius binary + format. hmmdefs_file - Output file. + Output file. EXAMPLES Convert HTK ascii format HMM definition file into Julius binary file: @@ -60,14 +59,14 @@ mkbinhmmlist ( 1 ) COPYRIGHT - Copyright (c) 1997-2000 Information-technology Promotion Agency, Japan + Copyright (c) 1991-2013 Kawahara Lab., Kyoto University - Copyright (c) 1991-2008 Kawahara Lab., Kyoto University + Copyright (c) 1997-2000 Information-technology Promotion Agency, Japan Copyright (c) 2000-2005 Shikano Lab., Nara Institute of Science and Technology - Copyright (c) 2005-2008 Julius project team, Nagoya Institute of + Copyright (c) 2005-2013 Julius project team, Nagoya Institute of Technology LICENSE @@ -75,4 +74,4 @@ - 10/02/2008 MKBINHMM(1) + 12/19/2013 MKBINHMM(1) From sumomo @ users.sourceforge.jp Fri Dec 20 01:28:45 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Fri, 20 Dec 2013 01:28:45 +0900 Subject: [Julius-cvs 904] CVS update: julius4/gramtools/accept_check Message-ID: <1387470525.642635.2407.nullmailer@users.sourceforge.jp> Index: julius4/gramtools/accept_check/00readme-ja.txt diff -u julius4/gramtools/accept_check/00readme-ja.txt:1.1 julius4/gramtools/accept_check/00readme-ja.txt:1.2 --- julius4/gramtools/accept_check/00readme-ja.txt:1.1 Thu Oct 2 17:23:45 2008 +++ julius4/gramtools/accept_check/00readme-ja.txt Fri Dec 20 01:28:45 2013 @@ -31,30 +31,30 @@ OPTIONS -t - ???????????????????D + ???????????????????D -s spname - ????????????????????????? (default: "sp") + ????????????????????????? (default: "sp") -v - ??????D + ??????D EXAMPLES vfr (?????????????) ??タ??? - % accept_check vfr - Reading in dictionary...done - Reading in DFA grammar...done - Mapping dict item <-> DFA terminal (category)...done - Reading in term file (optional)...done - 42 categories, 99 words - DFA has 135 nodes and 198 arcs - ----- - please input word sequence>silB ? ? ?? ??? silE - wseq: silB ? ? ?? ??? silE - cate: NS_B COLOR_N (NI|NI_AT) SURU_V KUDASAI_V NS_E - accepted - please input word sequence> + % accept_check vfr + Reading in dictionary...done + Reading in DFA grammar...done + Mapping dict item <-> DFA terminal (category)...done + Reading in term file (optional)...done + 42 categories, 99 words + DFA has 135 nodes and 198 arcs + ----- + please input word sequence>silB ? ? ?? ??? silE + wseq: silB ? ? ?? ??? silE + cate: NS_B COLOR_N (NI|NI_AT) SURU_V KUDASAI_V NS_E + accepted + please input word sequence> SEE ALSO @@ -63,17 +63,17 @@ nextword ( 1 ) COPYRIGHT - Copyright (c) 1991-2008 ???? ????コ + Copyright (c) 1991-2013 ???? ????コ Copyright (c) 1997-2000 ????U?????(IPA) - Copyright (c) 2000-2008 ?????????w??? ュ???コ + Copyright (c) 2000-2005 ?????????w??? ュ???コ - Copyright (c) 2005-2008 ??????? Julius????? + Copyright (c) 2005-2013 ??????? Julius????? LICENSE Julius ??????????D - 10/02/2008 ACCEPT_CHECK(1) + 19/12/2013 ACCEPT_CHECK(1) Index: julius4/gramtools/accept_check/00readme.txt diff -u julius4/gramtools/accept_check/00readme.txt:1.1 julius4/gramtools/accept_check/00readme.txt:1.2 --- julius4/gramtools/accept_check/00readme.txt:1.1 Thu Oct 2 17:23:45 2008 +++ julius4/gramtools/accept_check/00readme.txt Fri Dec 20 01:28:45 2013 @@ -31,29 +31,29 @@ OPTIONS -t - Use category name as input instead of word. + Use category name as input instead of word. -s spname - Short-pause word name to be skipped. (default: "sp") + Short-pause word name to be skipped. (default: "sp") -v - Debug output. + Debug output. EXAMPLES An output for "date" grammar: - % echo ' NEXT SUNDAY ' | accept_check date - Reading in dictionary... - 143 words...done - Reading in DFA grammar...done - Mapping dict item <-> DFA terminal (category)...done - Reading in term file (optional)...done - 27 categories, 143 words - DFA has 35 nodes and 71 arcs - ----- - wseq: NEXT SUNDAY - cate: NS_B (NEXT|NEXT) (DAYOFWEEK|DAYOFWEEK|DAY|DAY) NS_E - accepted + % echo ' NEXT SUNDAY ' | accept_check date + Reading in dictionary... + 143 words...done + Reading in DFA grammar...done + Mapping dict item <-> DFA terminal (category)...done + Reading in term file (optional)...done + 27 categories, 143 words + DFA has 35 nodes and 71 arcs + ----- + wseq: NEXT SUNDAY + cate: NS_B (NEXT|NEXT) (DAYOFWEEK|DAYOFWEEK|DAY|DAY) NS_E + accepted SEE ALSO @@ -62,14 +62,14 @@ nextword ( 1 ) COPYRIGHT - Copyright (c) 1997-2000 Information-technology Promotion Agency, Japan + Copyright (c) 1991-2013 Kawahara Lab., Kyoto University - Copyright (c) 1991-2008 Kawahara Lab., Kyoto University + Copyright (c) 1997-2000 Information-technology Promotion Agency, Japan Copyright (c) 2000-2005 Shikano Lab., Nara Institute of Science and Technology - Copyright (c) 2005-2008 Julius project team, Nagoya Institute of + Copyright (c) 2005-2013 Julius project team, Nagoya Institute of Technology LICENSE @@ -77,4 +77,4 @@ - 10/02/2008 ACCEPT_CHECK(1) + 12/19/2013 ACCEPT_CHECK(1) From sumomo @ users.sourceforge.jp Fri Dec 20 01:28:46 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Fri, 20 Dec 2013 01:28:46 +0900 Subject: [Julius-cvs 905] CVS update: julius4/gramtools/nextword Message-ID: <1387470526.062703.2467.nullmailer@users.sourceforge.jp> Index: julius4/gramtools/nextword/00readme-ja.txt diff -u julius4/gramtools/nextword/00readme-ja.txt:1.1 julius4/gramtools/nextword/00readme-ja.txt:1.2 --- julius4/gramtools/nextword/00readme-ja.txt:1.1 Thu Oct 2 17:23:47 2008 +++ julius4/gramtools/nextword/00readme-ja.txt Fri Dec 20 01:28:45 2013 @@ -25,41 +25,41 @@ OPTIONS -t - ???????????????????D + ???????????????????D -r - ??????????D + ??????????D -s spname - ????????????????????????? (default: "sp") + ????????????????????????? (default: "sp") -v - ??????D + ??????D EXAMPLES vfr (?????????????) ??タ??? - % nextword vfr - Reading in dictionary...done - Reading in DFA grammar...done - Mapping dict item <-> DFA terminal (category)...done - Reading in term file (optional)...done - 42 categories, 99 words - DFA has 135 nodes and 198 arcs - ----- - wseq > ? ?? ??? silE - [wseq: ? ?? ??? silE] - [cate: (NI|NI_AT) SURU_V KUDASAI_V NS_E] - PREDICTED CATEGORIES/WORDS: - KEIDOU_A (?? ?? ) - BANGOU_N (? ) - HUKU_N (? ?? ?? ) - PATTERN_N (???? ???ネ ...) - GARA_N (? ) - KANZI_N (?? ) - IRO_N (? ) - COLOR_N (? ? ? ...) - wseq > + % nextword vfr + Reading in dictionary...done + Reading in DFA grammar...done + Mapping dict item <-> DFA terminal (category)...done + Reading in term file (optional)...done + 42 categories, 99 words + DFA has 135 nodes and 198 arcs + ----- + wseq > ? ?? ??? silE + [wseq: ? ?? ??? silE] + [cate: (NI|NI_AT) SURU_V KUDASAI_V NS_E] + PREDICTED CATEGORIES/WORDS: + KEIDOU_A (?? ?? ) + BANGOU_N (? ) + HUKU_N (? ?? ?? ) + PATTERN_N (???? ???ネ ...) + GARA_N (? ) + KANZI_N (?? ) + IRO_N (? ) + COLOR_N (? ? ? ...) + wseq > SEE ALSO @@ -68,17 +68,17 @@ accept_check ( 1 ) COPYRIGHT - Copyright (c) 1991-2008 ???? ????コ + Copyright (c) 1991-2013 ???? ????コ Copyright (c) 1997-2000 ????U?????(IPA) - Copyright (c) 2000-2008 ?????????w??? ュ???コ + Copyright (c) 2000-2005 ?????????w??? ュ???コ - Copyright (c) 2005-2008 ??????? Julius????? + Copyright (c) 2005-2013 ??????? Julius????? LICENSE Julius ??????????D - 10/02/2008 NEXTWORD(1) + 19/12/2013 NEXTWORD(1) Index: julius4/gramtools/nextword/00readme.txt diff -u julius4/gramtools/nextword/00readme.txt:1.1 julius4/gramtools/nextword/00readme.txt:1.2 --- julius4/gramtools/nextword/00readme.txt:1.1 Thu Oct 2 17:23:47 2008 +++ julius4/gramtools/nextword/00readme.txt Fri Dec 20 01:28:46 2013 @@ -15,7 +15,6 @@ Given a partial (part of) sentence from the end, it outputs the next words allowed in the specified grammar. - .dfa, .dict and .term files are needed to execute. They can be generated from .grammar and .voca file by mkdfa.pl. @@ -24,38 +23,38 @@ OPTIONS -t - Input / Output in category name. (default: word) + Input / Output in category name. (default: word) -r - Enter in reverse order + Enter in reverse order -s spname - the name string of short-pause word to be supressed (default: "sp") + the name string of short-pause word to be supressed (default: "sp") -v - Debug output. + Debug output. EXAMPLES Exmple output of a sample grammar "fruit": - % nextword fruit - Stat: init_voca: read 36 words - Reading in term file (optional)...done - 15 categories, 36 words - DFA has 26 nodes and 42 arcs - ----- - command completion is disabled - ----- - wseq > A BANANA - [wseq: A BANANA ] - [cate: (NUM_1|NUM_1|A|A) FRUIT_SINGULAR NS_E] - PREDICTED CATEGORIES/WORDS: - NS_B ( ) - HAVE (HAVE ) - WANT (WANT ) - NS_B ( ) - HAVE (HAVE ) - WANT (WANT ) + % nextword fruit + Stat: init_voca: read 36 words + Reading in term file (optional)...done + 15 categories, 36 words + DFA has 26 nodes and 42 arcs + ----- + command completion is disabled + ----- + wseq > A BANANA + [wseq: A BANANA ] + [cate: (NUM_1|NUM_1|A|A) FRUIT_SINGULAR NS_E] + PREDICTED CATEGORIES/WORDS: + NS_B ( ) + HAVE (HAVE ) + WANT (WANT ) + NS_B ( ) + HAVE (HAVE ) + WANT (WANT ) SEE ALSO @@ -64,14 +63,14 @@ accept_check ( 1 ) COPYRIGHT - Copyright (c) 1997-2000 Information-technology Promotion Agency, Japan + Copyright (c) 1991-2013 Kawahara Lab., Kyoto University - Copyright (c) 1991-2008 Kawahara Lab., Kyoto University + Copyright (c) 1997-2000 Information-technology Promotion Agency, Japan Copyright (c) 2000-2005 Shikano Lab., Nara Institute of Science and Technology - Copyright (c) 2005-2008 Julius project team, Nagoya Institute of + Copyright (c) 2005-2013 Julius project team, Nagoya Institute of Technology LICENSE @@ -79,4 +78,4 @@ - 10/02/2008 NEXTWORD(1) + 12/19/2013 NEXTWORD(1) From sumomo @ users.sourceforge.jp Fri Dec 20 01:28:46 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Fri, 20 Dec 2013 01:28:46 +0900 Subject: [Julius-cvs 906] CVS update: julius4/jclient-perl Message-ID: <1387470526.130119.2477.nullmailer@users.sourceforge.jp> Index: julius4/jclient-perl/00readme-ja.txt diff -u julius4/jclient-perl/00readme-ja.txt:1.2 julius4/jclient-perl/00readme-ja.txt:1.3 --- julius4/jclient-perl/00readme-ja.txt:1.2 Thu Oct 2 17:23:47 2008 +++ julius4/jclient-perl/00readme-ja.txt Fri Dec 20 01:28:46 2013 @@ -44,4 +44,4 @@ - 10/02/2008 JCLIENT.PL(1) + 19/12/2013 JCLIENT.PL(1) Index: julius4/jclient-perl/00readme.txt diff -u julius4/jclient-perl/00readme.txt:1.2 julius4/jclient-perl/00readme.txt:1.3 --- julius4/jclient-perl/00readme.txt:1.2 Thu Oct 2 17:23:47 2008 +++ julius4/jclient-perl/00readme.txt Fri Dec 20 01:28:46 2013 @@ -43,4 +43,4 @@ - 10/02/2008 JCLIENT.PL(1) + 12/19/2013 JCLIENT.PL(1) From sumomo @ users.sourceforge.jp Fri Dec 20 01:28:46 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Fri, 20 Dec 2013 01:28:46 +0900 Subject: [Julius-cvs 907] CVS update: julius4/libjulius Message-ID: <1387470526.335040.2505.nullmailer@users.sourceforge.jp> Index: julius4/libjulius/configure diff -u julius4/libjulius/configure:1.17 julius4/libjulius/configure:1.18 --- julius4/libjulius/configure:1.17 Fri Jun 21 02:02:28 2013 +++ julius4/libjulius/configure Fri Dec 20 01:28:46 2013 @@ -592,7 +592,7 @@ JULIUS_PRODUCTNAME=JuliusLib -JULIUS_VERSION=4.2.3 +JULIUS_VERSION=4.3 # Check whether --enable-pthread or --disable-pthread was given. Index: julius4/libjulius/configure.in diff -u julius4/libjulius/configure.in:1.19 julius4/libjulius/configure.in:1.20 --- julius4/libjulius/configure.in:1.19 Fri Jun 21 02:14:19 2013 +++ julius4/libjulius/configure.in Fri Dec 20 01:28:46 2013 @@ -4,7 +4,7 @@ dnl Copyright (c) 2005-2013 Julius project team, Nagoya Institute of Technology dnl All rights reserved dnl -dnl $Id: configure.in,v 1.19 2013/06/20 17:14:19 sumomo Exp $ +dnl $Id: configure.in,v 1.20 2013/12/19 16:28:46 sumomo Exp $ dnl AC_INIT(src/search_bestfirst_main.c) @@ -12,7 +12,7 @@ AC_CONFIG_AUX_DIR(../support) JULIUS_PRODUCTNAME=JuliusLib -JULIUS_VERSION=4.2.3 +JULIUS_VERSION=4.3 dnl Checks for options From sumomo @ users.sourceforge.jp Fri Dec 20 01:28:47 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Fri, 20 Dec 2013 01:28:47 +0900 Subject: [Julius-cvs 908] CVS update: julius4/mkss Message-ID: <1387470527.313644.2651.nullmailer@users.sourceforge.jp> Index: julius4/mkss/00readme-ja.txt diff -u julius4/mkss/00readme-ja.txt:1.3 julius4/mkss/00readme-ja.txt:1.4 --- julius4/mkss/00readme-ja.txt:1.3 Thu Oct 2 17:23:49 2008 +++ julius4/mkss/00readme-ja.txt Fri Dec 20 01:28:47 2013 @@ -25,32 +25,32 @@ OPTIONS -freq Hz - ???????????? (Hz) ??????(default: 16,000) + ???????????? (Hz) ??????(default: 16,000) -len msec - ???????????????????default: 3000? + ???????????????????default: 3000? -fsize sample_num - ????????????? (default: 400)? + ????????????? (default: 400)? -fshift sample_num - ????????????????? (default: 160)? + ????????????????? (default: 160)? SEE ALSO julius ( 1 ) COPYRIGHT - Copyright (c) 1991-2008 ???? ????コ + Copyright (c) 1991-2013 ???? ????コ Copyright (c) 1997-2000 ????U?????(IPA) - Copyright (c) 2000-2008 ?????????w??? ュ???コ + Copyright (c) 2000-2005 ?????????w??? ュ???コ - Copyright (c) 2005-2008 ??????? Julius????? + Copyright (c) 2005-2013 ??????? Julius????? LICENSE Julius ??????????D - 10/02/2008 MKSS(1) + 19/12/2013 MKSS(1) Index: julius4/mkss/00readme.txt diff -u julius4/mkss/00readme.txt:1.3 julius4/mkss/00readme.txt:1.4 --- julius4/mkss/00readme.txt:1.3 Thu Oct 2 17:23:49 2008 +++ julius4/mkss/00readme.txt Fri Dec 20 01:28:47 2013 @@ -22,29 +22,29 @@ OPTIONS -freq Hz - Sampling frequency in Hz (default: 16,000) + Sampling frequency in Hz (default: 16,000) -len msec - capture length in milliseconds (default: 3000) + capture length in milliseconds (default: 3000) -fsize sample_num - frame size in number of samples (default: 400) + frame size in number of samples (default: 400) -fshift sample_num - frame shift in number of samples (default: 160) + frame shift in number of samples (default: 160) SEE ALSO julius ( 1 ) COPYRIGHT - Copyright (c) 1997-2000 Information-technology Promotion Agency, Japan + Copyright (c) 1991-2013 Kawahara Lab., Kyoto University - Copyright (c) 1991-2008 Kawahara Lab., Kyoto University + Copyright (c) 1997-2000 Information-technology Promotion Agency, Japan Copyright (c) 2000-2005 Shikano Lab., Nara Institute of Science and Technology - Copyright (c) 2005-2008 Julius project team, Nagoya Institute of + Copyright (c) 2005-2013 Julius project team, Nagoya Institute of Technology LICENSE @@ -52,4 +52,4 @@ - 10/02/2008 MKSS(1) + 12/19/2013 MKSS(1) From sumomo @ users.sourceforge.jp Fri Dec 20 01:28:45 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Fri, 20 Dec 2013 01:28:45 +0900 Subject: [Julius-cvs 909] CVS update: julius4/gramtools/generate Message-ID: <1387470525.861116.2437.nullmailer@users.sourceforge.jp> Index: julius4/gramtools/generate/00readme-ja.txt diff -u julius4/gramtools/generate/00readme-ja.txt:1.1 julius4/gramtools/generate/00readme-ja.txt:1.2 --- julius4/gramtools/generate/00readme-ja.txt:1.1 Thu Oct 2 17:23:46 2008 +++ julius4/gramtools/generate/00readme-ja.txt Fri Dec 20 01:28:45 2013 @@ -19,39 +19,39 @@ OPTIONS -t - ????????????????D + ????????????????D -n num - ???????????? (default: 10) + ???????????? (default: 10) -s spname - ??????????????????????????????? - (default: "sp") + ??????????????????????????????? + (default: "sp") -v - ??????D + ??????D EXAMPLES vfr (?????????????) ??タ??? - % generate vfr - Reading in dictionary...done - Reading in DFA grammar...done - Mapping dict item <-> DFA terminal (category)...done - Reading in term file (optional)...done - 42 categories, 99 words - DFA has 135 nodes and 198 arcs - ----- - silB ???? silE - silB ?????silE - silB ??? ? ??? ? ???? ??? silE - silB ??? ? ???? ? ?? ? ? ???? ??? silE - silB ???? ??? silE - silB ?? ? ?????? ??? silE - silB ?????? ??? silE - silB ??? ??? silE - silB ??? ? ??? ? ???? ??? silE - silB ??? ? ? ?? ??? silE + % generate vfr + Reading in dictionary...done + Reading in DFA grammar...done + Mapping dict item <-> DFA terminal (category)...done + Reading in term file (optional)...done + 42 categories, 99 words + DFA has 135 nodes and 198 arcs + ----- + silB ???? silE + silB ?????silE + silB ??? ? ??? ? ???? ??? silE + silB ??? ? ???? ? ?? ? ? ???? ??? silE + silB ???? ??? silE + silB ?? ? ?????? ??? silE + silB ?????? ??? silE + silB ??? ??? silE + silB ??? ? ??? ? ???? ??? silE + silB ??? ? ? ?? ??? silE SEE ALSO @@ -59,17 +59,17 @@ generate-ngram ( 1 ) COPYRIGHT - Copyright (c) 1991-2008 ???? ????コ + Copyright (c) 1991-2013 ???? ????コ Copyright (c) 1997-2000 ????U?????(IPA) - Copyright (c) 2000-2008 ?????????w??? ュ???コ + Copyright (c) 2000-2005 ?????????w??? ュ???コ - Copyright (c) 2005-2008 ??????? Julius????? + Copyright (c) 2005-2013 ??????? Julius????? LICENSE Julius ??????????D - 10/02/2008 GENERATE(1) + 19/12/2013 GENERATE(1) Index: julius4/gramtools/generate/00readme.txt diff -u julius4/gramtools/generate/00readme.txt:1.1 julius4/gramtools/generate/00readme.txt:1.2 --- julius4/gramtools/generate/00readme.txt:1.1 Thu Oct 2 17:23:46 2008 +++ julius4/gramtools/generate/00readme.txt Fri Dec 20 01:28:45 2013 @@ -15,42 +15,41 @@ This small program randomly generates sentences that are acceptable by the given grammar. - .dfa, .dict and .term files are needed to execute. They can be generated from .grammar and .voca file by mkdfa.pl. OPTIONS -t - Output in word's category name. + Output in word's category name. -n num - Set number of sentences to be generated (default: 10) + Set number of sentences to be generated (default: 10) -s spname - the name string of short-pause word to be supressed (default: "sp") + the name string of short-pause word to be supressed (default: "sp") -v - Debug output mode. + Debug output mode. EXAMPLES Exmple output of a sample grammar "fruit": - % generate fruit - Stat: init_voca: read 36 words - Reading in term file (optional)...done - 15 categories, 36 words - DFA has 26 nodes and 42 arcs - ----- - I WANT ONE APPLE - I WANT TEN PEARS - CAN I HAVE A PINEAPPLE - I WANT ONE PEAR - COULD I HAVE A BANANA - I WANT ONE APPLE PLEASE - I WANT NINE APPLES - NINE APPLES - I WANT ONE PINEAPPLE - I WANT A PEAR + % generate fruit + Stat: init_voca: read 36 words + Reading in term file (optional)...done + 15 categories, 36 words + DFA has 26 nodes and 42 arcs + ----- + I WANT ONE APPLE + I WANT TEN PEARS + CAN I HAVE A PINEAPPLE + I WANT ONE PEAR + COULD I HAVE A BANANA + I WANT ONE APPLE PLEASE + I WANT NINE APPLES + NINE APPLES + I WANT ONE PINEAPPLE + I WANT A PEAR SEE ALSO @@ -58,14 +57,14 @@ generate-ngram ( 1 ) COPYRIGHT - Copyright (c) 1997-2000 Information-technology Promotion Agency, Japan + Copyright (c) 1991-2013 Kawahara Lab., Kyoto University - Copyright (c) 1991-2008 Kawahara Lab., Kyoto University + Copyright (c) 1997-2000 Information-technology Promotion Agency, Japan Copyright (c) 2000-2005 Shikano Lab., Nara Institute of Science and Technology - Copyright (c) 2005-2008 Julius project team, Nagoya Institute of + Copyright (c) 2005-2013 Julius project team, Nagoya Institute of Technology LICENSE @@ -73,4 +72,4 @@ - 10/02/2008 GENERATE(1) + 12/19/2013 GENERATE(1) From sumomo @ users.sourceforge.jp Fri Dec 20 01:28:45 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Fri, 20 Dec 2013 01:28:45 +0900 Subject: [Julius-cvs 910] CVS update: julius4/gramtools/mkdfa Message-ID: <1387470525.994838.2457.nullmailer@users.sourceforge.jp> Index: julius4/gramtools/mkdfa/00readme-ja.txt diff -u julius4/gramtools/mkdfa/00readme-ja.txt:1.1 julius4/gramtools/mkdfa/00readme-ja.txt:1.2 --- julius4/gramtools/mkdfa/00readme-ja.txt:1.1 Thu Oct 2 17:23:46 2008 +++ julius4/gramtools/mkdfa/00readme-ja.txt Fri Dec 20 01:28:45 2013 @@ -20,7 +20,6 @@ ??????ョ????????C??????????????? - prefix ??.grammar ??????? .voca????? ?????????? ????????prefix.grammar? prefix.voca??prefix.dfa? prefix.dict??? prefix.term???????? @@ -30,18 +29,18 @@ OPTIONS -n - ォ??o?????.voca ??? .grammar ??? .dfa ????? ?? - ????? + ォ??o?????.voca ??? .grammar ??? .dfa ????? ?? + ????? ENVIRONMENT VARIABLES TMP ??? TEMP - ????????????????????????? ???????C - /tmp, /var/tmp, /WINDOWS/Temp, /WINNT/Temp ????????????- ??g????? + ????????????????????????? ???????C + /tmp, /var/tmp, /WINDOWS/Temp, /WINNT/Temp ????????????+ ??g????? EXAMPLES - ?????? foo.grammar, foo.voca? ??????タ?????? foo.dfa - ? foo.voca???foo.term??????D + ?????? foo.grammar, foo.voca? ??????タ?????? + foo.dfa? foo.voca???foo.term??????D SEE ALSO julius ( 1 ) , @@ -56,17 +55,17 @@ ????? ????Julius ?????????? COPYRIGHT - Copyright (c) 1991-2008 ???? ????コ + Copyright (c) 1991-2013 ???? ????コ Copyright (c) 1997-2000 ????U?????(IPA) - Copyright (c) 2000-2008 ?????????w??? ュ???コ + Copyright (c) 2000-2005 ?????????w??? ュ???コ - Copyright (c) 2005-2008 ??????? Julius????? + Copyright (c) 2005-2013 ??????? Julius????? LICENSE Julius ??????????D - 10/02/2008 MKDFA.PL(1) + 19/12/2013 MKDFA.PL(1) Index: julius4/gramtools/mkdfa/00readme.txt diff -u julius4/gramtools/mkdfa/00readme.txt:1.1 julius4/gramtools/mkdfa/00readme.txt:1.2 --- julius4/gramtools/mkdfa/00readme.txt:1.1 Thu Oct 2 17:23:46 2008 +++ julius4/gramtools/mkdfa/00readme.txt Fri Dec 20 01:28:45 2013 @@ -17,21 +17,20 @@ also generated that stores correspondence of category ID used in the output files to the source category name. - prefix should be the common file name prefix of ".grammar" and "voca" file. From prefix.grammar and prefix.voca file, prefix.dfa, prefix.dict and prefix.term will be output. OPTIONS -n - Not process dictionary. You can only convert .grammar file to .dfa - file without .voca file. + Not process dictionary. You can only convert .grammar file to .dfa + file without .voca file. ENVIRONMENT VARIABLES TMP or TEMP - Set directory to store temporal file. If not specified, one of them - on the following list will be used: /tmp, /var/tmp, /WINDOWS/Temp, - /WINNT/Temp. + Set directory to store temporal file. If not specified, one of them + on the following list will be used: /tmp, /var/tmp, /WINDOWS/Temp, + /WINNT/Temp. EXAMPLES Convert a grammar foo.grammar and foo.voca to foo.dfa, foo.voca and @@ -49,14 +48,14 @@ placed at the same directory as mkdfa.pl. COPYRIGHT - Copyright (c) 1997-2000 Information-technology Promotion Agency, Japan + Copyright (c) 1991-2013 Kawahara Lab., Kyoto University - Copyright (c) 1991-2008 Kawahara Lab., Kyoto University + Copyright (c) 1997-2000 Information-technology Promotion Agency, Japan Copyright (c) 2000-2005 Shikano Lab., Nara Institute of Science and Technology - Copyright (c) 2005-2008 Julius project team, Nagoya Institute of + Copyright (c) 2005-2013 Julius project team, Nagoya Institute of Technology LICENSE @@ -64,4 +63,4 @@ - 10/02/2008 MKDFA.PL(1) + 12/19/2013 MKDFA.PL(1) From sumomo @ users.sourceforge.jp Fri Dec 20 18:23:07 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Fri, 20 Dec 2013 18:23:07 +0900 Subject: [Julius-cvs 911] CVS update: julius4/libjulius/src Message-ID: <1387531387.541856.4445.nullmailer@users.sourceforge.jp> Index: julius4/libjulius/src/default.c diff -u julius4/libjulius/src/default.c:1.21 julius4/libjulius/src/default.c:1.22 --- julius4/libjulius/src/default.c:1.21 Wed Dec 18 12:55:20 2013 +++ julius4/libjulius/src/default.c Fri Dec 20 18:23:07 2013 @@ -17,7 +17,7 @@ * @author Akinobu Lee * @date Fri Feb 16 15:05:43 2007 * - * $Revision: 1.21 $ + * $Revision: 1.22 $ * */ /* @@ -103,9 +103,6 @@ j->optsection = JCONF_OPT_DEFAULT; j->optsectioning = TRUE; - if (j->outprob_outfile != NULL) { - free(j->outprob_outfile); - } j->outprob_outfile = NULL; } Index: julius4/libjulius/src/instance.c diff -u julius4/libjulius/src/instance.c:1.11 julius4/libjulius/src/instance.c:1.12 --- julius4/libjulius/src/instance.c:1.11 Wed Dec 18 12:55:20 2013 +++ julius4/libjulius/src/instance.c Fri Dec 20 18:23:07 2013 @@ -12,7 +12,7 @@ * @author Akinobu Lee * @date Sun Oct 28 18:06:20 2007 * - * $Revision: 1.11 $ + * $Revision: 1.12 $ * */ /* @@ -334,6 +334,7 @@ { JCONF_AM *new; new = (JCONF_AM *)mymalloc(sizeof(JCONF_AM)); + memset(new, 0, sizeof(JCONF_AM)); jconf_set_default_values_am(new); new->next = NULL; return new; @@ -438,6 +439,7 @@ { JCONF_LM *new; new = (JCONF_LM *)mymalloc(sizeof(JCONF_LM)); + memset(new, 0, sizeof(JCONF_LM)); jconf_set_default_values_lm(new); new->next = NULL; return new; @@ -555,6 +557,7 @@ { JCONF_SEARCH *new; new = (JCONF_SEARCH *)mymalloc(sizeof(JCONF_SEARCH)); + memset(new, 0, sizeof(JCONF_SEARCH)); jconf_set_default_values_search(new); new->next = NULL; return new; @@ -664,6 +667,7 @@ /* allocate memory */ jconf = (Jconf *)mymalloc(sizeof(Jconf)); + memset(jconf, 0, sizeof(Jconf)); /* set default values */ jconf_set_default_values(jconf); From sumomo @ users.sourceforge.jp Wed Dec 25 16:06:50 2013 From: sumomo @ users.sourceforge.jp (sumomo @ users.sourceforge.jp) Date: Wed, 25 Dec 2013 16:06:50 +0900 Subject: [Julius-cvs 912] CVS update: julius4/mkbingram Message-ID: <1387955210.313255.1281.nullmailer@users.sourceforge.jp> Index: julius4/mkbingram/charconv.c diff -u julius4/mkbingram/charconv.c:1.2 julius4/mkbingram/charconv.c:1.3 --- julius4/mkbingram/charconv.c:1.2 Fri Jun 21 02:14:27 2013 +++ julius4/mkbingram/charconv.c Wed Dec 25 16:06:47 2013 @@ -42,7 +42,7 @@ || strmatch(codestr, "euc") || strmatch(codestr, "eucjp")) { /* input = Shift_jis (codepage 932) */ - *code = CODE_JPN_EUC; + *code = 20932; } else if (strmatch(codestr, "ansi")) { /* ANSI codepage (MBCS) ex. shift-jis in Windows XP Japanese edition.*/ *code = CP_ACP; @@ -102,11 +102,11 @@ #if defined(_WIN32) if (str2code(fromcode, &from_cp) == -1) { - fpritnf(stderr, "Error: charconv_setup: unknown codepage specified\n"); + fprintf(stderr, "Error: charconv_setup: unknown codepage specified\n"); return -1; } if (str2code(tocode, &to_cp) == -1) { - fpritnf(stderr, "Error: charconv_setup: unknown codepage specified\n"); + fprintf(stderr, "Error: charconv_setup: unknown codepage specified\n"); return -1; } #else