Fix stereo handling in getPeaks (off-by-one)