Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Using JSGF grammar instead of DMP language model (use -jsgf instead of -lm) in CMU Sphinx (pocketsphinx)

I need to train CMU Sphinx offline in my android app. I downloaded this project that use this parameter but when I start it I have this error: Fatal signal 11 (SIGSEGV) at 0x0000001c (code=1). This error I also have when Sphinx can not find the accoustic model. I found answer on my question here, but it is does not work for me. What I am doing wrong, can anybody can provide me any tutorial, or a good answer?

So the question is how to use .jsgf files istead of .DMP files as language model for Pocketsphinx like it used in Recognizer task in Inimesed project?

like image 475
Sergey Pekar Avatar asked Feb 02 '13 20:02

Sergey Pekar


1 Answers

If CMU Sphinx works similarly on Android and on Windows, the following may help:

http://www.aiaioo.com/cms/index.php?id=28 http://homepages.abdn.ac.uk/k.vdeemter/pages/teaching/NLP/practicals/JSGFGrammar.html http://www.w3.org/TR/jsgf/

Example JSGF file:

#JSGF V1.0;
grammar hello;
public <command> = ( open | close ) ( computer | window | music | note );

Save the above grammar in a text file called "hello.gram", then run sphinx with:

pocketsphinx_continuous.exe -hmm hub4wsj_sc_8k -jsgf hello.gram -dict hub4.5000.dic
like image 133
herrlich10 Avatar answered Sep 21 '22 06:09

herrlich10