Menu

Simultaneous decoding processes

Help
Horia Cucu
2011-03-29
2012-09-22
  • Horia Cucu

    Horia Cucu - 2011-03-29

    Hello,

    I want to start to decode processes in the same time. The problem is I will
    need to change some parameters in the sphinx_decode.cfg file.

    The steps I intend to make are as follows:
    1. edit sphinx_decode.cfg to set the params for the first decode process
    2. start the first decode process
    3. edit sphinx_decode.cfg to set the params for the second decode process
    4. start the second decode process

    Will this work? I mean changing the config file after the first decode process
    has started...

    Horia

     
  • Rafael Oliveira

    Rafael Oliveira - 2011-03-29

    Hi,

    I think it will not work if you do the way you are planning. I have tried it
    once, and, i had some troubles... I can not tell you exactly why, but, i had
    some errors while trying to execute two instances of the decoder
    simultaneously. Maybe, the decoder stores some information in temporary files
    while doing the decoding, so, we have two or more processes attempting to
    access the same file at the same time without any kind of concurrence control,
    what in general does not smell so good.

    If what you want is automate your tests, consider stop using the script given
    in this tutorial http://cmusphinx.sourceforge.net/wiki/tutorialam (./scripts_pl/decode/slave.pl).
    Despite the fact slave.py is excellent when you are having your first meet
    with the test acoustic models task, it locks you into the structure that it
    requires, what bothers when you want a more personalized test processes. For
    example: every time you want to perform a test, you have to set the
    sphinx_decode.cfg file while It would be easier or comfortable to do something
    like that:

    ./decoder param1 param2 param3 param4 paramN

    where the parameters are just those which you are working with.

    If you take a look at the decoder log file on the logdir directory you will
    find in the begin of the file the command line the slave.py uses to invoke the
    decoder. It's something like that:

    /home/xxx/sphinx/acoustic_model/acoustic_model/bin/.libs/lt-
    pocketsphinx_batch \
    -hmm /home/xxx/sphinx/acoustic_model/acoustic_model/model_parameters/db.cd_cont_3000 \
    -lw 6 \
    -feat 1s_c_d_dd \
    -beam 1e-80 \
    -wbeam 1e-40 \
    -dict /home/20102000030/sphinx/acoustic_model/acoustic_model/etc/db.dic \
    -lm /home/20102000030/sphinx/acoustic_model/acoustic_model/etc/db.lm \
    -wip 0.2 \
    -ctl /home/20102000030/sphinx/acoustic_model/acoustic_model/etc/db_test.fileids \
    -ctloffset 0 \
    -ctlcount 700 \
    -cepdir /home/20102000030/sphinx/acoustic_model/acoustic_model/feat \
    -cepext .mfc \
    -hyp /home/20102000030/sphinx/acoustic_model/acoustic_model/result/db-1-1.match \
    -agc none \
    -varnorm no \
    -cmn current

    So, you can use this command line instead the slave.py, eliminating the need
    to set the parameters in the sphinx_decode.cfg every time you want to perform
    a test, which will guarantee you a number of other possibilities to automate
    your tests.

     
  • Horia Cucu

    Horia Cucu - 2011-03-30

    Ok! Thanks a lot!
    I'll have to dig into the perl scripts and see what's going on, but your idea
    seems reasonable.
    Horia

     
  • Nickolay V. Shmyrev

    It would be nice to collect requirements for the training system somewhere so
    we can make it more flexible in the future. Being able to train multiple
    databases with different parameters on the same data is certainly one of them.

     

Log in to post a comment.