paddleaudio.backends.common module
- class paddleaudio.backends.common.AudioInfo(sample_rate: int, num_frames: int, num_channels: int, bits_per_sample: int, encoding: str)[source]
Bases:
objectreturn of info function.
This class is used by "sox_io" backend and "soundfile" backend with the new interface.
- Variables
sample_rate (int) -- Sample rate
num_frames (int) -- The number of frames
num_channels (int) -- The number of channels
bits_per_sample (int) -- The number of bits per sample. This is 0 for lossy formats, or when it cannot be accurately inferred.
encoding (str) --
Audio encoding The values encoding can take are one of the following:
PCM_S: Signed integer linear PCMPCM_U: Unsigned integer linear PCMPCM_F: Floating point linear PCMFLAC: Flac, Free Lossless Audio CodecULAW: Mu-lawALAW: A-lawMP3: MP3, MPEG-1 Audio Layer IIIVORBIS: OGG VorbisAMR_WB: Adaptive Multi-RateAMR_NB: Adaptive Multi-Rate WidebandOPUS: OpusHTK: Single channel 16-bit PCMUNKNOWN: None of above