07-12-2023 06:45 AM - edited 07-12-2023 06:56 AM
Hello,
I need to manipulate several waveforms (an array of waveforms). With "manipulate" I mean decimating, filtering and other operations that can potentially modify all the waveform components: Y, dt and t0.
The waveform array has from ten to about a hundred elements. The Y array size of each waveform ranges from 1 to 10k samples.
I wanted to iterate through the array and use an In Place Structure to access the elements of the array. I believed the In Place Structure was the fastest solution.
However, I did some tests comparing the In-Place approach with a simple indexing at the end of the loop (which recreates a new array each time the entire array is looped).
According to my tests (see attachment) using the end-of-loop indexing seems to be the fastest approach. I thought that using In Place Structures for this kind of things was faster.
Can anyone give me an explanation? Am I wrong?
Solved! Go to Solution.
07-12-2023 06:53 AM
Disable debugging, force sequential execution of test cases and try again 🙂
07-12-2023 07:09 AM
You are right.
Results are completely different by disabling debugging. The fastest solution is the In-Place approach, as expected.
Thanks