xvoice-sphinx wiki   RunningSphinxTrain UserPreferences
 

Contained here is a recipe for improving the standard Sphinx2 distribution accuracy by combining your speaker-dependent training with some speaker-independent data (via hub4).

Do this:

  1. Install [WWW]Festival and all its associated models.
  2. Install SphinxTrain into /usr/local/src.
  3. export SPHINXTRAINDIR=/usr/local/src/SphinxTrain 
       
  4. Install [WWW]hub4 into /usr/local/src.
  5. Create a directory in which to create and run your training scripts, and cd into it. We will call this directory "time":
  6. Run the SphinxTrain setup script. It will create various subdirectories and files.

    $SPHINXTRAINDIR/scripts_pl/setup_SphinxTrain  time 
      
  7. Create the following files in time/etc:
  8. Create a WAV file in time/wav (we recommend using [WWW]ecasound, but any recording program which records clear and relatively loud sound as a WAV will work):
  9. Create a time/model_parameters/hub4 directory. Create symbolic links in that directory to the following files:
  10. Create a symbolic link in time/model_architecture from /usr/local/src/hub4-2000-11-17-1/sphinx_3_format/newfe.6000.mdef to time.6000.mdef. (Note that "mdef" stands for "Model Definitions". It contains the dimensions of various matrixes. The "6000" means 6000 tied states.)
  11. Modify time/scripts_pl/09.make_s2_models/make_s2_models.pl by replacing:
  12. Change the time/bin/make_feats script, line 72, from:

Then, run this script (builds2model) in the time directory:

#!/bin/sh -xv 
rm time.html 
rm model_architecture/time.[a-z]* 
bin/make_dict etc/time.transcription 
# 
#WIll create etc/word.known etc/word.unknown files,. check them once you are happy, 
# 
mv etc/word.known etc/time.dic 
# 
#Make the melcep feature files 
# 
bin/make_feats etc/time.fileids 
# 
#Now we can start on the basic perl scripts, ther 
#results will be put in perl_time.html, which you can view as things progress. Note the scripts aren't guaranteed, and problems do occur, \ though often the error message is actually indicative of the error. 
# 
#There a number of larger choices in building models, one is to build continous models or semi-continuous. Only semi-continous 
#can be used by Sphinx2. 
# 
#Doesn't do enough checking, but may help 
export SPHINXTRAINDIR=. 
./scripts_pl/00.verify/verify_all.pl 
#Can take several minutes 
rm -r model_parameters/time.*[a-z] 
rm -r logdir/0*[a-z] 
PATH=/bin:$PATH ./scripts_pl/01.vector_quantize/slave.VQ.pl 
#Initial BW training 
PATH=/bin:$PATH ./scripts_pl/02.ci_schmm/slave_convg.pl 
./scripts_pl/03.makeuntiedmdef/make_untied_mdef.pl 
PATH=/bin:$PATH ./scripts_pl/04.cd_schmm_untied/slave_convg.pl 
./scripts_pl/05.buildtrees/make_questions.pl 
./scripts_pl/06.prunetree/slave.state-tie-er.pl 
PATH=/bin:$PATH ./scripts_pl/07.cd-schmm/slave_convg.pl 
PATH=/bin:$PATH ./scripts_pl/08.deleted-interpolation/deleted_interpolation.pl 
mkdir model_parameters/time.cd_semi_6000_interp 
./bin/mixw_interp -SImixwfn model_parameters/time.cd_semi_6000_delinterp/mixture_weights -SDmixwfn  model_parameters/hub4/mixture_weights -SIlambda 0.1 -outmixwfn model_parameters/00.cd_semi_6000_interp/mixture_weights 
./scripts_pl/09.make_s2_models/make_s2_models.pl 

Errors will be put in 'train.log'.


PythonPowered