When I start Jasper it work correct, but after a few minutes I have this issue (I report terminal lines by input on terminal ./Jasper.py --debug)
DEBUG:sphinx_1_0_0.sphinxplugin:INFO: feat.c(715): Initializing feature stream to type: '1s_c_d_dd', ceplen=13, CMN='batch', VARNORM='no', AGC='none'
DEBUG:sphinx_1_0_0.sphinxplugin:INFO: acmod.c(162): Using subvector specification 0-12/13-25/26-38
DEBUG:sphinx_1_0_0.sphinxplugin:INFO: mdef.c(518): Reading model definition: /usr/local/share/pocketsphinx/model/en-us/en-us/mdef
DEBUG:sphinx_1_0_0.sphinxplugin:INFO: mdef.c(531): Found byte-order mark BMDF, assuming this is a binary mdef file
DEBUG:sphinx_1_0_0.sphinxplugin:INFO: bin_mdef.c(336): Reading binary model definition: /usr/local/share/pocketsphinx/model/en-us/en-us/mdef
DEBUG:sphinx_1_0_0.sphinxplugin:INFO: bin_mdef.c(516): 42 CI-phone, 137053 CD-phone, 3 emitstate/phone, 126 CI-sen, 5126 Sen, 29324 Sen-Seq
DEBUG:sphinx_1_0_0.sphinxplugin:INFO: tmat.c(149): Reading HMM transition probability matrices: /usr/local/share/pocketsphinx/model/en-us/en-us/transition_matrices
DEBUG:sphinx_1_0_0.sphinxplugin:INFO: acmod.c(113): Attempting to use PTM computation module
DEBUG:sphinx_1_0_0.sphinxplugin:INFO: ms_gauden.c(127): Reading mixture gaussian parameter: /usr/local/share/pocketsphinx/model/en-us/en-us/means
DEBUG:sphinx_1_0_0.sphinxplugin:INFO: ms_gauden.c(242): 42 codebook, 3 feature, size:
DEBUG:sphinx_1_0_0.sphinxplugin:INFO: ms_gauden.c(244): 128x13
DEBUG:sphinx_1_0_0.sphinxplugin:INFO: ms_gauden.c(244): 128x13
DEBUG:sphinx_1_0_0.sphinxplugin:INFO: ms_gauden.c(244): 128x13
DEBUG:sphinx_1_0_0.sphinxplugin:INFO: ms_gauden.c(127): Reading mixture gaussian parameter: /usr/local/share/pocketsphinx/model/en-us/en-us/variances
DEBUG:sphinx_1_0_0.sphinxplugin:INFO: ms_gauden.c(242): 42 codebook, 3 feature, size:
DEBUG:sphinx_1_0_0.sphinxplugin:INFO: ms_gauden.c(244):
INFO:sphinx_1_0_0.sphinxplugin:Transcribed: ['OF']
WARNING:pyaudio_1_0_0.pyaudioengine:IO error while reading from device 'default': 'Input overflowed' (Errno: -9981)
WARNING:pyaudio_1_0_0.pyaudioengine:IO error while reading from device 'default': 'Stream closed' (Errno: -9988)
WARNING:pyaudio_1_0_0.pyaudioengine:IO error while reading from device 'default': 'Stream closed' (Errno: -9988)
WARNING:pyaudio_1_0_0.pyaudioengine:IO error while reading from device 'default': 'Stream closed' (Errno: -9988)
WARNING:pyaudio_1_0_0.pyaudioengine:IO error while reading from device 'default': 'Stream closed' (Errno: -9988)
WARNING:pyaudio_1_0_0.pyaudioengine:IO error while reading from device 'default': 'Stream closed' (Errno: -9988)
WARNING:pyaudio_1_0_0.pyaudioengine:IO error while reading from device 'default': 'Stream closed' (Errno: -9988)
And the WARNING:pyaudio_1_0_0.pyaudioengine:IO error while reading from device 'default': 'Stream closed' (Errno: -9988) it's a loop that prevents jasper from working ...
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
And in this way, when I try to start jasper there is this error:
Traceback (most recent call last):
File "./Jasper.py", line 5, in <module>
jasper.main()
File "/home/pi/jasper/jasper-client/jasper/main.py", line 48, in main
batch_file=p_args.batch_file)
File "/home/pi/jasper/jasper-client/jasper/application.py", line 230, in init
tts_plugin, self.config, keyword=keyword)
File "/home/pi/jasper/jasper-client/jasper/mic.py", line 50, in init
self._input_rate = get_config_value(config, 'input_samplerate', 16000)
File "/home/pi/jasper/jasper-client/jasper/mic.py", line 24, in get_config_value
value = int(config['audio'][name])
TypeError: 'NoneType' object has no attribute 'getitem'</module>
Last edit: Giovanni 2018-04-30
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Better go through the code and try to understand the flow and logic.
Traceback showing the file name and line number.
If you know how to debug the python code then It will be very easy to fix the issues.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I don't understand how can I fix the problem, I've tried to execute this input:
root@raspberrypi:/home/pi/jasper/jasper-client/jasper# ./mic.py --debug
./mic.py: line 2: import: command not found
./mic.py: line 3: import: command not found
./mic.py: line 4: import: command not found
./mic.py: line 5: import: command not found
./mic.py: line 6: import: command not found
./mic.py: line 7: import: command not found
./mic.py: line 8: import: command not found
./mic.py: line 9: import: command not found
./mic.py: line 10: import: command not found
./mic.py: line 12: syntax error near unexpected token ('
./mic.py: line 12:if sys.version_info < (3, 0): # NOQA'
root@raspberrypi:/home/pi/jasper/jasper-client/jasper#
Can you help me to fix this problem?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
def get_config_value(config, name, default):
logger = logging.getLogger(name)
try:
value = int(config['2048'][name])
except KeyError:
logger.debug('%s not configured, using default.', name)
value = None
except ValueError:
logger.debug('%s is not an integer, using default.', name)
value = None
return value if value else default
And I need to change output_padding = config['2048']['output_padding'] because without Jasper doesn't work. With this change on mic.py Jasper work, but by insert the value 2048 or 4096 the problem doesn't fix ...
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi,
I'm working on this project http://jasperproject.github.io/ and I've installed jasper-dev that support Pocketsphinx-5prealpha by follow this link: https://github.com/GeoBeBee/mySystem/blob/master/Jasper-dev_onPocketPhinx_5preAlpha.txt
When I start Jasper it work correct, but after a few minutes I have this issue (I report terminal lines by input on terminal ./Jasper.py --debug)
DEBUG:sphinx_1_0_0.sphinxplugin:INFO: feat.c(715): Initializing feature stream to type: '1s_c_d_dd', ceplen=13, CMN='batch', VARNORM='no', AGC='none'
DEBUG:sphinx_1_0_0.sphinxplugin:INFO: acmod.c(162): Using subvector specification 0-12/13-25/26-38
DEBUG:sphinx_1_0_0.sphinxplugin:INFO: mdef.c(518): Reading model definition: /usr/local/share/pocketsphinx/model/en-us/en-us/mdef
DEBUG:sphinx_1_0_0.sphinxplugin:INFO: mdef.c(531): Found byte-order mark BMDF, assuming this is a binary mdef file
DEBUG:sphinx_1_0_0.sphinxplugin:INFO: bin_mdef.c(336): Reading binary model definition: /usr/local/share/pocketsphinx/model/en-us/en-us/mdef
DEBUG:sphinx_1_0_0.sphinxplugin:INFO: bin_mdef.c(516): 42 CI-phone, 137053 CD-phone, 3 emitstate/phone, 126 CI-sen, 5126 Sen, 29324 Sen-Seq
DEBUG:sphinx_1_0_0.sphinxplugin:INFO: tmat.c(149): Reading HMM transition probability matrices: /usr/local/share/pocketsphinx/model/en-us/en-us/transition_matrices
DEBUG:sphinx_1_0_0.sphinxplugin:INFO: acmod.c(113): Attempting to use PTM computation module
DEBUG:sphinx_1_0_0.sphinxplugin:INFO: ms_gauden.c(127): Reading mixture gaussian parameter: /usr/local/share/pocketsphinx/model/en-us/en-us/means
DEBUG:sphinx_1_0_0.sphinxplugin:INFO: ms_gauden.c(242): 42 codebook, 3 feature, size:
DEBUG:sphinx_1_0_0.sphinxplugin:INFO: ms_gauden.c(244): 128x13
DEBUG:sphinx_1_0_0.sphinxplugin:INFO: ms_gauden.c(244): 128x13
DEBUG:sphinx_1_0_0.sphinxplugin:INFO: ms_gauden.c(244): 128x13
DEBUG:sphinx_1_0_0.sphinxplugin:INFO: ms_gauden.c(127): Reading mixture gaussian parameter: /usr/local/share/pocketsphinx/model/en-us/en-us/variances
DEBUG:sphinx_1_0_0.sphinxplugin:INFO: ms_gauden.c(242): 42 codebook, 3 feature, size:
DEBUG:sphinx_1_0_0.sphinxplugin:INFO: ms_gauden.c(244):
INFO:sphinx_1_0_0.sphinxplugin:Transcribed: ['OF']
WARNING:pyaudio_1_0_0.pyaudioengine:IO error while reading from device 'default': 'Input overflowed' (Errno: -9981)
WARNING:pyaudio_1_0_0.pyaudioengine:IO error while reading from device 'default': 'Stream closed' (Errno: -9988)
WARNING:pyaudio_1_0_0.pyaudioengine:IO error while reading from device 'default': 'Stream closed' (Errno: -9988)
WARNING:pyaudio_1_0_0.pyaudioengine:IO error while reading from device 'default': 'Stream closed' (Errno: -9988)
WARNING:pyaudio_1_0_0.pyaudioengine:IO error while reading from device 'default': 'Stream closed' (Errno: -9988)
WARNING:pyaudio_1_0_0.pyaudioengine:IO error while reading from device 'default': 'Stream closed' (Errno: -9988)
WARNING:pyaudio_1_0_0.pyaudioengine:IO error while reading from device 'default': 'Stream closed' (Errno: -9988)
And the WARNING:pyaudio_1_0_0.pyaudioengine:IO error while reading from device 'default': 'Stream closed' (Errno: -9988) it's a loop that prevents jasper from working ...
try increasing
input_chunksizeto 2048 or 4096.First I try to modify my profile.yml in this way:
carrier: ''
first_name:
gmail_address:
gmail_password: ''
last_name:
location:
phone_number: ''
prefers_email: false
stt_engine: sphinx
timezone: Europe/Rome
stt_engine: sphinx
pocketsphinx:
fst_model: '/home/pi/jasper/phonetisaurus/g014b2b.fst' #optional
hmm_dir: '/usr/local/share/pocketsphinx/model/en-us/en-us' #optional
tts_engine: festival-tts
keyword: 'Jasper'
input_chunksize: '2048'
And it work, but the problem doesn't solve, but after (because I think that I've write it uncorrectly) I modify profile.yml in this way:
carrier: ''
first_name:
gmail_address:
gmail_password: ''
last_name:
location:
phone_number: ''
prefers_email: false
stt_engine: sphinx
timezone: Europe/Rome
stt_engine: sphinx
pocketsphinx:
fst_model: '/home/pi/jasper/phonetisaurus/g014b2b.fst' #optional
hmm_dir: '/usr/local/share/pocketsphinx/model/en-us/en-us' #optional
tts_engine: festival-tts
keyword: 'Jasper'
audio:
input_chunksize: '2048'
And in this way, when I try to start jasper there is this error:
Traceback (most recent call last):
File "./Jasper.py", line 5, in <module>
jasper.main()
File "/home/pi/jasper/jasper-client/jasper/main.py", line 48, in main
batch_file=p_args.batch_file)
File "/home/pi/jasper/jasper-client/jasper/application.py", line 230, in init
tts_plugin, self.config, keyword=keyword)
File "/home/pi/jasper/jasper-client/jasper/mic.py", line 50, in init
self._input_rate = get_config_value(config, 'input_samplerate', 16000)
File "/home/pi/jasper/jasper-client/jasper/mic.py", line 24, in get_config_value
value = int(config['audio'][name])
TypeError: 'NoneType' object has no attribute 'getitem'</module>
Last edit: Giovanni 2018-04-30
Better go through the code and try to understand the flow and logic.
Traceback showing the file name and line number.
If you know how to debug the python code then It will be very easy to fix the issues.
I don't understand how can I fix the problem, I've tried to execute this input:
root@raspberrypi:/home/pi/jasper/jasper-client/jasper# ./mic.py --debug
./mic.py: line 2: import: command not found
./mic.py: line 3: import: command not found
./mic.py: line 4: import: command not found
./mic.py: line 5: import: command not found
./mic.py: line 6: import: command not found
./mic.py: line 7: import: command not found
./mic.py: line 8: import: command not found
./mic.py: line 9: import: command not found
./mic.py: line 10: import: command not found
./mic.py: line 12: syntax error near unexpected token
(' ./mic.py: line 12:if sys.version_info < (3, 0): # NOQA'root@raspberrypi:/home/pi/jasper/jasper-client/jasper#
Can you help me to fix this problem?
I tried to insert manually the value in this way:
def get_config_value(config, name, default):
logger = logging.getLogger(name)
try:
value = int(config['2048'][name])
except KeyError:
logger.debug('%s not configured, using default.', name)
value = None
except ValueError:
logger.debug('%s is not an integer, using default.', name)
value = None
return value if value else default
try:
output_padding = config['2048']['output_padding']
except KeyError:
self._logger.debug('output_padding not configured,' +
'using default.')
And I need to change output_padding = config['2048']['output_padding'] because without Jasper doesn't work. With this change on mic.py Jasper work, but by insert the value 2048 or 4096 the problem doesn't fix ...
Its time to learn some basic python.
I have change my profile.yml same here (and try it with both value 2048 and 4096):
carrier: ''
first_name:
last_name:
location:
phone_number: ''
prefers_email: false
stt_engine: sphinx
timezone: Europe/Rome
stt_engine: sphinx
pocketsphinx:
fst_model: '/home/pi/jasper/phonetisaurus/g014b2b.fst' #optional
hmm_dir: '/usr/local/share/pocketsphinx/model/en-us/en-us' #optional
tts_engine: festival-tts
keyword: 'Jasper'
audio_engine: pyaudio
audio:
input_chunksize: '4096'
And Jasper work, but the issue doesn't fix
Last edit: Giovanni 2018-05-01