【发布时间】:2018-11-29 06:51:43
【问题描述】:
我正在尝试使用 Cloud Speech API 进行超过 1 分钟的实时语音识别,但同步语音识别的限制仅为每个请求 1 分钟。我试过运行https://github.com/GoogleCloudPlatform/python-docs-samples/blob/speech-continuous/speech/cloud-client/transcribe_streaming_indefinite.py 正如这个问题Multiple StreamingRecognizeRequest的回答所建议的那样,但我收到了这个错误:
File "transcribe_streaming_indefinite.py", line 30, in __init__
self._bytes_per_sample = 2 * self._num_channels AttributeError:
'ResumableMicrophoneStream' object has no attribute '_num_channels''
有人知道如何做到这一点吗?提前谢谢你。
【问题讨论】:
标签: python speech-recognition google-speech-api google-cloud-speech