Exemple #1
0
def main():
    config = Configuration()

    for fname in sys.argv[1:]:
        x = common.load(open(fname, 'rb'))
        t = np.arange(len(x)) * config.Ts
        pylab.figure()
        pylab.title(fname)
        spectrogram(t, x, config.Fs)

    pylab.show()
Exemple #2
0
def main():
    config = Configuration()

    for fname in sys.argv[1:]:
        x = common.load(open(fname, 'rb'))
        t = np.arange(len(x)) * config.Ts
        pylab.figure()
        pylab.title(fname)
        spectrogram(t, x, config.Fs)

    pylab.show()
Exemple #3
0
def resample(src, dst, df=0.0):
    x = common.load(src)
    sampler = Sampler(x, Interpolator())
    sampler.freq += df
    y = sampler.take(len(x))
    dst.write(common.dumps(y))
Exemple #4
0
def resample(src, dst, df=0.0):
    x = common.load(src)
    sampler = Sampler(x, Interpolator())
    sampler.freq += df
    y = sampler.take(len(x))
    dst.write(common.dumps(y))