LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Waveform resampling results in "memory is full"

Hi all,

 

I've a small issue using the "Resample waveforms" function. I have a 1 minute tone sampled at 44.1 kHz. I need to resample it at 48 kHz. When I run the attached example here are the LabVIEW.exe memory use as seen in Windows Task Manager :

- Before "Sine Waveform.vi" = 149'580 KB

- Before "Resample Waveforms" = 232'440 KB

- After "Resample Waveforms" = 505'056 KB

 

First question : Why does memory use increase by around 80 MB when I create a 1 minute waveform ? The waveform length is 60 seconds and sampling rate is 44100 Hz => 2646 KSamples. The waveform datatype is DBL (64 bits) => 2646 KSamples * 64 bits => 20.19 MB. What is wrong ?

 

Furthermore, the resampling function works but seems to not release memory after processing the waveform. Is there any way to force memory deallocation of a single function ?

 

Thanks and best regards,

Alex

0 Kudos
Message 1 of 3
(2,710 Views)

Hi Alex,

 

using LV2011SP1 task manager gives following numbers:

before "sine": 107MB

after "sine": 128MB (waveform needs ~20MB)

after "resample": 346MB

 

So resampling tooks it's memory - and will free it only, when the VI gets removed from memory. Additionally you need memory for the waveform indicator, which now holds 2880000 samples!

 

Subsequent runs of the VI only increase the memory usage before "sine", after "sine" still takes additional 20MB, after "resample" stops with 346MB...

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 2 of 3
(2,704 Views)

Hi GerdW,

 

Thanks for you reply.

 

My first run was done with LV2009SP1. I tried again with LV2011 and now I get the same as you. After "sine", I get a memory use increase of around 20 MB (doing the same on LV2009 results in 80 MB). So there is something which I can't explain with LV2009.

 

Best regards,

Alex

0 Kudos
Message 3 of 3
(2,696 Views)