-
Notifications
You must be signed in to change notification settings - Fork 6.4k
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
Streaming too fast from Streaming API sample code (unmodified) #742
Comments
@jerjou Is this due to an issue from GCP speech service or the way sample client code is written? |
Huh... interesting. The "streamed too fast" error you're getting occurs when the sample rate specified in the initial config request doesn't match the rate at which the api is receiving the data. I've seen it happen when the device was opened with a different sample rate than was sent in the config request (See #364). Did you check that the audio device supports the sample rate specified? The sample code assumes a sample rate of 16000, but not all devices support that. |
@jerjou I have set the sampling rate of input device to 2 channel, 16 bit, 48000 Hz. The options available from my laptop (hp elitebook 8570w with windows 8) limits to 2 channels and higher sampling rates. Unfortunately I don't see mono channel and lower sampling rate options in audio recording properties. When rate is set to 48000 and channel = 2 is passed to initial config, getting the following error. C:\Users\chandana_kithalagama>cd C:\Users\chandana_kithalagama\Documents\1. HLB\google stt integration
|
@jerjou another observation is that when I changed rate back to 16 kHz and channels = 1, I could get the transcripts for 1 min without 'streaming errors'. I wasn't able to get any transcripts yesterday around this time having tried running the sample for 3 times. I noticed this behavior multiple times during last two weeks. Doesn't this suggest a problem at server side? If the sampling rate is the issue, it should consistently throw the error. |
Per https://goo.gl/z757pE, the api only supports 1-channel (and per https://g.co/cloud/speech/limits#content streaming is limited to 1 minute) Looking into whether there was a server outage yesterday.. |
@jerjou check with back end guys on how stable the speech API is. I'm asking this as this is in beta. Could it have issues that lead to 'streaming too fast' error at times during a day. I have seen this issue time to time during the past two weeks. I tested it once more now and it works fine which means channels = 2 is working too despite the disclaimer as you pointed out. |
Hi. Tory. I am using ubuntu 16 on Raspberry pi 3. ========================================= ras@ras:~$ aplay -l
|
This seems to be the same issue as #738, plus perhaps an intermittent server outage? Closing for now - please comment with clarification if this is a separate issue. |
Thanks @jerjou. Yes, it is more or less the same issue but with the original sample code from git. @ToryHwang could you confirm if this is fixed? I don't have a laptop with me (just migrated to Australia) to confirm. |
In which file did you encounter the issue?
transcribe_streaming.py
Did you change the file? If so, how?
No
Describe the issue
We have witnessed a very inconsistent behavior of streaming API functionality of google cloud speech service during the last week in our testing in different environments. I have raised couple of tickets for each observation. However, we didn't realize that issue was even in the original script as we did our initial testing with a modified script to use
arecord
instead ofpyaudio
to circumvent an issue in NAO robot OS (see #738 ). As none of the fixes worked out, we tried testing the originaltranscribe_streaming.py
file on windows 8 and python 2.7.11 but ended up with the inconsistent behavior. During our testing, we ran intostreaming too fast
error couple of times (see following stack trace). This error didn't occur consistently with every attempt we made to run the script. We tried running script for multiple times at 4 different times of the day out of which the error was thrown on two times of the day. This script was used as is with no changes at all. Is there any reason for the script to throw this error at different attempts? What does it depend on? Is there a way to get rid of this error?The text was updated successfully, but these errors were encountered: