def test_set_fftlib(): librosa.set_fftlib('foo') assert librosa.get_fftlib() == 'foo' librosa.set_fftlib()
def test_reset_fftlib(): import numpy.fft as fft librosa.set_fftlib() assert librosa.get_fftlib() is fft
import sys sys.path.append('tsss') import wavdecode import Note import pyaudio import glob import time import wave import numpy as np import cProfile import librosa import pyfftw librosa.set_fftlib(pyfftw.interfaces.numpy_fft) import soundfile as sf from pydub import AudioSegment from pydub.playback import play CHANNELS = 2 SAMPLEWIDTH = 3 # 24bi SAMPLERATE = 48000 FRAMESPERBUFFER = 48000 # FRAMESPERBUFFER = 1024 fs = sorted( glob.glob( "/run/media/gotzl/stuff/realsamples/German Harpsichord 1741/Front 8'/*/*.wav" )) wavs = [wave.open(f, 'rb') for f in fs[:10]] print(fs[-1])