Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Recognizer becomes weird after cancellation #123

Closed
alexanderkoller opened this issue Nov 21, 2018 · 9 comments
Closed

Recognizer becomes weird after cancellation #123

alexanderkoller opened this issue Nov 21, 2018 · 9 comments

Comments

@alexanderkoller
Copy link
Contributor

Sometimes, I observe the following behavior:

  1. Open an ASR node and click on "Try" to try out the speech recognizer.
  2. Wait until the recognizer has been loaded and then cancel the recognition.
  3. Click "Try" again.
  4. The ASR window opens very briefly and then is closed again.

This doesn't seem entirely reproducible, but we should keep an eye on it and fix it.

@alexanderkoller
Copy link
Contributor Author

@timobaumann Do you have the time to look into this? If the students notice this in their dialog development work (as in #125), less experienced users would probably struggle with it even more.

@timobaumann
Copy link
Contributor

it's also possible to trigger this without clicking try:

  1. embed ASR node in some simple model and click cancel before there is a recognition result.
  2. try to run again and it fails in the same way as outlined above.

@timobaumann
Copy link
Contributor

interesting: when I wait a while after that, I get:

Exception in thread "PulseAudio Eventloop Thread" java.lang.IllegalStateException: drain failed
        at org.classpath.icedtea.pulseaudio.EventLoop.native_iterate(Native Method)
        at org.classpath.icedtea.pulseaudio.EventLoop.run(EventLoop.java:133)
        at java.lang.Thread.run(Thread.java:748)

too bad we don't know what that thread is that is failing.

@alexanderkoller
Copy link
Contributor Author

Wow, that's a weird exception. The Google search seems to indicate that this is somehow related to audio playback. Are we playing back audio in some way before/during/after running the recognizer?

@timobaumann
Copy link
Contributor

nope. but I got that only once, so would not read too much into it.
I'm still debugging the issue. may be related to frontend processing, but I can't really explain how.

@alexanderkoller
Copy link
Contributor Author

Thanks!

@timobaumann
Copy link
Contributor

see cmusphinx/sphinx4#87

timobaumann added a commit that referenced this issue Dec 7, 2018
the main fix is in sphinx.frontend.feature.LiveCMN : avoid to keep
stale Data objects around in the queue. Other changes:
(a) avoid re-running recognition after cancellation (Sphinx.java)
(b) Java-9 adaptations in many places
@timobaumann
Copy link
Contributor

I still wonder why this bug only occurred on the very first invocation (i.e., you could cancel on a later invocation if you said something in the first without breaking things). Oh well.

@alexanderkoller
Copy link
Contributor Author

Wow. Cool. Thanks for taking care of this!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants