jasperproject / jasper-client

Client code for Jasper voice computing platform
MIT License
4.53k stars 1.01k forks source link

Running Jasper with Pocketsphinx STT Error #617

Open Mvpchris opened 7 years ago

Mvpchris commented 7 years ago

The error I get is below.

ERROR:client.stt:hmm_dir '/usr/local/share/pocketsphinx/model/hmm/en_US/hub4wsj_sc_8k' does not exist! Please make sure that you have set the correct hmm_dir in your profile. ERROR:root:Error occured! Traceback (most recent call last): File "./jasper.py", line 146, in app = Jasper() File "./jasper.py", line 109, in init stt_passive_engine_class.get_passive_instance(), File "/home/pi/jasper/client/stt.py", line 48, in get_passive_instance return cls.get_instance('keyword', phrases) File "/home/pi/jasper/client/stt.py", line 42, in get_instance instance = cls(**config) File "/home/pi/jasper/client/stt.py", line 105, in init raise RuntimeError(msg) RuntimeError: hmm_dir '/usr/local/share/pocketsphinx/model/hmm/en_US/hub4wsj_sc_8k' does not exist! Please make sure that you have set the correct hmm_dir in your profile.

I set up the info in my profile like the jasper website instructed (at least I thought I did). How I set up my profile is below.

stt_engine: sphinx pocketsphinx: fst_model: 'home/pi/phonetisaurus/g014b2b.fst' hmm_dir: '/usr/local/share/pocketsphinx/model/hmm/en_US/hub4wsj_sc_8k' timezone: America/Chicago tts_engine: google-tts audio: input_samplerate: 44100

I still do not understand why I'm getting an error running Jasper

This is the site I used when I first ran into problems with installing: http://chrismeiercs.com/blog/2016/02/27/installing-jasper-on-raspberry-pi-b-plus/

Mvpchris commented 7 years ago

Update on error.

I was about to get the Pocketsphinx working when I changed the path of my hmm_dir. I downloaded the latest CMU Sphinx model to my Downloads folder in pi and I corrected the path in my profile. Jasper is now working but it is unable to recognize anything Im saying. For example: I change my recognition word (or keyword) to 'J' so it would be easier to recognize but jasper responds with ['Now'] or ['Time'] or something thats not even close to what I said.

Im pretty sure there is a way to train the sphinx to my voice or words but Im unsure how to accomplish that while still in Jasper. If anyone has any links/tutorials/videos/ anything on how to fix this situation please comment. Any help is a big help. Thanks!!

(Also Ive tried google stt but the max quota you can use is not enough. Ive also tried witai and it worked ok but the speed was slow and it takes many tries to get it recognizing what I want it to say so I figured sphinx would be the best to use)

mridulzz commented 7 years ago

i want the same thing . i think this can be done by creating an acoustic model and we can train it.visit this link https://cmusphinx.github.io/wiki/tutorialam/