synesthesiam / rhasspy

Rhasspy voice assistant for offline home automation
https://rhasspy.readthedocs.io
MIT License
944 stars 101 forks source link

Wake Word detection not working #117

Closed matthias-matze closed 4 years ago

matthias-matze commented 4 years ago

Hy,

thanks for that great app !

i'm trying to get rhasspy working, the only thing that can't work is the wake word detection.

I tried pocketsphinx and snowboy without success, if i use the web interface "Wake" button, my mic is working and the wav are played to indicate that the system is listening

It used the Docker version of rhasspy on raspberry pi 2 with a raspiaudio MIC+ interface.

Same result running rhasspy on a Pyhon Virtuel env.

It seems the system is simply not listening

PS: i tried to edit the advanced tab with the instructions in the documentation, but no result.

frkos commented 4 years ago

Hi,

Let's begin with your logs... what do you see there? And what is your profile.json looks like?

matthias-matze commented 4 years ago

Hi,

Here is the profile:

{     "handle": {         "remote": {             "url": "http://192.168.50.249:80/core/api/jeeApi.php?plugin=jeerhasspy&apikey=apikey&plugin=jeerhasspy&type=jeerhasspy"         },         "system": "remote"     },     "microphone": {         "system": "arecord"     },     "text_to_speech": {         "picotts": {             "language": "fr-fr"         },         "system": "picotts"     },     "wake": {         "pocketsphinx": {             "keyphrase": "okay jarvis"         },         "system": "pocketsphinx"     } }

And the log: [INFO:6479533] quart.serving: 192.168.50.83:48080 GET /webfonts/fa-solid-900.woff2 1.1 200 74320 71104 [INFO:6479513] quart.serving: 192.168.50.83:48082 GET /api/events/log 1.1 101 - 21638 [INFO:6479492] quart.serving: 192.168.50.83:48078 GET /api/custom-words 1.1 200 102 100137 [INFO:6479486] quart.serving: 192.168.50.83:48072 GET /api/problems 1.1 200 299 51630

Nothing in the log when i Say the wake word.

Matthias


De : frkos notifications@github.com Envoyé : mercredi 25 décembre 2019 19:25 À : synesthesiam/rhasspy Cc: matthias-matze; Author Objet : Re: [synesthesiam/rhasspy] Wake Word detection not working (#117)

Hi,

Let's begin with your logs... what do you see there? And what is your profile.json looks like?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

frkos commented 4 years ago

Try to push wake button and wait till the command is finished. Do you see anything related to pocketsphinx or snowboy? like this

[DEBUG:40491] SnowboyWakeListener: loaded -> listening

synesthesiam commented 4 years ago

For the record, the pocketsphinx wake word system is pretty bad. I'd try Porcupine first before any of the others.

Do you also have "Listen for wake word on start-up" checked in the Rhasspy section of the Settings?

matthias-matze commented 4 years ago

Hi,

I confirm the option is enable in settings tab. "Enable wake word".

I've tried snwoboy, but i'm not sure if it needs further setup to work, the same with Porcupine, i followed the documentation, but i didn't understand how to personalize the wake word and ensure that it's properly setup.

Matthias


De : Michael Hansen notifications@github.com Envoyé : jeudi 26 décembre 2019 00:10 À : synesthesiam/rhasspy Cc: matthias-matze; Author Objet : Re: [synesthesiam/rhasspy] Wake Word detection not working (#117)

For the record, the pocketsphinx wake word system is pretty bad. I'd try Porcupine first before any of the others.

Do you also have "Listen for wake word on start-up" checked in the Rhasspy section of the Settings?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

frkos commented 4 years ago

I confirm the option is enable in settings tab. "Enable wake word".

Just right above MQTT settings there is a check box 'Listen for wake word on start-up' It should be checked

Please try to select snowboy, download required files and reboot rhasspy... What do you see in the logs? Try to make default word 'snowboy' work before any customization

matthias-matze commented 4 years ago

Hi again,

Same result with snowboy, nothing in the logs.

I tried to manually push the button on the raspiaudio, same, nothing appends, no wake, nothing in log.

The only way to make rhasspy listen is to click on the wake button in the web interface.

Matthias

De : frkos notifications@github.com Envoyé : jeudi 26 décembre 2019 09:54 À : synesthesiam/rhasspy rhasspy@noreply.github.com Cc : matthias-matze matthias@matze.fr; Author author@noreply.github.com Objet : Re: [synesthesiam/rhasspy] Wake Word detection not working (#117)

I confirm the option is enable in settings tab. "Enable wake word".

Just right above MQTT settings there is a check box 'Listen for wake word on start-up' It should be checked

Please try to select snowboy, download required files and reboot rhasspy... What do you see in the logs? Try to make default word 'snowboy' work before any customization

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/synesthesiam/rhasspy/issues/117?email_source=notifications&email_token=AFQ6DUS25PG57TPJFSV7M33Q2RWLHA5CNFSM4J7F42PKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEHVH3PI#issuecomment-569015741 , or unsubscribe https://github.com/notifications/unsubscribe-auth/AFQ6DUWJPGR57DBQ3KI4OELQ2RWLHANCNFSM4J7F42PA . https://github.com/notifications/beacon/AFQ6DUQF5WL2KGELSYQJJO3Q2RWLHA5CNFSM4J7F42PKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEHVH3PI.gif

frkos commented 4 years ago

I believe there is misconfiguration... Please share your profile with snowboy set as a wake word Also check you have downloaded snowboy files in Rhasspy profile folder

matthias-matze commented 4 years ago

Hy,

The profile for the web interface :

{

"handle": {

    "remote": {

        "url": "http://192.168.50.249:80/core/api/jeeApi.php?plugin=jeerhasspy&apikey=O3nAbOrKxB22id0peCjAEtUvbSeHQvgJ&plugin=jeerhasspy&type=jeerhasspy"

    },

    "system": "remote"

},

"microphone": {

    "system": "arecord"

},

"text_to_speech": {

    "picotts": {

        "language": "fr-fr"

    },

    "system": "picotts"

},

"wake": {

    "system": "snowboy",

    "snowboy": {

        "sensitivity": "0.5"

    }

}

}

And :

Matthias

De : frkos notifications@github.com Envoyé : jeudi 26 décembre 2019 21:26 À : synesthesiam/rhasspy rhasspy@noreply.github.com Cc : matthias-matze matthias@matze.fr; Author author@noreply.github.com Objet : Re: [synesthesiam/rhasspy] Wake Word detection not working (#117)

I believe there is misconfiguration... Please share your profile with snowboy set as a wake word Also check you have downloaded snowboy files in Rhasspy profile folder

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/synesthesiam/rhasspy/issues/117?email_source=notifications&email_token=AFQ6DUT3UFKH5UPYPENTMDLQ2UHO3A5CNFSM4J7F42PKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEHWDLGQ#issuecomment-569128346 , or unsubscribe https://github.com/notifications/unsubscribe-auth/AFQ6DUSA2C3Q4GYKPNPXNA3Q2UHO3ANCNFSM4J7F42PA . https://github.com/notifications/beacon/AFQ6DUTJUAF3JGPW6J3YA63Q2UHO3A5CNFSM4J7F42PKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEHWDLGQ.gif

andyinno commented 4 years ago

I think I am in the same situation,

I never used snowboy before but from what I see it should be the best one for foreign languages, in my case italian.

I can see in the logs:

 DEBUG:SnowboyWakeListener:Loading snowboy model from /profiles/it/snowboy/snowboy.umdl
 DEBUG:SnowboyWakeListener:Loaded snowboy model snowboy/snowboy.umdl ({'sensitivity': '0.5', 'audio_gain': 1.0, 'apply_frontend': False})
 DEBUG:SnowboyWakeListener:started -> loaded

I tried in any way to wake up by voice but it won't woke up. I can say that microphone is working because I can wake up using the "wake" button on the browser. Example:

DEBUG:DialogueManager:{'intent': {'name': 'GetTime', 'confidence': 1.0}, 'entities': [], 'text': 'che ore sono', 'raw_text': 'che ore sono', 'recognize_seconds': 0.0011236419995839242, 'tokens': ['che', 'ore', 'sono'], 'raw_tokens': ['che', 'ore', 'sono'], 'speech_confidence': 0.3771120052474623, 'wakeId': '', 'siteId': 'default'}

It correctly decodes "what time it is now"

I am tring to follow the tutorial but maybe there are some settings that must be taken care of for foreign languages? I am italian and Matthias french?

adrianofoschi commented 4 years ago

Hi, probably I have the same issue with italian language too.

My config:

{
    "handle": {
        "system": "hass"
    },
    "home_assistant": {
        "access_token": "...",
        "url": "http://192.168.0.100:8123"
    },
    "sounds": {
        "aplay": {
            "device": "sysdefault:CARD=seeed2micvoicec"
        }
    },
    "text_to_speech": {
        "picotts": {
            "language": "it-IT"
        }
    },
    "wake": {
        "porcupine": {
            "keyword_path": "porcupine/hey_pico_raspberrypi.ppn"
        },
        "system": "porcupine"
    }
}

On first boot I say in sequence: 1- "hey pico", the wake up is activated 2- "what time is it" (in italian), and it works perfectly, the intent is triggered.

This is the log:

[DEBUG:17007632] PyAudioRecorder: recording -> started
[ERROR:17007630] PyAudioRecorder: to_recording
Traceback (most recent call last):
  File "/usr/share/rhasspy/rhasspy/audio_recorder.py", line 205, in to_recording
    frames_per_buffer=self.frames_per_buffer,
  File "/usr/local/lib/python3.6/dist-packages/pyaudio.py", line 750, in open
    stream = Stream(self, *args, **kwargs)
  File "/usr/local/lib/python3.6/dist-packages/pyaudio.py", line 441, in __init__
    self._stream = pa.open(**arguments)
OSError: [Errno -9997] Invalid sample rate
[DEBUG:17007625] PyAudioRecorder: started -> recording
[DEBUG:17007624] PorcupineWakeListener: started -> listening
[DEBUG:17007621] DialogueManager: ready -> asleep
[INFO:17007616] DialogueManager: Automatically listening for wake word
[DEBUG:17007614] DialogueManager: handling -> ready
[DEBUG:17007612] HomeAssistantIntentHandler: POSTed intent to http://192.168.0.100:8123/api/events/rhasspy_GetTime
[DEBUG:17007607] urllib3.connectionpool: http://192.168.0.100:8123 "POST /api/events/rhasspy_GetTime HTTP/1.1" 200 45
[DEBUG:17007593] urllib3.connectionpool: Starting new HTTP connection (1): 192.168.0.100:8123
[DEBUG:17007591] WebSocketObserver: {"intent": {"name": "GetTime", "confidence": 1.0}, "entities": [], "text": "che ore sono", "raw_text": "che ore sono", "recognize_seconds": 0.00110424000013154, "tokens": ["che", "ore", "sono"], "raw_tokens": ["che", "ore", "sono"], "speech_confidence": 0.41694481647450005, "wakeId": "True", "siteId": "default", "hass_event": {"event_type": "rhasspy_GetTime", "event_data": {}}, "slots": {}}
[DEBUG:17007586] DialogueManager: recognizing -> handling
[DEBUG:17007584] DialogueManager: {'intent': {'name': 'GetTime', 'confidence': 1.0}, 'entities': [], 'text': 'che ore sono', 'raw_text': 'che ore sono', 'recognize_seconds': 0.00110424000013154, 'tokens': ['che', 'ore', 'sono'], 'raw_tokens': ['che', 'ore', 'sono'], 'speech_confidence': 0.41694481647450005, 'wakeId': 'True', 'siteId': 'default'}
[DEBUG:17007580] DialogueManager: decoding -> recognizing
[DEBUG:17007578] DialogueManager: che ore sono (confidence=0.41694481647450005)
[DEBUG:17007577] PocketsphinxDecoder: che ore sono
[DEBUG:17007576] PocketsphinxDecoder: Transcription confidence: 0.41694481647450005
[DEBUG:17007573] PocketsphinxDecoder: Decoded WAV in 0.46885132789611816 second(s)
[DEBUG:17007163] PyAudioRecorder: Stopped recording from microphone (PyAudio)
[DEBUG:17007159] PyAudioRecorder: recording -> started
[DEBUG:17007104] APlayAudioPlayer: ['aplay', '-q', '-D', 'sysdefault:CARD=seeed2micvoicec', '/usr/share/rhasspy/etc/wav/beep_lo.wav']
[DEBUG:17007102] PocketsphinxDecoder: rate=16000, width=2, channels=1.
[DEBUG:17007099] DialogueManager: awake -> decoding
[DEBUG:17007096] WebrtcvadCommandListener: listening -> loaded
[DEBUG:17007095] WebrtcvadCommandListener: Voice command finished
[DEBUG:17004905] WebrtcvadCommandListener: Voice command started
[DEBUG:17004453] PyAudioRecorder: Recording from microphone (PyAudio, device=None)
[DEBUG:17004182] PorcupineWakeListener: Loaded porcupine (keyword=[PosixPath('/profiles/it/porcupine/hey_pico_raspberrypi.ppn')]). Expecting sample rate=16000, frame length=512
[DEBUG:17004175] PyAudioRecorder: started -> recording
[DEBUG:17004174] PyAudioRecorder: Stopped recording from microphone (PyAudio)
[DEBUG:17004139] PyAudioRecorder: recording -> started
[DEBUG:17004108] PorcupineWakeListener: listening -> started
[DEBUG:17004103] APlayAudioPlayer: ['aplay', '-q', '-D', 'sysdefault:CARD=seeed2micvoicec', '/usr/share/rhasspy/etc/wav/beep_hi.wav']
[DEBUG:17004102] WebrtcvadCommandListener: loaded -> listening
[DEBUG:17004099] WebrtcvadCommandListener: Will timeout in 30 second(s)
[DEBUG:17004094] DialogueManager: asleep -> awake
[DEBUG:17004093] DialogueManager: Awake!
[DEBUG:17004091] PorcupineWakeListener: Hotword detected (True)
[INFO:16994358] quart.serving: 192.168.0.109:36902 GET /img/favicon.png 1.1 200 802 8833
[INFO:16994309] quart.serving: 192.168.0.109:36884 GET /api/problems 1.1 200 297 23081
[INFO:16994304] quart.serving: 192.168.0.109:36896 GET /api/custom-words 1.1 200 143 60671
[INFO:16994288] quart.serving: 192.168.0.109:36894 GET /api/speakers 1.1 200 1249 122893
[INFO:16994286] quart.serving: 192.168.0.109:36902 GET /api/unknown-words 1.1 200 164 24897
[INFO:16994284] quart.serving: 192.168.0.109:36900 GET /api/version 1.1 200 6 107495
[INFO:16994282] quart.serving: 192.168.0.109:36898 GET /api/profile 1.1 200 687 117112
[INFO:16994269] quart.serving: 192.168.0.109:36884 GET /api/profile 1.1 200 6569 26551
[INFO:16994240] quart.serving: 192.168.0.109:36902 GET /api/profiles 1.1 200 144 19086
[INFO:16994234] quart.serving: 192.168.0.109:36896 GET /api/profile 1.1 200 7571 56904
[INFO:16994222] quart.serving: 192.168.0.109:36884 GET /api/microphones 1.1 200 135 72684
[INFO:16994168] quart.serving: 192.168.0.109:36902 GET /api/phonemes 1.1 200 1139 19222
[DEBUG:16994153] __main__: Loading phoneme examples from /usr/share/rhasspy/profiles/it/phoneme_examples.txt
[INFO:16994148] quart.serving: 192.168.0.109:36896 GET /api/slots 1.1 200 2 8193
[INFO:16994138] quart.serving: 192.168.0.109:36902 GET /api/sentences 1.1 200 349 7725
[INFO:16994052] quart.serving: 192.168.0.109:36904 GET /api/events/log 1.1 101 - 18382
[INFO:16994049] quart.serving: 192.168.0.109:36902 GET /img/logo.png 1.1 200 1924 8775

The problem is if I try again it doesn't work, I need to restart rhasspy and it works again. Probably the error in top of the log breaks something...

matthias-matze commented 4 years ago

Hy,

Tried to switch my config to an english profile -> Same result, noreaction to wake word. (PocketSphinx or snowboy)

Matthias

De : Adriano Foschi notifications@github.com Envoyé : samedi 28 décembre 2019 01:05 À : synesthesiam/rhasspy rhasspy@noreply.github.com Cc : matthias-matze matthias@matze.fr; Author author@noreply.github.com Objet : Re: [synesthesiam/rhasspy] Wake Word detection not working (#117)

Hi, probably I have the same issue with italian language too.

My config:

{ "handle": { "system": "hass" }, "home_assistant": { "access_token": "...", "url": "http://192.168.0.100:8123" }, "sounds": { "aplay": { "device": "sysdefault:CARD=seeed2micvoicec" } }, "text_to_speech": { "picotts": { "language": "it-IT" } }, "wake": { "porcupine": { "keyword_path": "porcupine/hey_pico_raspberrypi.ppn" }, "system": "porcupine" } }

On first boot I say in sequence: 1- "hey pico", the wake up is activated 2- "what time is it" (in italian), and it works perfectly.

This is the log:

[DEBUG:17007632] PyAudioRecorder: recording -> started [ERROR:17007630] PyAudioRecorder: to_recording Traceback (most recent call last): File "/usr/share/rhasspy/rhasspy/audio_recorder.py", line 205, in to_recording frames_per_buffer=self.frames_per_buffer, File "/usr/local/lib/python3.6/dist-packages/pyaudio.py", line 750, in open stream = Stream(self, *args, kwargs) File "/usr/local/lib/python3.6/dist-packages/pyaudio.py", line 441, in init self._stream = pa.open(arguments) OSError: [Errno -9997] Invalid sample rate [DEBUG:17007625] PyAudioRecorder: started -> recording [DEBUG:17007624] PorcupineWakeListener: started -> listening [DEBUG:17007621] DialogueManager: ready -> asleep [INFO:17007616] DialogueManager: Automatically listening for wake word [DEBUG:17007614] DialogueManager: handling -> ready [DEBUG:17007612] HomeAssistantIntentHandler: POSTed intent to http://192.168.0.100:8123/api/events/rhasspy_GetTime [DEBUG:17007607] urllib3.connectionpool: http://192.168.0.100:8123 "POST /api/events/rhasspy_GetTime HTTP/1.1" 200 45 [DEBUG:17007593] urllib3.connectionpool: Starting new HTTP connection (1): 192.168.0.100:8123 [DEBUG:17007591] WebSocketObserver: {"intent": {"name": "GetTime", "confidence": 1.0}, "entities": [], "text": "che ore sono", "raw_text": "che ore sono", "recognize_seconds": 0.00110424000013154, "tokens": ["che", "ore", "sono"], "raw_tokens": ["che", "ore", "sono"], "speech_confidence": 0.41694481647450005, "wakeId": "True", "siteId": "default", "hass_event": {"event_type": "rhasspy_GetTime", "event_data": {}}, "slots": {}} [DEBUG:17007586] DialogueManager: recognizing -> handling [DEBUG:17007584] DialogueManager: {'intent': {'name': 'GetTime', 'confidence': 1.0}, 'entities': [], 'text': 'che ore sono', 'raw_text': 'che ore sono', 'recognize_seconds': 0.00110424000013154, 'tokens': ['che', 'ore', 'sono'], 'raw_tokens': ['che', 'ore', 'sono'], 'speech_confidence': 0.41694481647450005, 'wakeId': 'True', 'siteId': 'default'} [DEBUG:17007580] DialogueManager: decoding -> recognizing [DEBUG:17007578] DialogueManager: che ore sono (confidence=0.41694481647450005) [DEBUG:17007577] PocketsphinxDecoder: che ore sono [DEBUG:17007576] PocketsphinxDecoder: Transcription confidence: 0.41694481647450005 [DEBUG:17007573] PocketsphinxDecoder: Decoded WAV in 0.46885132789611816 second(s) [DEBUG:17007163] PyAudioRecorder: Stopped recording from microphone (PyAudio) [DEBUG:17007159] PyAudioRecorder: recording -> started [DEBUG:17007104] APlayAudioPlayer: ['aplay', '-q', '-D', 'sysdefault:CARD=seeed2micvoicec', '/usr/share/rhasspy/etc/wav/beep_lo.wav'] [DEBUG:17007102] PocketsphinxDecoder: rate=16000, width=2, channels=1. [DEBUG:17007099] DialogueManager: awake -> decoding [DEBUG:17007096] WebrtcvadCommandListener: listening -> loaded [DEBUG:17007095] WebrtcvadCommandListener: Voice command finished [DEBUG:17004905] WebrtcvadCommandListener: Voice command started [DEBUG:17004453] PyAudioRecorder: Recording from microphone (PyAudio, device=None) [DEBUG:17004182] PorcupineWakeListener: Loaded porcupine (keyword=[PosixPath('/profiles/it/porcupine/hey_pico_raspberrypi.ppn')]). Expecting sample rate=16000, frame length=512 [DEBUG:17004175] PyAudioRecorder: started -> recording [DEBUG:17004174] PyAudioRecorder: Stopped recording from microphone (PyAudio) [DEBUG:17004139] PyAudioRecorder: recording -> started [DEBUG:17004108] PorcupineWakeListener: listening -> started [DEBUG:17004103] APlayAudioPlayer: ['aplay', '-q', '-D', 'sysdefault:CARD=seeed2micvoicec', '/usr/share/rhasspy/etc/wav/beep_hi.wav'] [DEBUG:17004102] WebrtcvadCommandListener: loaded -> listening [DEBUG:17004099] WebrtcvadCommandListener: Will timeout in 30 second(s) [DEBUG:17004094] DialogueManager: asleep -> awake [DEBUG:17004093] DialogueManager: Awake! [DEBUG:17004091] PorcupineWakeListener: Hotword detected (True) [INFO:16994358] quart.serving: 192.168.0.109:36902 GET /img/favicon.png 1.1 200 802 8833 [INFO:16994309] quart.serving: 192.168.0.109:36884 GET /api/problems 1.1 200 297 23081 [INFO:16994304] quart.serving: 192.168.0.109:36896 GET /api/custom-words 1.1 200 143 60671 [INFO:16994288] quart.serving: 192.168.0.109:36894 GET /api/speakers 1.1 200 1249 122893 [INFO:16994286] quart.serving: 192.168.0.109:36902 GET /api/unknown-words 1.1 200 164 24897 [INFO:16994284] quart.serving: 192.168.0.109:36900 GET /api/version 1.1 200 6 107495 [INFO:16994282] quart.serving: 192.168.0.109:36898 GET /api/profile 1.1 200 687 117112 [INFO:16994269] quart.serving: 192.168.0.109:36884 GET /api/profile 1.1 200 6569 26551 [INFO:16994240] quart.serving: 192.168.0.109:36902 GET /api/profiles 1.1 200 144 19086 [INFO:16994234] quart.serving: 192.168.0.109:36896 GET /api/profile 1.1 200 7571 56904 [INFO:16994222] quart.serving: 192.168.0.109:36884 GET /api/microphones 1.1 200 135 72684 [INFO:16994168] quart.serving: 192.168.0.109:36902 GET /api/phonemes 1.1 200 1139 19222 [DEBUG:16994153] main: Loading phoneme examples from /usr/share/rhasspy/profiles/it/phoneme_examples.txt [INFO:16994148] quart.serving: 192.168.0.109:36896 GET /api/slots 1.1 200 2 8193 [INFO:16994138] quart.serving: 192.168.0.109:36902 GET /api/sentences 1.1 200 349 7725 [INFO:16994052] quart.serving: 192.168.0.109:36904 GET /api/events/log 1.1 101 - 18382 [INFO:16994049] quart.serving: 192.168.0.109:36902 GET /img/logo.png 1.1 200 1924 8775

The problem is if I try again it doesn't work, I need to restart rhasspy and it works again.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/synesthesiam/rhasspy/issues/117?email_source=notifications&email_token=AFQ6DUR3NWYRUJLLLCCIOBLQ22J3DA5CNFSM4J7F42PKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEHX5RVI#issuecomment-569366741 , or unsubscribe https://github.com/notifications/unsubscribe-auth/AFQ6DURZHHOQTK5PRA53KWDQ22J3DANCNFSM4J7F42PA . https://github.com/notifications/beacon/AFQ6DUQF6DPJBJUFSTBZ4D3Q22J3DA5CNFSM4J7F42PKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEHX5RVI.gif

frkos commented 4 years ago

Hi @adrianofoschi Do you use the last version? Looks like your issue is similar to this https://github.com/synesthesiam/rhasspy/issues/90 Could you check your docker logs? Also try to select different device in microphone section

Hi @matthias-matze could you check your docker logs too? it's weird that you have no error messages and nothing related to snowboy.... =(

matthias-matze commented 4 years ago

Hi,

Here is a log.

You’ll seen successfull tests when i use the Wake button from the web interface.

I tried to switch from aply to arecord without success, also disabled audio from PI with « dtparam=audio=off »

Still no success.

Matthias

De : frkos notifications@github.com Envoyé : samedi 28 décembre 2019 10:30 À : synesthesiam/rhasspy rhasspy@noreply.github.com Cc : matthias-matze matthias@matze.fr; Mention mention@noreply.github.com Objet : Re: [synesthesiam/rhasspy] Wake Word detection not working (#117)

Hi @adrianofoschi https://github.com/adrianofoschi Do you use the last version? Looks like your issue is similar to this #90 https://github.com/synesthesiam/rhasspy/issues/90 Could you check your docker logs? Also try to select different device in microphone section

Hi @matthias-matze https://github.com/matthias-matze could you check your docker logs too? it's weird that you have no error messages and nothing related to snowboy.... =(

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/synesthesiam/rhasspy/issues/117?email_source=notifications&email_token=AFQ6DUSUKVAJDB23FENJQSLQ24MA3A5CNFSM4J7F42PKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEHYGB7Y#issuecomment-569401599 , or unsubscribe https://github.com/notifications/unsubscribe-auth/AFQ6DUQOHOCTKN7WAPMMN63Q24MA3ANCNFSM4J7F42PA . https://github.com/notifications/beacon/AFQ6DUVG7MYNDDA5BQJ5PPDQ24MA3A5CNFSM4J7F42PKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEHYGB7Y.gif

DEBUG:main:Namespace(host='0.0.0.0', log_level='DEBUG', port=12101, profile='en', set=[], ssl=None, system_profiles='/usr/share/rhasspy/profiles', user_profiles='/profiles') DEBUG:RhasspyCore:Loaded profile from /profiles/en/profile.json DEBUG:RhasspyCore:Profile files will be written to /profiles/en DEBUG:root:Loading default profile settings from /usr/share/rhasspy/profiles/defaults.json DEBUG:WebSocketObserver: -> started DEBUG:DialogueManager: -> started DEBUG:DialogueManager:started -> loading DEBUG:DialogueManager:Loading actors DEBUG:DialogueManager:Actors created. Waiting for ['recorder', 'player', 'speech', 'wake', 'command', 'decoder', 'recognizer', 'handler', 'speech_trainer', 'intent_trainer', 'word_pronouncer'] to start. DEBUG:APlayAudioPlayer: -> started DEBUG:WebrtcvadCommandListener: -> started DEBUG:PocketsphinxDecoder: -> started DEBUG:FsticuffsRecognizer: -> started DEBUG:DummyIntentHandler: -> started DEBUG:PhonetisaurusPronounce: -> started DEBUG:PyAudioRecorder: -> started DEBUG:EspeakSentenceSpeaker: -> started DEBUG:DialogueManager:player started DEBUG:SnowboyWakeListener: -> started DEBUG:WebrtcvadCommandListener:started -> loaded DEBUG:PocketsphinxSpeechTrainer: -> started DEBUG:FsticuffsIntentTrainer: -> started DEBUG:EspeakSentenceSpeaker:started -> ready DEBUG:DialogueManager:handler started DEBUG:FsticuffsRecognizer:Using stop words at /usr/share/rhasspy/profiles/en/stop_words.txt DEBUG:DialogueManager:word_pronouncer started DEBUG:DialogueManager:recorder started DEBUG:DialogueManager:command started DEBUG:DialogueManager:speech_trainer started DEBUG:DialogueManager:intent_trainer started DEBUG:DialogueManager:speech started DEBUG:FsticuffsRecognizer:started -> loaded DEBUG:DialogueManager:recognizer started DEBUG:PocketsphinxDecoder:Loading decoder with hmm=/profiles/en/acoustic_model, dict=/profiles/en/dictionary.txt, lm=/profiles/en/language_model.txt DEBUG:SnowboyWakeListener:Loading snowboy model from /profiles/en/snowboy/snowboy.umdl DEBUG:SnowboyWakeListener:Loaded snowboy model snowboy/snowboy.umdl ({'sensitivity': '0.5', 'audio_gain': 1.0, 'apply_frontend': False}) DEBUG:SnowboyWakeListener:started -> loaded DEBUG:DialogueManager:wake started DEBUG:PocketsphinxDecoder:started -> loaded DEBUG:DialogueManager:decoder started DEBUG:DialogueManager:Actors loaded DEBUG:DialogueManager:loading -> ready INFO:DialogueManager:Automatically listening for wake word DEBUG:DialogueManager:ready -> asleep DEBUG:SnowboyWakeListener:loaded -> listening INFO:main:Started DEBUG:PyAudioRecorder:started -> recording DEBUG:main:Starting web server at http://0.0.0.0:12101 Running on https://0.0.0.0:12101 (CTRL + C to quit) [2019-12-28 09:25:09,189] ASGI Framework Lifespan error, continuing without Lifespan support WARNING:quart.serving:ASGI Framework Lifespan error, continuing without Lifespan support ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.front ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.rear ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.center_lfe ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.side ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround21 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround21 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround40 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround41 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround50 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround51 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround71 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.iec958 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.iec958 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.iec958 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.hdmi ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.hdmi ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.modem ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.modem ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.phoneline ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.phoneline DEBUG:PyAudioRecorder:Recording from microphone (PyAudio, device=None) [2019-12-28 09:26:06,950] 192.168.50.59:51766 GET / 1.1 200 1029 31134 INFO:quart.serving:192.168.50.59:51766 GET / 1.1 200 1029 31134 [2019-12-28 09:26:06,961] 192.168.50.59:51763 GET /api/events/log 1.1 101 - 57503364 INFO:quart.serving:192.168.50.59:51763 GET /api/events/log 1.1 101 - 57503364 [2019-12-28 09:26:06,973] 192.168.50.59:51765 GET /api/events/log 1.1 101 - 26685645 INFO:quart.serving:192.168.50.59:51765 GET /api/events/log 1.1 101 - 26685645 ERROR:main:api_events_log Traceback (most recent call last): File "app.py", line 1124, in api_events_log await websocket.send(text) File "/usr/local/lib/python3.6/dist-packages/quart/wrappers/request.py", line 296, in send await asyncio.sleep(0) File "/usr/lib/python3.6/asyncio/tasks.py", line 472, in sleep yield concurrent.futures._base.CancelledError ERROR:main:api_events_log Traceback (most recent call last): File "app.py", line 1123, in api_events_log text = await q.get() File "/usr/lib/python3.6/asyncio/queues.py", line 167, in get yield from getter concurrent.futures._base.CancelledError [2019-12-28 09:26:07,021] Error in ASGI Framework Traceback (most recent call last): File "/usr/local/lib/python3.6/dist-packages/hypercorn/asgi/wsproto.py", line 91, in handle_asgi_app await asgi_instance(self.asgi_receive, self.asgi_send) File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 106, in call await _cancel_tasks(pending) File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 189, in _cancel_tasks raise task.exception() File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 157, in handle_websocket 'code': 1000, File "/usr/local/lib/python3.6/dist-packages/hypercorn/asgi/wsproto.py", line 149, in asgi_send await self.asend(CloseConnection(code=int(message["code"]))) File "/usr/local/lib/python3.6/dist-packages/hypercorn/asyncio/wsproto.py", line 93, in asend self.write(self.connection.send(event)) File "/usr/local/lib/python3.6/dist-packages/wsproto/init.py", line 64, in send data += self.connection.send(event) File "/usr/local/lib/python3.6/dist-packages/wsproto/connection.py", line 101, in send "Connection cannot be closed in state %s" % self.state wsproto.utilities.LocalProtocolError: Connection cannot be closed in state ConnectionState.CLOSED ERROR:quart.serving:Error in ASGI Framework Traceback (most recent call last): File "/usr/local/lib/python3.6/dist-packages/hypercorn/asgi/wsproto.py", line 91, in handle_asgi_app await asgi_instance(self.asgi_receive, self.asgi_send) File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 106, in call await _cancel_tasks(pending) File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 189, in _cancel_tasks raise task.exception() File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 157, in handle_websocket 'code': 1000, File "/usr/local/lib/python3.6/dist-packages/hypercorn/asgi/wsproto.py", line 149, in asgi_send await self.asend(CloseConnection(code=int(message["code"]))) File "/usr/local/lib/python3.6/dist-packages/hypercorn/asyncio/wsproto.py", line 93, in asend self.write(self.connection.send(event)) File "/usr/local/lib/python3.6/dist-packages/wsproto/init.py", line 64, in send data += self.connection.send(event) File "/usr/local/lib/python3.6/dist-packages/wsproto/connection.py", line 101, in send "Connection cannot be closed in state %s" % self.state wsproto.utilities.LocalProtocolError: Connection cannot be closed in state ConnectionState.CLOSED ERROR:quart.serving:Error in ASGI Framework Traceback (most recent call last): File "/usr/local/lib/python3.6/dist-packages/hypercorn/asgi/wsproto.py", line 91, in handle_asgi_app await asgi_instance(self.asgi_receive, self.asgi_send) File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 106, in call await _cancel_tasks(pending) File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 189, in _cancel_tasks raise task.exception() [2019-12-28 09:26:07,043] Error in ASGI Framework Traceback (most recent call last): File "/usr/local/lib/python3.6/dist-packages/hypercorn/asgi/wsproto.py", line 91, in handle_asgi_app await asgi_instance(self.asgi_receive, self.asgi_send) File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 106, in call await _cancel_tasks(pending) File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 189, in _cancel_tasks raise task.exception() File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 157, in handle_websocket 'code': 1000, File "/usr/local/lib/python3.6/dist-packages/hypercorn/asgi/wsproto.py", line 149, in asgi_send await self.asend(CloseConnection(code=int(message["code"]))) File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 157, in handle_websocket 'code': 1000, File "/usr/local/lib/python3.6/dist-packages/hypercorn/asgi/wsproto.py", line 149, in asgi_send await self.asend(CloseConnection(code=int(message["code"]))) File "/usr/local/lib/python3.6/dist-packages/hypercorn/asyncio/wsproto.py", line 93, in asend self.write(self.connection.send(event)) File "/usr/local/lib/python3.6/dist-packages/wsproto/init.py", line 64, in send data += self.connection.send(event) File "/usr/local/lib/python3.6/dist-packages/wsproto/connection.py", line 101, in send "Connection cannot be closed in state %s" % self.state wsproto.utilities.LocalProtocolError: Connection cannot be closed in state ConnectionState.CLOSED File "/usr/local/lib/python3.6/dist-packages/hypercorn/asyncio/wsproto.py", line 93, in asend self.write(self.connection.send(event)) File "/usr/local/lib/python3.6/dist-packages/wsproto/init.py", line 64, in send data += self.connection.send(event) File "/usr/local/lib/python3.6/dist-packages/wsproto/connection.py", line 101, in send "Connection cannot be closed in state %s" % self.state wsproto.utilities.LocalProtocolError: Connection cannot be closed in state ConnectionState.CLOSED INFO:quart.serving:192.168.50.59:51766 GET /css/bootstrap.min.css 1.1 200 140930 21071 [2019-12-28 09:26:07,234] 192.168.50.59:51766 GET /css/bootstrap.min.css 1.1 200 140930 21071 [2019-12-28 09:26:07,330] 192.168.50.59:51768 GET /css/main.css 1.1 200 688 79090 INFO:quart.serving:192.168.50.59:51768 GET /css/main.css 1.1 200 688 79090 [2019-12-28 09:26:07,332] 192.168.50.59:51767 GET /css/fontawesome-all.min.css 1.1 200 54456 82496 INFO:quart.serving:192.168.50.59:51767 GET /css/fontawesome-all.min.css 1.1 200 54456 82496 [2019-12-28 09:26:07,334] 192.168.50.59:51769 GET /css/app.3074119d.css 1.1 200 309 83398 INFO:quart.serving:192.168.50.59:51769 GET /css/app.3074119d.css 1.1 200 309 83398 [2019-12-28 09:26:07,337] 192.168.50.59:51770 GET /js/recorder.js 1.1 200 13027 85217 INFO:quart.serving:192.168.50.59:51770 GET /js/recorder.js 1.1 200 13027 85217 [2019-12-28 09:26:07,342] 192.168.50.59:51771 GET /js/jquery-3.3.1.slim.min.js 1.1 200 69917 89513 INFO:quart.serving:192.168.50.59:51771 GET /js/jquery-3.3.1.slim.min.js 1.1 200 69917 89513 [2019-12-28 09:26:07,855] 192.168.50.59:51770 GET /js/axios.min.js 1.1 200 12941 26131 INFO:quart.serving:192.168.50.59:51770 GET /js/axios.min.js 1.1 200 12941 26131 [2019-12-28 09:26:07,915] 192.168.50.59:51769 GET /js/bootstrap.min.js 1.1 200 50731 45725 INFO:quart.serving:192.168.50.59:51769 GET /js/bootstrap.min.js 1.1 200 50731 45725 [2019-12-28 09:26:07,921] 192.168.50.59:51768 GET /js/vue-axios.min.js 1.1 200 673 41770 INFO:quart.serving:192.168.50.59:51768 GET /js/vue-axios.min.js 1.1 200 673 41770 [2019-12-28 09:26:08,302] 192.168.50.59:51767 GET /js/app.a4422e56.js 1.1 200 148688 50412 INFO:quart.serving:192.168.50.59:51767 GET /js/app.a4422e56.js 1.1 200 148688 50412 [2019-12-28 09:26:08,684] 192.168.50.59:51766 GET /js/chunk-vendors.323824ab.js 1.1 200 279468 448574 INFO:quart.serving:192.168.50.59:51766 GET /js/chunk-vendors.323824ab.js 1.1 200 279468 448574 [2019-12-28 09:26:09,821] 192.168.50.59:51766 GET /img/logo.png 1.1 200 1924 21594 INFO:quart.serving:192.168.50.59:51766 GET /img/logo.png 1.1 200 1924 21594 [2019-12-28 09:26:09,928] 192.168.50.59:51766 GET /api/sentences 1.1 200 581 46458 INFO:quart.serving:192.168.50.59:51766 GET /api/sentences 1.1 200 581 46458 DEBUG:main:Loading phoneme examples from /usr/share/rhasspy/profiles/en/phoneme_examples.txt [2019-12-28 09:26:09,961] 192.168.50.59:51767 GET /api/slots 1.1 200 2 60022 INFO:quart.serving:192.168.50.59:51767 GET /api/slots 1.1 200 2 60022 [2019-12-28 09:26:10,012] 192.168.50.59:51771 GET /api/phonemes 1.1 200 1526 88619 INFO:quart.serving:192.168.50.59:51771 GET /api/phonemes 1.1 200 1526 88619 [2019-12-28 09:26:10,026] 192.168.50.59:51769 GET /api/microphones 1.1 200 94 104696 INFO:quart.serving:192.168.50.59:51769 GET /api/microphones 1.1 200 94 104696 [2019-12-28 09:26:10,087] 192.168.50.59:51767 GET /api/profile 1.1 200 8632 51531 INFO:quart.serving:192.168.50.59:51767 GET /api/profile 1.1 200 8632 51531 [2019-12-28 09:26:10,095] 192.168.50.59:51771 GET /api/profiles 1.1 200 144 58457 INFO:quart.serving:192.168.50.59:51771 GET /api/profiles 1.1 200 144 58457 [2019-12-28 09:26:10,116] 192.168.50.59:51770 GET /api/speakers 1.1 200 401 161903 INFO:quart.serving:192.168.50.59:51770 GET /api/speakers 1.1 200 401 161903 [2019-12-28 09:26:10,125] 192.168.50.59:51768 GET /api/profile 1.1 200 51 169824 INFO:quart.serving:192.168.50.59:51768 GET /api/profile 1.1 200 51 169824 [2019-12-28 09:26:10,128] 192.168.50.59:51769 GET /api/profile 1.1 200 6781 29937 INFO:quart.serving:192.168.50.59:51769 GET /api/profile 1.1 200 6781 29937 [2019-12-28 09:26:10,139] 192.168.50.59:51766 GET /api/version 1.1 200 6 119084 INFO:quart.serving:192.168.50.59:51766 GET /api/version 1.1 200 6 119084 [2019-12-28 09:26:10,152] 192.168.50.59:51767 GET /api/custom-words 1.1 200 19 36990 INFO:quart.serving:192.168.50.59:51767 GET /api/custom-words 1.1 200 19 36990 [2019-12-28 09:26:10,192] 192.168.50.59:51771 GET /api/unknown-words 1.1 200 2 12857 INFO:quart.serving:192.168.50.59:51771 GET /api/unknown-words 1.1 200 2 12857 [2019-12-28 09:26:10,204] 192.168.50.59:51768 GET /api/problems 1.1 200 287 15905 INFO:quart.serving:192.168.50.59:51768 GET /api/problems 1.1 200 287 15905 [2019-12-28 09:26:10,293] 192.168.50.59:51766 GET /img/favicon.png 1.1 200 802 13514 INFO:quart.serving:192.168.50.59:51766 GET /img/favicon.png 1.1 200 802 13514 INFO:main:Starting training DEBUG:DialogueManager:asleep -> training_sentences DEBUG:SnowboyWakeListener:listening -> loaded [2019-12-28 09:26:19,650] 192.168.50.59:51776 GET /api/unknown-words 1.1 200 2 34055 INFO:quart.serving:192.168.50.59:51776 GET /api/unknown-words 1.1 200 2 34055 [2019-12-28 09:26:19,666] 192.168.50.59:51774 GET /api/events/log 1.1 101 - 2737434 WARNING:train:Unsupported acoustic model type: pocketsphinx INFO:quart.serving:192.168.50.59:51774 GET /api/events/log 1.1 101 - 2737434 DEBUG:train:Parsing ini file(s): ['/usr/share/rhasspy/profiles/en/sentences.ini'] DEBUG:rhasspynlu.ini_jsgf:Loaded ini file ERROR:asyncio:Task exception was never retrieved future: <Task finished coro=<WebsocketMixin.handle_websocket() done, defined at /usr/local/lib/python3.6/dist-packages/hypercorn/asgi/wsproto.py:60> exception=LocalProtocolError('Connection cannot be closed in state ConnectionState.CLOSED',)> Traceback (most recent call last): File "/usr/local/lib/python3.6/dist-packages/hypercorn/asgi/wsproto.py", line 91, in handle_asgi_app await asgi_instance(self.asgi_receive, self.asgi_send) File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 106, in call await _cancel_tasks(pending) File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 189, in _cancel_tasks raise task.exception() File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 157, in handle_websocket 'code': 1000, File "/usr/local/lib/python3.6/dist-packages/hypercorn/asgi/wsproto.py", line 149, in asgi_send await self.asend(CloseConnection(code=int(message["code"]))) File "/usr/local/lib/python3.6/dist-packages/hypercorn/asyncio/wsproto.py", line 93, in asend self.write(self.connection.send(event)) File "/usr/local/lib/python3.6/dist-packages/wsproto/init.py", line 64, in send data += self.connection.send(event) File "/usr/local/lib/python3.6/dist-packages/wsproto/connection.py", line 101, in send "Connection cannot be closed in state %s" % self.state wsproto.utilities.LocalProtocolError: Connection cannot be closed in state ConnectionState.CLOSED

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "/usr/local/lib/python3.6/dist-packages/hypercorn/asgi/wsproto.py", line 78, in handle_websocket await self.handle_asgi_app(event) File "/usr/local/lib/python3.6/dist-packages/hypercorn/asgi/wsproto.py", line 99, in handle_asgi_app await self.asend(CloseConnection(code=CloseReason.ABNORMAL_CLOSURE)) File "/usr/local/lib/python3.6/dist-packages/hypercorn/asyncio/wsproto.py", line 93, in asend self.write(self.connection.send(event)) File "/usr/local/lib/python3.6/dist-packages/wsproto/init.py", line 64, in send data += self.connection.send(event) File "/usr/local/lib/python3.6/dist-packages/wsproto/connection.py", line 101, in send "Connection cannot be closed in state %s" % self.state wsproto.utilities.LocalProtocolError: Connection cannot be closed in state ConnectionState.CLOSED ERROR:asyncio:Task exception was never retrieved future: <Task finished coro=<WebsocketMixin.handle_websocket() done, defined at /usr/local/lib/python3.6/dist-packages/hypercorn/asgi/wsproto.py:60> exception=LocalProtocolError('Connection cannot be closed in state ConnectionState.CLOSED',)> Traceback (most recent call last): File "/usr/local/lib/python3.6/dist-packages/hypercorn/asgi/wsproto.py", line 91, in handle_asgi_app await asgi_instance(self.asgi_receive, self.asgi_send) File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 106, in call await _cancel_tasks(pending) File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 189, in _cancel_tasks raise task.exception() File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 157, in handle_websocket 'code': 1000, File "/usr/local/lib/python3.6/dist-packages/hypercorn/asgi/wsproto.py", line 149, in asgi_send await self.asend(CloseConnection(code=int(message["code"]))) File "/usr/local/lib/python3.6/dist-packages/hypercorn/asyncio/wsproto.py", line 93, in asend self.write(self.connection.send(event)) File "/usr/local/lib/python3.6/dist-packages/wsproto/init.py", line 64, in send data += self.connection.send(event) File "/usr/local/lib/python3.6/dist-packages/wsproto/connection.py", line 101, in send "Connection cannot be closed in state %s" % self.state wsproto.utilities.LocalProtocolError: Connection cannot be closed in state ConnectionState.CLOSED

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "/usr/local/lib/python3.6/dist-packages/hypercorn/asgi/wsproto.py", line 78, in handle_websocket await self.handle_asgi_app(event) File "/usr/local/lib/python3.6/dist-packages/hypercorn/asgi/wsproto.py", line 99, in handle_asgi_app await self.asend(CloseConnection(code=CloseReason.ABNORMAL_CLOSURE)) File "/usr/local/lib/python3.6/dist-packages/hypercorn/asyncio/wsproto.py", line 93, in asend self.write(self.connection.send(event)) File "/usr/local/lib/python3.6/dist-packages/wsproto/init.py", line 64, in send data += self.connection.send(event) File "/usr/local/lib/python3.6/dist-packages/wsproto/connection.py", line 101, in send "Connection cannot be closed in state %s" % self.state wsproto.utilities.LocalProtocolError: Connection cannot be closed in state ConnectionState.CLOSED DEBUG:DialogueManager:training_sentences -> training_intent INFO:DialogueManager:Training complete DEBUG:DialogueManager:Reloading actors DEBUG:SnowboyWakeListener:loaded -> stopped DEBUG:PocketsphinxDecoder:loaded -> stopped DEBUG:FsticuffsRecognizer:loaded -> stopped DEBUG:DialogueManager:training_intent -> training_loading DEBUG:SnowboyWakeListener: -> started DEBUG:PocketsphinxDecoder: -> started DEBUG:FsticuffsRecognizer: -> started DEBUG:SnowboyWakeListener:Loading snowboy model from /profiles/en/snowboy/snowboy.umdl DEBUG:SnowboyWakeListener:Loaded snowboy model snowboy/snowboy.umdl ({'sensitivity': '0.5', 'audio_gain': 1.0, 'apply_frontend': False}) DEBUG:SnowboyWakeListener:started -> loaded DEBUG:PocketsphinxDecoder:Loading decoder with hmm=/profiles/en/acoustic_model, dict=/profiles/en/dictionary.txt, lm=/profiles/en/language_model.txt DEBUG:FsticuffsRecognizer:Using stop words at /usr/share/rhasspy/profiles/en/stop_words.txt DEBUG:FsticuffsRecognizer:started -> loaded DEBUG:PocketsphinxDecoder:started -> loaded INFO:DialogueManager:Actors reloaded DEBUG:DialogueManager:training_loading -> ready INFO:DialogueManager:Automatically listening for wake word DEBUG:DialogueManager:ready -> asleep DEBUG:SnowboyWakeListener:loaded -> listening -- ini_graph -- intent_fst -- language_model:intent_counts -- language_model:intent_model -- language_model:intent_arpa -- vocab -- vocab_dict [2019-12-28 09:26:32,988] 192.168.50.59:51775 POST /api/train 1.1 200 37 13373784 INFO:quart.serving:192.168.50.59:51775 POST /api/train 1.1 200 37 13373784 [2019-12-28 09:26:33,254] 192.168.50.59:51775 GET /api/problems 1.1 200 287 14354 INFO:quart.serving:192.168.50.59:51775 GET /api/problems 1.1 200 287 14354 INFO:quart.serving:192.168.50.59:51780 POST /api/start-recording 1.1 200 2 14932 [2019-12-28 09:27:09,023] 192.168.50.59:51780 POST /api/start-recording 1.1 200 2 14932 DEBUG:main:Recorded 67244 byte(s) of audio data DEBUG:PocketsphinxDecoder:rate=16000, width=2, channels=1. DEBUG:PocketsphinxDecoder:Decoded WAV in 4.476516246795654 second(s) DEBUG:PocketsphinxDecoder:Transcription confidence: 0.00426961147104037 DEBUG:PocketsphinxDecoder:what time is it DEBUG:main:what time is it DEBUG:main:{"intent": {"name": "GetTime", "confidence": 1.0}, "entities": [], "text": "what time is it", "raw_text": "what time is it", "recognize_seconds": 0.0019147360003444192, "tokens": ["what", "time", "is", "it"], "raw_tokens": ["what", "time", "is", "it"], "speech_confidence": 0.00426961147104037, "slots": {}, "wakeId": "", "siteId": "default"} INFO:quart.serving:192.168.50.59:51780 POST /api/stop-recording 1.1 200 312 4548329 [2019-12-28 09:27:15,673] 192.168.50.59:51780 POST /api/stop-recording 1.1 200 312 4548329 DEBUG:main:Wrote profile to /profiles/en/profile.json [2019-12-28 09:28:29,026] 192.168.50.59:51796 POST /api/profile 1.1 200 42 43624 INFO:quart.serving:192.168.50.59:51796 POST /api/profile 1.1 200 42 43624 DEBUG:main:Restarting Rhasspy DEBUG:WebSocketObserver:started -> stopped DEBUG:EspeakSentenceSpeaker:ready -> stopped DEBUG:PyAudioRecorder:recording -> stopped DEBUG:PhonetisaurusPronounce:started -> stopped DEBUG:PocketsphinxDecoder:loaded -> stopped DEBUG:DummyIntentHandler:started -> stopped DEBUG:APlayAudioPlayer:started -> stopped DEBUG:FsticuffsIntentTrainer:started -> stopped DEBUG:PocketsphinxSpeechTrainer:started -> stopped DEBUG:SnowboyWakeListener:listening -> stopped DEBUG:DialogueManager:asleep -> stopped DEBUG:FsticuffsRecognizer:loaded -> stopped DEBUG:WebrtcvadCommandListener:loaded -> stopped DEBUG:PyAudioRecorder:Stopped recording from microphone (PyAudio) DEBUG:RhasspyCore:Loaded profile from /profiles/en/profile.json DEBUG:RhasspyCore:Profile files will be written to /profiles/en DEBUG:root:Loading default profile settings from /usr/share/rhasspy/profiles/defaults.json DEBUG:WebSocketObserver: -> started DEBUG:DialogueManager: -> started DEBUG:DialogueManager:started -> loading DEBUG:DialogueManager:Loading actors DEBUG:DialogueManager:Actors created. Waiting for ['recorder', 'player', 'speech', 'wake', 'command', 'decoder', 'recognizer', 'handler', 'speech_trainer', 'intent_trainer', 'word_pronouncer'] to start. DEBUG:PyAudioRecorder: -> started DEBUG:SnowboyWakeListener: -> started DEBUG:APlayAudioPlayer: -> started DEBUG:WebrtcvadCommandListener: -> started DEBUG:EspeakSentenceSpeaker: -> started DEBUG:PocketsphinxDecoder: -> started DEBUG:FsticuffsRecognizer: -> started DEBUG:PocketsphinxSpeechTrainer: -> started DEBUG:DummyIntentHandler: -> started DEBUG:PhonetisaurusPronounce: -> started DEBUG:FsticuffsIntentTrainer: -> started DEBUG:DialogueManager:recorder started DEBUG:SnowboyWakeListener:Loading snowboy model from /profiles/en/snowboy/snowboy.umdl DEBUG:WebrtcvadCommandListener:started -> loaded DEBUG:EspeakSentenceSpeaker:started -> ready DEBUG:PocketsphinxDecoder:Loading decoder with hmm=/profiles/en/acoustic_model, dict=/profiles/en/dictionary.txt, lm=/profiles/en/language_model.txt DEBUG:DialogueManager:player started DEBUG:SnowboyWakeListener:Loaded snowboy model snowboy/snowboy.umdl ({'sensitivity': '0.5', 'audio_gain': 1.0, 'apply_frontend': False}) DEBUG:FsticuffsRecognizer:Using stop words at /usr/share/rhasspy/profiles/en/stop_words.txt DEBUG:SnowboyWakeListener:started -> loaded DEBUG:DialogueManager:handler started DEBUG:DialogueManager:speech_trainer started DEBUG:FsticuffsRecognizer:started -> loaded DEBUG:DialogueManager:word_pronouncer started DEBUG:DialogueManager:intent_trainer started DEBUG:DialogueManager:command started DEBUG:DialogueManager:speech started DEBUG:DialogueManager:wake started DEBUG:DialogueManager:recognizer started DEBUG:PocketsphinxDecoder:started -> loaded DEBUG:DialogueManager:decoder started DEBUG:DialogueManager:Actors loaded DEBUG:DialogueManager:loading -> ready INFO:main:Started INFO:main:Restarted Rhasspy [2019-12-28 09:28:50,736] 192.168.50.59:51796 POST /api/restart 1.1 200 17 20295764 INFO:quart.serving:192.168.50.59:51796 POST /api/restart 1.1 200 17 20295764 ERROR:main:api_events_log Traceback (most recent call last): File "app.py", line 1123, in api_events_log text = await q.get() File "/usr/lib/python3.6/asyncio/queues.py", line 167, in get yield from getter concurrent.futures._base.CancelledError [2019-12-28 09:28:50,975] Error in ASGI Framework Traceback (most recent call last): File "/usr/local/lib/python3.6/dist-packages/hypercorn/asgi/wsproto.py", line 91, in handle_asgi_app await asgi_instance(self.asgi_receive, self.asgi_send) File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 106, in call await _cancel_tasks(pending) File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 189, in _cancel_tasks raise task.exception() File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 157, in handle_websocket 'code': 1000, File "/usr/local/lib/python3.6/dist-packages/hypercorn/asgi/wsproto.py", line 149, in asgi_send await self.asend(CloseConnection(code=int(message["code"]))) File "/usr/local/lib/python3.6/dist-packages/hypercorn/asyncio/wsproto.py", line 93, in asend self.write(self.connection.send(event)) File "/usr/local/lib/python3.6/dist-packages/wsproto/init.py", line 64, in send data += self.connection.send(event) File "/usr/local/lib/python3.6/dist-packages/wsproto/connection.py", line 101, in send "Connection cannot be closed in state %s" % self.state wsproto.utilities.LocalProtocolError: Connection cannot be closed in state ConnectionState.CLOSED ERROR:quart.serving:Error in ASGI Framework Traceback (most recent call last): File "/usr/local/lib/python3.6/dist-packages/hypercorn/asgi/wsproto.py", line 91, in handle_asgi_app await asgi_instance(self.asgi_receive, self.asgi_send) File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 106, in call await _cancel_tasks(pending) File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 189, in _cancel_tasks raise task.exception() File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 157, in handle_websocket 'code': 1000, File "/usr/local/lib/python3.6/dist-packages/hypercorn/asgi/wsproto.py", line 149, in asgi_send await self.asend(CloseConnection(code=int(message["code"]))) File "/usr/local/lib/python3.6/dist-packages/hypercorn/asyncio/wsproto.py", line 93, in asend self.write(self.connection.send(event)) File "/usr/local/lib/python3.6/dist-packages/wsproto/init.py", line 64, in send data += self.connection.send(event) File "/usr/local/lib/python3.6/dist-packages/wsproto/connection.py", line 101, in send "Connection cannot be closed in state %s" % self.state wsproto.utilities.LocalProtocolError: Connection cannot be closed in state ConnectionState.CLOSED [2019-12-28 09:28:50,993] 192.168.50.59:51796 GET / 1.1 200 1029 11783 INFO:quart.serving:192.168.50.59:51796 GET / 1.1 200 1029 11783 [2019-12-28 09:28:51,405] 192.168.50.59:51796 GET /css/bootstrap.min.css 1.1 200 140930 38140 INFO:quart.serving:192.168.50.59:51796 GET /css/bootstrap.min.css 1.1 200 140930 38140 [2019-12-28 09:28:51,491] 192.168.50.59:51797 GET /css/fontawesome-all.min.css 1.1 200 54456 82621 INFO:quart.serving:192.168.50.59:51797 GET /css/fontawesome-all.min.css 1.1 200 54456 82621 [2019-12-28 09:28:51,494] 192.168.50.59:51801 GET /js/jquery-3.3.1.slim.min.js 1.1 200 69917 61584 INFO:quart.serving:192.168.50.59:51801 GET /js/jquery-3.3.1.slim.min.js 1.1 200 69917 61584 [2019-12-28 09:28:51,496] 192.168.50.59:51799 GET /css/app.3074119d.css 1.1 200 309 65131 INFO:quart.serving:192.168.50.59:51799 GET /css/app.3074119d.css 1.1 200 309 65131 [2019-12-28 09:28:51,500] 192.168.50.59:51798 GET /css/main.css 1.1 200 688 90077 INFO:quart.serving:192.168.50.59:51798 GET /css/main.css 1.1 200 688 90077 [2019-12-28 09:28:51,509] 192.168.50.59:51800 GET /js/recorder.js 1.1 200 13027 76318 INFO:quart.serving:192.168.50.59:51800 GET /js/recorder.js 1.1 200 13027 76318 [2019-12-28 09:28:51,725] 192.168.50.59:51800 GET /js/axios.min.js 1.1 200 12941 13242 INFO:quart.serving:192.168.50.59:51800 GET /js/axios.min.js 1.1 200 12941 13242 [2019-12-28 09:28:51,822] 192.168.50.59:51796 GET /js/vue-axios.min.js 1.1 200 673 12754 INFO:quart.serving:192.168.50.59:51796 GET /js/vue-axios.min.js 1.1 200 673 12754 [2019-12-28 09:28:51,930] 192.168.50.59:51798 GET /js/bootstrap.min.js 1.1 200 50731 23054 INFO:quart.serving:192.168.50.59:51798 GET /js/bootstrap.min.js 1.1 200 50731 23054 [2019-12-28 09:28:51,966] 192.168.50.59:51797 GET /js/app.a4422e56.js 1.1 200 148688 16046 INFO:quart.serving:192.168.50.59:51797 GET /js/app.a4422e56.js 1.1 200 148688 16046 [2019-12-28 09:28:53,047] 192.168.50.59:51799 GET /js/chunk-vendors.323824ab.js 1.1 200 279468 1144639 INFO:quart.serving:192.168.50.59:51799 GET /js/chunk-vendors.323824ab.js 1.1 200 279468 1144639 [2019-12-28 09:28:53,380] 192.168.50.59:51799 GET /img/logo.png 1.1 200 1924 32863 INFO:quart.serving:192.168.50.59:51799 GET /img/logo.png 1.1 200 1924 32863 [2019-12-28 09:28:53,388] 192.168.50.59:51802 GET /api/events/log 1.1 101 - 24591 INFO:quart.serving:192.168.50.59:51802 GET /api/events/log 1.1 101 - 24591 DEBUG:main:Loading phoneme examples from /usr/share/rhasspy/profiles/en/phoneme_examples.txt [2019-12-28 09:28:53,492] 192.168.50.59:51799 GET /api/sentences 1.1 200 581 54067 INFO:quart.serving:192.168.50.59:51799 GET /api/sentences 1.1 200 581 54067 [2019-12-28 09:28:53,495] 192.168.50.59:51797 GET /api/slots 1.1 200 2 55443 INFO:quart.serving:192.168.50.59:51797 GET /api/slots 1.1 200 2 55443 [2019-12-28 09:28:53,502] 192.168.50.59:51796 GET /api/phonemes 1.1 200 1526 38754 INFO:quart.serving:192.168.50.59:51796 GET /api/phonemes 1.1 200 1526 38754 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.front ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.rear ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.center_lfe ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.side ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround21 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround21 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround40 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround41 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround50 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround51 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround71 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.iec958 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.iec958 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.iec958 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.hdmi ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.hdmi ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.modem ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.modem ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.phoneline ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.phoneline [2019-12-28 09:28:53,547] 192.168.50.59:51800 GET /api/profile 1.1 200 108 56077 INFO:quart.serving:192.168.50.59:51800 GET /api/profile 1.1 200 108 56077 [2019-12-28 09:28:53,550] 192.168.50.59:51799 GET /api/profile 1.1 200 8633 21584 INFO:quart.serving:192.168.50.59:51799 GET /api/profile 1.1 200 8633 21584 [2019-12-28 09:28:53,617] 192.168.50.59:51797 GET /api/profiles 1.1 200 144 64102 INFO:quart.serving:192.168.50.59:51797 GET /api/profiles 1.1 200 144 64102 [2019-12-28 09:28:53,623] 192.168.50.59:51796 GET /api/version 1.1 200 6 111594 INFO:quart.serving:192.168.50.59:51796 GET /api/version 1.1 200 6 111594 [2019-12-28 09:28:53,626] 192.168.50.59:51801 GET /api/microphones 1.1 200 94 161643 INFO:quart.serving:192.168.50.59:51801 GET /api/microphones 1.1 200 94 161643 [2019-12-28 09:28:53,658] 192.168.50.59:51798 GET /api/speakers 1.1 200 401 192825 INFO:quart.serving:192.168.50.59:51798 GET /api/speakers 1.1 200 401 192825 [2019-12-28 09:28:53,777] 192.168.50.59:51800 GET /api/profile 1.1 200 6781 9416 INFO:quart.serving:192.168.50.59:51800 GET /api/profile 1.1 200 6781 9416 [2019-12-28 09:28:53,828] 192.168.50.59:51800 GET /api/custom-words 1.1 200 19 16467 INFO:quart.serving:192.168.50.59:51800 GET /api/custom-words 1.1 200 19 16467 [2019-12-28 09:28:53,844] 192.168.50.59:51801 GET /api/unknown-words 1.1 200 2 13092 INFO:quart.serving:192.168.50.59:51801 GET /api/unknown-words 1.1 200 2 13092 [2019-12-28 09:28:53,853] 192.168.50.59:51797 GET /api/problems 1.1 200 287 21272 INFO:quart.serving:192.168.50.59:51797 GET /api/problems 1.1 200 287 21272 [2019-12-28 09:28:54,032] 192.168.50.59:51797 GET /img/favicon.png 1.1 200 802 13648 INFO:quart.serving:192.168.50.59:51797 GET /img/favicon.png 1.1 200 802 13648 DEBUG:main:Wrote profile to /profiles/en/profile.json [2019-12-28 09:29:09,323] 192.168.50.59:51803 POST /api/profile 1.1 200 42 29689 INFO:quart.serving:192.168.50.59:51803 POST /api/profile 1.1 200 42 29689 DEBUG:main:Restarting Rhasspy DEBUG:WebSocketObserver:started -> stopped DEBUG:EspeakSentenceSpeaker:ready -> stopped DEBUG:FsticuffsIntentTrainer:started -> stopped DEBUG:PyAudioRecorder:started -> stopped DEBUG:APlayAudioPlayer:started -> stopped DEBUG:WebrtcvadCommandListener:loaded -> stopped DEBUG:PocketsphinxDecoder:loaded -> stopped DEBUG:DummyIntentHandler:started -> stopped DEBUG:FsticuffsRecognizer:loaded -> stopped DEBUG:PocketsphinxSpeechTrainer:started -> stopped DEBUG:PhonetisaurusPronounce:started -> stopped DEBUG:SnowboyWakeListener:loaded -> stopped DEBUG:DialogueManager:ready -> stopped DEBUG:RhasspyCore:Loaded profile from /profiles/en/profile.json DEBUG:RhasspyCore:Profile files will be written to /profiles/en DEBUG:root:Loading default profile settings from /usr/share/rhasspy/profiles/defaults.json DEBUG:WebSocketObserver: -> started DEBUG:DialogueManager: -> started DEBUG:DialogueManager:started -> loading DEBUG:DialogueManager:Loading actors DEBUG:DialogueManager:Actors created. Waiting for ['recorder', 'player', 'speech', 'wake', 'command', 'decoder', 'recognizer', 'handler', 'speech_trainer', 'intent_trainer', 'word_pronouncer'] to start. DEBUG:EspeakSentenceSpeaker: -> started DEBUG:EspeakSentenceSpeaker:started -> ready DEBUG:SnowboyWakeListener: -> started DEBUG:APlayAudioPlayer: -> started DEBUG:WebrtcvadCommandListener: -> started DEBUG:PocketsphinxDecoder: -> started DEBUG:DummyIntentHandler: -> started DEBUG:FsticuffsRecognizer: -> started DEBUG:FsticuffsIntentTrainer: -> started DEBUG:DialogueManager:speech started DEBUG:PyAudioRecorder: -> started DEBUG:PhonetisaurusPronounce: -> started DEBUG:SnowboyWakeListener:Loading snowboy model from /profiles/en/snowboy/snowboy.umdl DEBUG:WebrtcvadCommandListener:started -> loaded DEBUG:PocketsphinxDecoder:Loading decoder with hmm=/profiles/en/acoustic_model, dict=/profiles/en/dictionary.txt, lm=/profiles/en/language_model.txt DEBUG:PocketsphinxSpeechTrainer: -> started DEBUG:DialogueManager:player started DEBUG:SnowboyWakeListener:Loaded snowboy model snowboy/snowboy.umdl ({'sensitivity': '0.5', 'audio_gain': 1.0, 'apply_frontend': False}) DEBUG:DialogueManager:handler started DEBUG:DialogueManager:recorder started DEBUG:DialogueManager:intent_trainer started DEBUG:DialogueManager:word_pronouncer started DEBUG:DialogueManager:command started DEBUG:DialogueManager:speech_trainer started DEBUG:SnowboyWakeListener:started -> loaded DEBUG:FsticuffsRecognizer:Using stop words at /usr/share/rhasspy/profiles/en/stop_words.txt DEBUG:DialogueManager:wake started DEBUG:FsticuffsRecognizer:started -> loaded DEBUG:DialogueManager:recognizer started DEBUG:PocketsphinxDecoder:started -> loaded DEBUG:DialogueManager:decoder started DEBUG:DialogueManager:Actors loaded DEBUG:DialogueManager:loading -> ready INFO:DialogueManager:Automatically listening for wake word DEBUG:DialogueManager:ready -> asleep DEBUG:SnowboyWakeListener:loaded -> listening DEBUG:PyAudioRecorder:started -> recording INFO:main:Started INFO:main:Restarted Rhasspy [2019-12-28 09:29:31,410] 192.168.50.59:51803 POST /api/restart 1.1 200 17 20122125 INFO:quart.serving:192.168.50.59:51803 POST /api/restart 1.1 200 17 20122125 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.front ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.rear ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.center_lfe ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.side ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround21 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround21 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround40 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround41 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround50 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround51 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround71 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.iec958 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.iec958 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.iec958 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.hdmi ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.hdmi ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.modem ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.modem ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.phoneline ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.phoneline DEBUG:PyAudioRecorder:Recording from microphone (PyAudio, device=None) ERROR:main:api_events_log Traceback (most recent call last): File "app.py", line 1123, in api_events_log text = await q.get() File "/usr/lib/python3.6/asyncio/queues.py", line 167, in get yield from getter concurrent.futures._base.CancelledError [2019-12-28 09:29:31,672] Error in ASGI Framework Traceback (most recent call last): File "/usr/local/lib/python3.6/dist-packages/hypercorn/asgi/wsproto.py", line 91, in handle_asgi_app await asgi_instance(self.asgi_receive, self.asgi_send) File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 106, in call await _cancel_tasks(pending) File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 189, in _cancel_tasks raise task.exception() File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 157, in handle_websocket 'code': 1000, File "/usr/local/lib/python3.6/dist-packages/hypercorn/asgi/wsproto.py", line 149, in asgi_send await self.asend(CloseConnection(code=int(message["code"]))) File "/usr/local/lib/python3.6/dist-packages/hypercorn/asyncio/wsproto.py", line 93, in asend self.write(self.connection.send(event)) File "/usr/local/lib/python3.6/dist-packages/wsproto/init.py", line 64, in send ERROR:quart.serving:Error in ASGI Framework data += self.connection.send(event) File "/usr/local/lib/python3.6/dist-packages/wsproto/connection.py", line 101, in send "Connection cannot be closed in state %s" % self.state Traceback (most recent call last): File "/usr/local/lib/python3.6/dist-packages/hypercorn/asgi/wsproto.py", line 91, in handle_asgi_app await asgi_instance(self.asgi_receive, self.asgi_send) File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 106, in call await _cancel_tasks(pending) File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 189, in _cancel_tasks raise task.exception() wsproto.utilities.LocalProtocolError: Connection cannot be closed in state ConnectionState.CLOSED File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 157, in handle_websocket 'code': 1000, File "/usr/local/lib/python3.6/dist-packages/hypercorn/asgi/wsproto.py", line 149, in asgi_send await self.asend(CloseConnection(code=int(message["code"]))) File "/usr/local/lib/python3.6/dist-packages/hypercorn/asyncio/wsproto.py", line 93, in asend self.write(self.connection.send(event)) File "/usr/local/lib/python3.6/dist-packages/wsproto/init.py", line 64, in send data += self.connection.send(event) File "/usr/local/lib/python3.6/dist-packages/wsproto/connection.py", line 101, in send "Connection cannot be closed in state %s" % self.state wsproto.utilities.LocalProtocolError: Connection cannot be closed in state ConnectionState.CLOSED [2019-12-28 09:29:31,685] 192.168.50.59:51803 GET / 1.1 200 1029 24245 INFO:quart.serving:192.168.50.59:51803 GET / 1.1 200 1029 24245 [2019-12-28 09:29:31,794] 192.168.50.59:51803 GET /css/bootstrap.min.css 1.1 200 140930 19522 INFO:quart.serving:192.168.50.59:51803 GET /css/bootstrap.min.css 1.1 200 140930 19522 [2019-12-28 09:29:31,862] 192.168.50.59:51805 GET /css/main.css 1.1 200 688 54501 INFO:quart.serving:192.168.50.59:51805 GET /css/main.css 1.1 200 688 54501 [2019-12-28 09:29:31,864] 192.168.50.59:51804 GET /css/fontawesome-all.min.css 1.1 200 54456 55096 INFO:quart.serving:192.168.50.59:51804 GET /css/fontawesome-all.min.css 1.1 200 54456 55096 [2019-12-28 09:29:31,879] 192.168.50.59:51806 GET /css/app.3074119d.css 1.1 200 309 68899 INFO:quart.serving:192.168.50.59:51806 GET /css/app.3074119d.css 1.1 200 309 68899 [2019-12-28 09:29:31,883] 192.168.50.59:51807 GET /js/recorder.js 1.1 200 13027 74859 INFO:quart.serving:192.168.50.59:51807 GET /js/recorder.js 1.1 200 13027 74859 [2019-12-28 09:29:31,885] 192.168.50.59:51808 GET /js/jquery-3.3.1.slim.min.js 1.1 200 69917 76650 INFO:quart.serving:192.168.50.59:51808 GET /js/jquery-3.3.1.slim.min.js 1.1 200 69917 76650 [2019-12-28 09:29:32,023] 192.168.50.59:51807 GET /js/axios.min.js 1.1 200 12941 21577 INFO:quart.serving:192.168.50.59:51807 GET /js/axios.min.js 1.1 200 12941 21577 [2019-12-28 09:29:32,057] 192.168.50.59:51805 GET /js/vue-axios.min.js 1.1 200 673 20495 INFO:quart.serving:192.168.50.59:51805 GET /js/vue-axios.min.js 1.1 200 673 20495 [2019-12-28 09:29:32,206] 192.168.50.59:51806 GET /js/bootstrap.min.js 1.1 200 50731 14965 INFO:quart.serving:192.168.50.59:51806 GET /js/bootstrap.min.js 1.1 200 50731 14965 [2019-12-28 09:29:32,742] 192.168.50.59:51807 GET /js/app.a4422e56.js 1.1 200 148688 15180 INFO:quart.serving:192.168.50.59:51807 GET /js/app.a4422e56.js 1.1 200 148688 15180 [2019-12-28 09:29:32,787] 192.168.50.59:51804 GET /js/chunk-vendors.323824ab.js 1.1 200 279468 161868 INFO:quart.serving:192.168.50.59:51804 GET /js/chunk-vendors.323824ab.js 1.1 200 279468 161868 [2019-12-28 09:29:35,241] 192.168.50.59:51804 GET /img/logo.png 1.1 200 1924 35531 INFO:quart.serving:192.168.50.59:51804 GET /img/logo.png 1.1 200 1924 35531 INFO:quart.serving:192.168.50.59:51809 GET /api/events/log 1.1 101 - 28515 [2019-12-28 09:29:35,250] 192.168.50.59:51809 GET /api/events/log 1.1 101 - 28515 [2019-12-28 09:29:35,313] 192.168.50.59:51804 GET /api/sentences 1.1 200 581 25729 INFO:quart.serving:192.168.50.59:51804 GET /api/sentences 1.1 200 581 25729 DEBUG:main:Loading phoneme examples from /usr/share/rhasspy/profiles/en/phoneme_examples.txt [2019-12-28 09:29:35,390] 192.168.50.59:51807 GET /api/slots 1.1 200 2 72736 INFO:quart.serving:192.168.50.59:51807 GET /api/slots 1.1 200 2 72736 [2019-12-28 09:29:35,398] 192.168.50.59:51803 GET /api/phonemes 1.1 200 1526 81406 INFO:quart.serving:192.168.50.59:51803 GET /api/phonemes 1.1 200 1526 81406 [2019-12-28 09:29:35,435] 192.168.50.59:51808 GET /api/microphones 1.1 200 94 117884 INFO:quart.serving:192.168.50.59:51808 GET /api/microphones 1.1 200 94 117884 [2019-12-28 09:29:35,446] 192.168.50.59:51804 GET /api/profile 1.1 200 8632 32524 INFO:quart.serving:192.168.50.59:51804 GET /api/profile 1.1 200 8632 32524 [2019-12-28 09:29:35,480] 192.168.50.59:51807 GET /api/profiles 1.1 200 144 42219 INFO:quart.serving:192.168.50.59:51807 GET /api/profiles 1.1 200 144 42219 [2019-12-28 09:29:35,487] 192.168.50.59:51805 GET /api/profile 1.1 200 51 169030 INFO:quart.serving:192.168.50.59:51805 GET /api/profile 1.1 200 51 169030 [2019-12-28 09:29:35,491] 192.168.50.59:51806 GET /api/speakers 1.1 200 401 173713 INFO:quart.serving:192.168.50.59:51806 GET /api/speakers 1.1 200 401 173713 [2019-12-28 09:29:35,515] 192.168.50.59:51804 GET /api/profile 1.1 200 6781 21844 INFO:quart.serving:192.168.50.59:51804 GET /api/profile 1.1 200 6781 21844 [2019-12-28 09:29:35,525] 192.168.50.59:51803 GET /api/version 1.1 200 6 91372 INFO:quart.serving:192.168.50.59:51803 GET /api/version 1.1 200 6 91372 [2019-12-28 09:29:35,541] 192.168.50.59:51808 GET /api/custom-words 1.1 200 19 32664 INFO:quart.serving:192.168.50.59:51808 GET /api/custom-words 1.1 200 19 32664 [2019-12-28 09:29:35,557] 192.168.50.59:51807 GET /api/unknown-words 1.1 200 2 13217 INFO:quart.serving:192.168.50.59:51807 GET /api/unknown-words 1.1 200 2 13217 INFO:quart.serving:192.168.50.59:51804 GET /api/problems 1.1 200 287 23356 [2019-12-28 09:29:35,568] 192.168.50.59:51804 GET /api/problems 1.1 200 287 23356 [2019-12-28 09:29:35,657] 192.168.50.59:51804 GET /img/favicon.png 1.1 200 802 13306 INFO:quart.serving:192.168.50.59:51804 GET /img/favicon.png 1.1 200 802 13306 DEBUG:DialogueManager:asleep -> awake DEBUG:SnowboyWakeListener:listening -> loaded DEBUG:WebrtcvadCommandListener:Will timeout in 30 second(s) DEBUG:WebrtcvadCommandListener:loaded -> listening DEBUG:APlayAudioPlayer:['aplay', '-q', '/usr/share/rhasspy/etc/wav/beep_hi.wav'] DEBUG:WebrtcvadCommandListener:Voice command started DEBUG:WebrtcvadCommandListener:Voice command finished DEBUG:WebrtcvadCommandListener:listening -> loaded DEBUG:DialogueManager:awake -> decoding DEBUG:PocketsphinxDecoder:rate=16000, width=2, channels=1. DEBUG:APlayAudioPlayer:['aplay', '-q', '/usr/share/rhasspy/etc/wav/beep_lo.wav'] DEBUG:PocketsphinxDecoder:Decoded WAV in 5.3203794956207275 second(s) DEBUG:PocketsphinxDecoder:Transcription confidence: 0.001528525835989543 DEBUG:PocketsphinxDecoder:the blue DEBUG:DialogueManager:the blue (confidence=0.001528525835989543) DEBUG:DialogueManager:decoding -> recognizing ERROR:FsticuffsRecognizer:in_loaded Traceback (most recent call last): File "/usr/share/rhasspy/rhasspy/intent.py", line 179, in in_loaded assert recognitions, "No intent recognized" AssertionError: No intent recognized DEBUG:DialogueManager:{'text': 'the blue', 'intent': {'name': '', 'confidence': 0}, 'entities': [], 'raw_text': 'the blue', 'speech_confidence': 0.001528525835989543, 'wakeId': '', 'siteId': 'default'} DEBUG:APlayAudioPlayer:['aplay', '-q', '/usr/share/rhasspy/etc/wav/beep_error.wav'] DEBUG:DialogueManager:recognizing -> handling DEBUG:WebSocketObserver:{"text": "the blue", "intent": {"name": "", "confidence": 0}, "entities": [], "raw_text": "the blue", "speech_confidence": 0.001528525835989543, "wakeId": "", "siteId": "default", "slots": {}} DEBUG:DialogueManager:handling -> ready INFO:DialogueManager:Automatically listening for wake word DEBUG:DialogueManager:ready -> asleep DEBUG:SnowboyWakeListener:loaded -> listening INFO:quart.serving:192.168.50.59:51810 POST /api/listen-for-command 1.1 200 174 7641820 [2019-12-28 09:29:55,950] 192.168.50.59:51810 POST /api/listen-for-command 1.1 200 174 7641820 DEBUG:DialogueManager:asleep -> awake DEBUG:APlayAudioPlayer:['aplay', '-q', '/usr/share/rhasspy/etc/wav/beep_hi.wav'] DEBUG:SnowboyWakeListener:listening -> loaded DEBUG:WebrtcvadCommandListener:Will timeout in 30 second(s) DEBUG:WebrtcvadCommandListener:loaded -> listening DEBUG:WebrtcvadCommandListener:Voice command started DEBUG:WebrtcvadCommandListener:Voice command finished DEBUG:WebrtcvadCommandListener:listening -> loaded DEBUG:DialogueManager:awake -> decoding DEBUG:PocketsphinxDecoder:rate=16000, width=2, channels=1. DEBUG:APlayAudioPlayer:['aplay', '-q', '/usr/share/rhasspy/etc/wav/beep_lo.wav'] DEBUG:PocketsphinxDecoder:Decoded WAV in 5.749267101287842 second(s) DEBUG:PocketsphinxDecoder:Transcription confidence: 0.006328532961257632 DEBUG:PocketsphinxDecoder:what time is it DEBUG:DialogueManager:what time is it (confidence=0.006328532961257632) DEBUG:DialogueManager:decoding -> recognizing DEBUG:DialogueManager:{'intent': {'name': 'GetTime', 'confidence': 1.0}, 'entities': [], 'text': 'what time is it', 'raw_text': 'what time is it', 'recognize_seconds': 0.0021813610001117922, 'tokens': ['what', 'time', 'is', 'it'], 'raw_tokens': ['what', 'time', 'is', 'it'], 'speech_confidence': 0.006328532961257632, 'wakeId': '', 'siteId': 'default'} DEBUG:DialogueManager:recognizing -> handling DEBUG:WebSocketObserver:{"intent": {"name": "GetTime", "confidence": 1.0}, "entities": [], "text": "what time is it", "raw_text": "what time is it", "recognize_seconds": 0.0021813610001117922, "tokens": ["what", "time", "is", "it"], "raw_tokens": ["what", "time", "is", "it"], "speech_confidence": 0.006328532961257632, "wakeId": "", "siteId": "default", "slots": {}} DEBUG:DialogueManager:handling -> ready INFO:DialogueManager:Automatically listening for wake word DEBUG:DialogueManager:ready -> asleep DEBUG:SnowboyWakeListener:loaded -> listening [2019-12-28 09:30:12,167] 192.168.50.59:51811 POST /api/listen-for-command 1.1 200 313 8208261 INFO:quart.serving:192.168.50.59:51811 POST /api/listen-for-command 1.1 200 313 8208261

adrianofoschi commented 4 years ago

Hi @adrianofoschi Do you use the last version? Looks like your issue is similar to this #90 Could you check your docker logs? Also try to select different device in microphone section

Is there a script to update ti latest version? How to check the docker logs? Thanks you

andyinno commented 4 years ago

you can use

docker container ls
docker logs yourcontainername

for getting the logs.

An alternative, I run in this way the docker container:

apt install docker-compose

create a file docker-compose.yml

rhasspy:
image: "synesthesiam/rhasspy-server:latest"
restart: unless-stopped
volumes:
    - "profiles:/profiles"
ports:
    - "12101:12101"
devices:
    - "/dev/snd:/dev/snd"
command: --user-profiles /profiles --profile it

and then you can use: docker-compose up to have it running in the terminal, and docker-compose up -d to send it to the background. Updating is also simple: docker-compose pull will fetch any new version of the container and then docker-compose up will run it again.

@frkos I also have some error in the logs, they do not looks related to snowboy

ERROR:main:api_events_log` Traceback (most recent call last): File "app.py", line 1139, in api_events_log text = await q.get() File "/usr/lib/python3.6/asyncio/queues.py", line 167, in get yield from getter concurrent.futures._base.CancelledError ERROR:quart.serving:Error in ASGI Framework Traceback (most recent call last): File "/usr/local/lib/python3.6/dist-packages/hypercorn/asgi/wsproto.py", line 91, in handle_asgi_app await asgi_instance(self.asgi_receive, self.asgi_send) File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 106, in call await _cancel_tasks(pending) File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 189, in _cancel_tasks raise task.exception() [2019-12-27 23:22:24,349] Error in ASGI Framework Traceback (most recent call last): File "/usr/local/lib/python3.6/dist-packages/hypercorn/asgi/wsproto.py", line 91, in handle_asgi_app await asgi_instance(self.asgi_receive, self.asgi_send) File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 106, in call File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 157, in handle_websocket 'code': 1000, File "/usr/local/lib/python3.6/dist-packages/hypercorn/asgi/wsproto.py", line 149, in asgi_send await self.asend(CloseConnection(code=int(message["code"]))) File "/usr/local/lib/python3.6/dist-packages/hypercorn/asyncio/wsproto.py", line 93, in asend self.write(self.connection.send(event)) File "/usr/local/lib/python3.6/dist-packages/wsproto/init.py", line 64, in send data += self.connection.send(event) File "/usr/local/lib/python3.6/dist-packages/wsproto/connection.py", line 101, in send "Connection cannot be closed in state %s" % self.state wsproto.utilities.LocalProtocolError: Connection cannot be closed in state ConnectionState.CLOSED await _cancel_tasks(pending) File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 189, in _cancel_tasks raise task.exception() File "/usr/local/lib/python3.6/dist-packages/quart/asgi.py", line 157, in handle_websocket 'code': 1000, File "/usr/local/lib/python3.6/dist-packages/hypercorn/asgi/wsproto.py", line 149, in asgi_send await self.asend(CloseConnection(code=int(message["code"]))) File "/usr/local/lib/python3.6/dist-packages/hypercorn/asyncio/wsproto.py", line 93, in asend self.write(self.connection.send(event)) File "/usr/local/lib/python3.6/dist-packages/wsproto/init.py", line 64, in send data += self.connection.send(event) File "/usr/local/lib/python3.6/dist-packages/wsproto/connection.py", line 101, in send "Connection cannot be closed in state %s" % self.state wsproto.utilities.LocalProtocolError: Connection cannot be closed in state ConnectionState.CLOSED DEBUG:main:Namespace(host='0.0.0.0', log_level='DEBUG', port=12101, profile='it', set=[], ssl=None, system_profiles='/usr/share/rhasspy/profiles', user_profiles='/profiles') WARNING:quart.serving:ASGI Framework Lifespan error, continuing without Lifespan support Expression 'alsa_snd_pcm_hw_params_set_period_size_near( pcm, hwParams, &alsaPeriodFrames, &dir )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 924 Expression 'alsa_snd_pcm_hw_params_set_period_size_near( pcm, hwParams, &alsaPeriodFrames, &dir )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 924 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.front ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.rear ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.center_lfe ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.side ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround21 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround21 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround40 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround41 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround50 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround51 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround71 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.iec958 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.iec958 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.iec958 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.hdmi ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.hdmi ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.modem ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.modem ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.phoneline ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.phoneline Expression 'alsa_snd_pcm_hw_params_set_period_size_near( pcm, hwParams, &alsaPeriodFrames, &dir )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 924 DEBUG:PyAudioRecorder:Recording from microphone (PyAudio, device=2)

adrianofoschi commented 4 years ago

Thanks you, I solved with:

  1. Updating by docker-compose pull
  2. disable rpi builtin audio
andyinno commented 4 years ago

@adrianofoschi can you detail the steps that you performed for 2?

thank you

andyinno commented 4 years ago

I tried to docker-compose pull after the update. It's still not working. Here attached a fresh log that I got after updating

rhasspy_1 | DEBUG:main:Namespace(host='0.0.0.0', log_level='DEBUG', port=12101, profile='it', set=[], ssl=None, system_profiles='/usr/share/rhasspy/profiles', user_profiles='/profiles') rhasspy_1 | DEBUG:RhasspyCore:Loaded profile from /profiles/it/profile.json rhasspy_1 | DEBUG:RhasspyCore:Profile files will be written to /profiles/it rhasspy_1 | DEBUG:root:Loading default profile settings from /usr/share/rhasspy/profiles/defaults.json rhasspy_1 | DEBUG:WebSocketObserver: -> started rhasspy_1 | DEBUG:DialogueManager: -> started rhasspy_1 | DEBUG:DialogueManager:started -> loading rhasspy_1 | DEBUG:DialogueManager:Loading actors rhasspy_1 | DEBUG:DialogueManager:Actors created. Waiting for ['recorder', 'player', 'speech', 'wake', 'command', 'decoder', 'recognizer', 'handler', 'speech_trainer', 'intent_trainer', 'word_pronouncer'] to start. rhasspy_1 | DEBUG:PyAudioRecorder: -> started rhasspy_1 | DEBUG:APlayAudioPlayer: -> started rhasspy_1 | DEBUG:EspeakSentenceSpeaker: -> started rhasspy_1 | DEBUG:SnowboyWakeListener: -> started rhasspy_1 | DEBUG:PhonetisaurusPronounce: -> started rhasspy_1 | DEBUG:WebrtcvadCommandListener: -> started rhasspy_1 | DEBUG:PocketsphinxDecoder: -> started rhasspy_1 | DEBUG:DummyIntentHandler: -> started rhasspy_1 | DEBUG:PocketsphinxSpeechTrainer: -> started rhasspy_1 | DEBUG:FsticuffsIntentTrainer: -> started rhasspy_1 | DEBUG:FsticuffsRecognizer: -> started rhasspy_1 | DEBUG:DialogueManager:recorder started rhasspy_1 | DEBUG:EspeakSentenceSpeaker:started -> ready rhasspy_1 | DEBUG:WebrtcvadCommandListener:started -> loaded rhasspy_1 | DEBUG:DialogueManager:player started rhasspy_1 | DEBUG:DialogueManager:word_pronouncer started rhasspy_1 | DEBUG:DialogueManager:handler started rhasspy_1 | DEBUG:FsticuffsRecognizer:Using stop words at /usr/share/rhasspy/profiles/it/stop_words.txt rhasspy_1 | DEBUG:DialogueManager:speech_trainer started rhasspy_1 | DEBUG:DialogueManager:intent_trainer started rhasspy_1 | DEBUG:DialogueManager:command started rhasspy_1 | DEBUG:DialogueManager:speech started rhasspy_1 | DEBUG:FsticuffsRecognizer:started -> loaded rhasspy_1 | DEBUG:DialogueManager:recognizer started rhasspy_1 | DEBUG:SnowboyWakeListener:Loading snowboy model from /profiles/it/snowboy/snowboy.umdl rhasspy_1 | DEBUG:SnowboyWakeListener:Loaded snowboy model snowboy/snowboy.umdl ({'sensitivity': '0.5', 'audio_gain': 1.0, 'apply_frontend': False}) rhasspy_1 | DEBUG:PocketsphinxDecoder:Loading decoder with hmm=/profiles/it/acoustic_model, dict=/profiles/it/dictionary.txt, lm=/profiles/it/language_model.txt rhasspy_1 | DEBUG:SnowboyWakeListener:started -> loaded rhasspy_1 | DEBUG:DialogueManager:wake started rhasspy_1 | DEBUG:PocketsphinxDecoder:started -> loaded rhasspy_1 | DEBUG:DialogueManager:decoder started rhasspy_1 | DEBUG:DialogueManager:Actors loaded rhasspy_1 | DEBUG:DialogueManager:loading -> ready rhasspy_1 | INFO:DialogueManager:Automatically listening for wake word rhasspy_1 | DEBUG:DialogueManager:ready -> asleep rhasspy_1 | DEBUG:SnowboyWakeListener:loaded -> listening rhasspy_1 | INFO:main:Started rhasspy_1 | DEBUG:PyAudioRecorder:started -> recording rhasspy_1 | DEBUG:main:Starting web server at http://0.0.0.0:12101 rhasspy_1 | Running on https://0.0.0.0:12101 (CTRL + C to quit) rhasspy_1 | [2019-12-28 17:55:46,505] ASGI Framework Lifespan error, continuing without Lifespan support rhasspy_1 | WARNING:quart.serving:ASGI Framework Lifespan error, continuing without Lifespan support rhasspy_1 | Expression 'alsa_snd_pcm_hw_params_set_period_size_near( pcm, hwParams, &alsaPeriodFrames, &dir )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 924 rhasspy_1 | Expression 'alsa_snd_pcm_hw_params_set_period_size_near( pcm, hwParams, &alsaPeriodFrames, &dir )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 924 rhasspy_1 | ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.front rhasspy_1 | ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.rear rhasspy_1 | ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.center_lfe rhasspy_1 | ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.side rhasspy_1 | ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround21 rhasspy_1 | ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround21 rhasspy_1 | ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround40 rhasspy_1 | ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround41 rhasspy_1 | ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround50 rhasspy_1 | ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround51 rhasspy_1 | ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.surround71 rhasspy_1 | ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.iec958 rhasspy_1 | ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.iec958 rhasspy_1 | ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.iec958 rhasspy_1 | ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.hdmi rhasspy_1 | ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.hdmi rhasspy_1 | ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.modem rhasspy_1 | ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.modem rhasspy_1 | ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.phoneline rhasspy_1 | ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.phoneline rhasspy_1 | Expression 'alsa_snd_pcm_hw_params_set_period_size_near( pcm, hwParams, &alsaPeriodFrames, &dir )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 924 rhasspy_1 | DEBUG:PyAudioRecorder:Recording from microphone (PyAudio, device=2)

Pressing the wake button on the web interface I can get the sentense in the logs:

rhasspy_1 | DEBUG:DialogueManager:asleep -> awake rhasspy_1 | DEBUG:SnowboyWakeListener:listening -> loaded rhasspy_1 | DEBUG:WebrtcvadCommandListener:Will timeout in 30 second(s) rhasspy_1 | DEBUG:APlayAudioPlayer:['aplay', '-q', '-D', 'default:CARD=seeed2micvoicec', '/usr/share/rhasspy/etc/wav/beep_hi.wav'] rhasspy_1 | DEBUG:WebrtcvadCommandListener:loaded -> listening rhasspy_1 | DEBUG:WebrtcvadCommandListener:Voice command started rhasspy_1 | DEBUG:WebrtcvadCommandListener:Voice command finished rhasspy_1 | DEBUG:WebrtcvadCommandListener:listening -> loaded rhasspy_1 | DEBUG:DialogueManager:awake -> decoding rhasspy_1 | DEBUG:PocketsphinxDecoder:rate=16000, width=2, channels=1. rhasspy_1 | DEBUG:APlayAudioPlayer:['aplay', '-q', '-D', 'default:CARD=seeed2micvoicec', '/usr/share/rhasspy/etc/wav/beep_lo.wav'] rhasspy_1 | DEBUG:PocketsphinxDecoder:Decoded WAV in 0.5372183322906494 second(s) rhasspy_1 | DEBUG:PocketsphinxDecoder:Transcription confidence: 0.380407576637821 rhasspy_1 | DEBUG:PocketsphinxDecoder:che ore sono rhasspy_1 | DEBUG:DialogueManager:che ore sono (confidence=0.380407576637821) rhasspy_1 | DEBUG:DialogueManager:decoding -> recognizing rhasspy_1 | DEBUG:DialogueManager:{'intent': {'name': 'GetTime', 'confidence': 1.0}, 'entities': [], 'text': 'che ore sono', 'raw_text': 'che ore sono', 'recognize_seconds': 0.001060996999967756, 'tokens': ['che', 'ore', 'sono'], 'raw_tokens': ['che', 'ore', 'sono'], 'speech_confidence': 0.380407576637821, 'wakeId': '', 'siteId': 'default'} rhasspy_1 | DEBUG:DialogueManager:recognizing -> handling rhasspy_1 | DEBUG:WebSocketObserver:{"intent": {"name": "GetTime", "confidence": 1.0}, "entities": [], "text": "che ore sono", "raw_text": "che ore sono", "recognize_seconds": 0.001060996999967756, "tokens": ["che", "ore", "sono"], "raw_tokens": ["che", "ore", "sono"], "speech_confidence": 0.380407576637821, "wakeId": "", "siteId": "default", "slots": {}} rhasspy_1 | DEBUG:DialogueManager:handling -> ready rhasspy_1 | INFO:DialogueManager:Automatically listening for wake word rhasspy_1 | DEBUG:DialogueManager:ready -> asleep rhasspy_1 | DEBUG:SnowboyWakeListener:loaded -> listening rhasspy_1 | [2019-12-28 18:00:25,070] 192.168.43.208:39712 POST /api/listen-for-command 1.1 200 293 2935103 rhasspy_1 | INFO:quart.serving:192.168.43.208:39712 POST /api/listen-for-command 1.1 200 293 2935103

adrianofoschi commented 4 years ago

@adrianofoschi can you detail the steps that you performed for 2?

thank you

Look there https://github.com/synesthesiam/rhasspy/issues/90#issuecomment-568614012

matthias-matze commented 4 years ago

Hy,

For me the issue is still there.

I completly reinstalled a fesh Raspian strech, docker, docker compose. Created a docker-compose.yml file and launched it.

Disabled the audio editing the /boot/config.txt as suggested.

My Raspiaudio MIC+ is working when i test it outside of Rhasspy, Rhasspy is working when i use the Wake Button of the web interface.

Only the wake word isn’t working. (Snowboy or pocketsphinx).

Each time i change the wake word setting i re-train .

Still no luck.

Matthias

De : Adriano Foschi notifications@github.com Envoyé : dimanche 29 décembre 2019 01:38 À : synesthesiam/rhasspy rhasspy@noreply.github.com Cc : matthias-matze matthias@matze.fr; Mention mention@noreply.github.com Objet : Re: [synesthesiam/rhasspy] Wake Word detection not working (#117)

@adrianofoschi https://github.com/adrianofoschi can you detail the steps that you performed for 2?

thank you

Look there #90 (comment) https://github.com/synesthesiam/rhasspy/issues/90#issuecomment-568614012

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/synesthesiam/rhasspy/issues/117?email_source=notifications&email_token=AFQ6DUU33BJDIJNSLWNARGDQ27WO7A5CNFSM4J7F42PKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEHYVCBA#issuecomment-569463044 , or unsubscribe https://github.com/notifications/unsubscribe-auth/AFQ6DURP26U76MBQJPIUEXDQ27WO7ANCNFSM4J7F42PA . https://github.com/notifications/beacon/AFQ6DUSNELPDK22VIXDNGXTQ27WO7A5CNFSM4J7F42PKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEHYVCBA.gif

frkos commented 4 years ago

@matthias-matze If you run arecord from docker, do you hear your speech well?

Please test your mic like this: To record wav file run: sudo docker exec 3ade54edfea0 arecord -d 5 -r 16000 /tmp/test.wav To play wav file: sudo docker exec 3ade54edfea0 aplay /tmp/test.wav

matthias-matze commented 4 years ago

Hi again,

Here is the error while launching your test command :

arecord: main:788: audio open error: Device or resource busy

Matthias

De : frkos notifications@github.com Envoyé : dimanche 29 décembre 2019 12:37 À : synesthesiam/rhasspy rhasspy@noreply.github.com Cc : matthias-matze matthias@matze.fr; Mention mention@noreply.github.com Objet : Re: [synesthesiam/rhasspy] Wake Word detection not working (#117)

@matthias-matze https://github.com/matthias-matze If you run arecord from docker, do you hear your speech well?

Please test your mic like this: To record wav file run: sudo docker exec 3ade54edfea0 arecord -d 5 -r 16000 /tmp/test.wav To play wav file: sudo docker exec 3ade54edfea0 aplay /tmp/test.wav

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/synesthesiam/rhasspy/issues/117?email_source=notifications&email_token=AFQ6DUWGRS2KXTX7U3NTXJ3Q3CDV7A5CNFSM4J7F42PKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEHY5NGI#issuecomment-569497241 , or unsubscribe https://github.com/notifications/unsubscribe-auth/AFQ6DUWGP2QDD4OXTG4XYELQ3CDV7ANCNFSM4J7F42PA . https://github.com/notifications/beacon/AFQ6DUQMTGGT7UU6SPAKC73Q3CDV7A5CNFSM4J7F42PKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEHY5NGI.gif

frkos commented 4 years ago

Yes, you should stop rhasspy listening to the wake word... The rootcause of the problem may be volume or other issues with you mic So test it. Also you can try to increase sensitivity for snowboy I have this in my profile

   "wake": {
        "snowboy": {
            "audio_gain": "1.5",
            "sensitivity": "0.8"
        },
matthias-matze commented 4 years ago

Hy,

Thanks for the tip ! Problem resolved :

I have to set the following values to resolve my issue :

"wake": {

    "snowboy": {

        "audio_gain": "2.6",

        "sensitivity": "1"

    },

Matthias

De : frkos notifications@github.com Envoyé : dimanche 29 décembre 2019 21:43 À : synesthesiam/rhasspy rhasspy@noreply.github.com Cc : matthias-matze matthias@matze.fr; Mention mention@noreply.github.com Objet : Re: [synesthesiam/rhasspy] Wake Word detection not working (#117)

Yes, you should stop the rasspy listening to the wake word... The rootcause of the problem may be volume or other issues with you mic So test it. Also you can try to increase sensitivity for snowboy I have this in my profile

"wake": { "snowboy": { "audio_gain": "1.5", "sensitivity": "0.8" },

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/synesthesiam/rhasspy/issues/117?email_source=notifications&email_token=AFQ6DUS7ZPL4TXQSMXW4WXTQ3EDVHA5CNFSM4J7F42PKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEHZH53Q#issuecomment-569540334 , or unsubscribe https://github.com/notifications/unsubscribe-auth/AFQ6DUUQVIKZM3YKANFNFSTQ3EDVHANCNFSM4J7F42PA . https://github.com/notifications/beacon/AFQ6DUXJVU7QLHUNZBEST33Q3EDVHA5CNFSM4J7F42PKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEHZH53Q.gif