nnAudio icon indicating copy to clipboard operation
nnAudio copied to clipboard

nnAudio-CPU memory growth

Open will-wiki opened this issue 3 years ago • 2 comments

Hello, I am using nnAudio to extract the CQT features of the audio in the following way


from nnAudio import features
cqt_layer = features.CQT2010v2(sr=16000).to(torch.device('cuda'))
data, sr = librosa.load(audio_file, sr=None)
 with torch.no_grad():
        data = torch.tensor(data, dtype=torch.float32).to(torch.device('cuda'))
        cqt = cqt_layer(data)[0].cpu().numpy()

However, the problem is that when the amount of data requested is fixed, increasing concurrency causes memory to keep growing image

will-wiki avatar Oct 28 '22 02:10 will-wiki

How do you increase concurrency? Using torch.multiprocessing? Maybe you can share your code with concurrency included.

gudgud96 avatar Feb 05 '23 06:02 gudgud96

Hi! @will-wiki , what do you mean by "fixed amount of data"?

migperfer avatar Mar 30 '23 19:03 migperfer