ML Community Day is November 9! Join us for updates from TensorFlow, JAX, and more Learn more

TensorAudio.TensorAudioFormat

public static abstract class TensorAudio.TensorAudioFormat

Wraps a few constants describing the format of the incoming audio samples, namely number of channels and the sample rate. By default, channels is set to 1.

Nested Classes

class TensorAudio.TensorAudioFormat.Builder Builder for TensorAudio.TensorAudioFormat  

Public Constructors

Public Methods

static TensorAudio.TensorAudioFormat.Builder
static TensorAudio.TensorAudioFormat
create(AudioFormat format)
Creates a TensorAudio.TensorAudioFormat instance from Android AudioFormat class.
abstract int
abstract int

Inherited Methods

Public Constructors

public TensorAudioFormat ()

Public Methods

public static TensorAudio.TensorAudioFormat.Builder builder ()

public static TensorAudio.TensorAudioFormat create (AudioFormat format)

Creates a TensorAudio.TensorAudioFormat instance from Android AudioFormat class.

Parameters
format

public abstract int getChannels ()

public abstract int getSampleRate ()