Skip to content

__init__() got an unexpected keyword argument 'hmm' and path issues with pocketsphinx #712

@BruceJohnJennerLawso

Description

@BruceJohnJennerLawso

So I am trying to get jasper working with pocketsphinx and espeak on an Orange Pi board running Ubuntu 16.04. For all intents and purposes the board has run like any ordinary Ubuntu install, save with ARM packages.

Because Im on Ubuntu, Im able to skip the whole build process for pocketsphinx and install pocketsphinx and python-pocketsphinx through apt. I then installed the rest of the dependencies as needed, but Im still having issues getting jasper to work.

The first issue seems to be with parsing profile.yml. When I try to manually specify options for CMUSphinx hmm_dir and fst_model as described at

http://jasperproject.github.io/documentation/configuration/

I get

ScannerError: mapping values are not allowed here

Which seems to happen whenever I indent a line in profile.yml. If I dont indent the lines for hmm_dir and fst_model, they seem to just be ignored.

I tried to continue on leaving those options blank, but the hmm_dir that apt installs pocketsphinx with seems to have changed. Jasper seems to think its located at

/usr/local/share/pocketsphinx/model/hmm/en_US/hub4wsj_sc_8k

but as far as I can tell its actually located at

/usr/share/pocketsphinx/model/en-us/en-us

Jasper manages to get past that issue when I manually edited the hmm path in client/stt.py, but now crashes somewhere in stt.py with

File "./jasper.py", line 146, in
app = Jasper()
File "./jasper.py", line 109, in init
stt_passive_engine_class.get_passive_instance(),
File "/home/john/dev/jasper/client/stt.py", line 48, in get_passive_instance
return cls.get_instance('keyword', phrases)
File "/home/john/dev/jasper/client/stt.py", line 42, in get_instance
instance = cls(**config)
File "/home/john/dev/jasper/client/stt.py", line 129, in init
**vocabulary.decoder_kwargs)
TypeError: init() got an unexpected keyword argument 'hmm'

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions