diff options
| author | Jules Laplace <julescarbon@gmail.com> | 2017-07-02 06:40:42 +0200 |
|---|---|---|
| committer | Jules Laplace <julescarbon@gmail.com> | 2017-07-02 06:40:42 +0200 |
| commit | ef0d6a05a1717b9cb9b52fca9285c9ba8c191b0c (patch) | |
| tree | 94954b6f983d636ea9744ab600e42c07ce7af735 /python | |
| parent | be26f182ccdff4f96c52d419deebee4aff055e18 (diff) | |
process aiff spectrum
Diffstat (limited to 'python')
| -rw-r--r-- | python/spectrum.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/python/spectrum.py b/python/spectrum.py index 514092b..267f368 100644 --- a/python/spectrum.py +++ b/python/spectrum.py @@ -13,8 +13,8 @@ FILENAME = sys.argv[1] N_FFT = 2048 def read_audio_spectum(filename): - fs, x = scipy.io.wavfile.read(filename) - S = librosa.stft(numpy.transpose(x)[0], N_FFT) + x, fs = librosa.load(filename, 44100) + S = librosa.stft(x, N_FFT) S = numpy.log1p(numpy.abs(S)) return S, fs |
