Convert 3-byte stereo WAV-file to numpy array
问题 I have been given a large WAV-file of continuous underwater recording which I would like to convert to a numpy array for analysis. I am struggling to do this. So far I have: import numpy as np import scipy as sp import wave as wv import struct wavefile = wv.open(filename,'r') (nchannels,sampwidth,framerate,nframes,comptype,compname) = wavefile.getparams() // read a sample as example wavedata =wavefile.readframes(1) The first frame looks like this: '\xcd\xbc\xff@\x01\x00'. I have tried to