What types of audio are supported by Cloud Speech API?

痞子三分冷 提交于 2019-12-25 09:48:32

问题


There are a lot of audio formats (e.g., mp3, m4a), sources (e.g., dictation, commands, phone calls, meetings) and devices (e.g., phones, PCs, IoT devices). Which ones work best with Cloud Speech API?


回答1:


Which ones work best with Cloud Speech API?

Supported ones shall work best:

  • LINEAR16 Uncompressed 16-bit signed little-endian samples. This is the only encoding that may be used by speech.asyncrecognize.
  • FLAC This is the recommended encoding for speech.syncrecognize and StreamingRecognize because it uses lossless compression; therefore recognition accuracy is not compromised by a lossy codec.
  • MULAW 8-bit samples that compand 14-bit audio samples using G.711 PCMU/mu-law.
  • AMR Adaptive Multi-Rate Narrowband codec. sampleRate must be 8000 Hz.
  • AMR_WB Adaptive Multi-Rate Wideband codec. sampleRate must be 16000 Hz.

https://cloud.google.com/speech/reference/rest/v1beta1/RecognitionConfig#AudioEncoding



来源:https://stackoverflow.com/questions/38485515/what-types-of-audio-are-supported-by-cloud-speech-api

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!