Python wavio
From wikinotes
wavio
is a simple library for reading wavfiles into numpy arrays, and converting them back into numpy arrays.
NOTE:
Personally, I found the private methods much more useful than the public interface.
Documentation
github (no docs) https://github.com/WarrenWeckesser/wavio
Usage
import wavio numpy_array = wavio.read('/var/tmp/audio.wav') wavio.write( '/var/tmp/audio.wav', numpy_array, rate=44100, # samplerate/framerate in Hz ) wav_str = wavio._array2wav(numpy_array, sampwidth=2) numpy_array = wavio._wav2array(nchannels=2, sampwidth=2, numpy_array)