A Python wrapper around qoa Written using the CFFI library.
- QOA is fast. It decodes audio 3x faster than Ogg-Vorbis, while offering better quality and compression (278 kbits/s for 44khz stereo) than ADPCM.
- QOA is simple. The reference en-/decoder fits in about 400 lines of C. The file format specification is a single page PDF.
- Multi-threaded - Cffi unlocks the GIL
pip install qoa
You can use the qoa
library to encode and decode audio files. Here's a basic example:
import qoa
# Read an audio file
np_array = qoa.read('path/to/file')
# Write an audio file
qoa.write(np_array , 'path/to/file')
# Encode an audio file
buffer = qoa.encode(np_array)