Sample rate calculation is done of .wav data easily using following this code.
sampleRate, data = scipy.io.wavfile.read(\'ecg.wav\') times = np.arange(len(dat