sampleRateHertz property

  1. @TagNumber(2)
int get sampleRateHertz

Sample rate in Hertz of the audio data sent for recognition. Valid values are: 8000-48000. 16000 is optimal. For best results, set the sampling rate of the audio source to 16000 Hz. If that's not possible, use the native sample rate of the audio source (instead of re-sampling). Supported for the following encodings:

  • LINEAR16: Headerless 16-bit signed little-endian PCM samples.

  • MULAW: Headerless 8-bit companded mulaw samples.

  • ALAW: Headerless 8-bit companded alaw samples.

Implementation

@$pb.TagNumber(2)
$core.int get sampleRateHertz => $_getIZ(1);
  1. @TagNumber(2)
set sampleRateHertz (int v)

Implementation

@$pb.TagNumber(2)
set sampleRateHertz($core.int v) {
  $_setSignedInt32(1, v);
}