LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Slow graph update with NaN values

Hi,

 

I was playing with waveform graph (update via property node) and found out that it takes much longer when plotting data with NaN values compared to plotting data with no NaN values (see attached example). Is this expected behavior?

0 Kudos
Message 1 of 15
(1,896 Views)

Please post the code in 2011 version.

-----

The best solution is the one you find it by yourself
0 Kudos
Message 2 of 15
(1,891 Views)

@andrej wrote:

Hi,

 

I was playing with waveform graph (update via property node) and found out that it takes much longer when plotting data with NaN values compared to plotting data with no NaN values (see attached example). Is this expected behavior?


Is the NaN data replacing real data, or is it in addition to the real data?

 

nvm - I answered my own q by looking at the code.  😉

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
0 Kudos
Message 3 of 15
(1,885 Views)

Actually, I see no difference in the times.

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
0 Kudos
Message 4 of 15
(1,883 Views)

While benchmarking (against execution time) I prefer to run the code in a For loop and then take average. I don't see much difference also the results are quite inconsistent, probably because the target is Windows.

 

Benchmarking in Loop.png


I am not allergic to Kudos, in fact I love Kudos.

 Make your LabVIEW experience more CONVENIENT.


0 Kudos
Message 5 of 15
(1,880 Views)

However, if i connect the data directly to the indicator, instead of to the property node, the value drops to ~ 0 ms for either...

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
0 Kudos
Message 6 of 15
(1,879 Views)

Passing data using wire should always be first choice...!!


I am not allergic to Kudos, in fact I love Kudos.

 Make your LabVIEW experience more CONVENIENT.


0 Kudos
Message 7 of 15
(1,876 Views)

Hmmmm interesting. If I run with "No NaN values", the average time is around 24 ± 1 ms, while with "NaN values", the average time is 435 ± 5 ms. So results are quite different and consistent for me.

 

I'm aware that local variable and terminal will make it faster.

0 Kudos
Message 8 of 15
(1,870 Views)

Maybe you are demonstrating why it is so much better to wire data directly to an indicator, rather than to a property node.  😉

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
0 Kudos
Message 9 of 15
(1,865 Views)

@andrej wrote:

Hmmmm interesting. If I run with "No NaN values", the average time is around 24 ± 1 ms, while with "NaN values", the average time is 435 ± 5 ms. So results are quite different and consistent for me.

 

I'm aware that local variable and terminal will make it faster.


Even I got the same result but by wiring to the terminal no difference among both. I wonder it depends on the OS also (Smiley Indifferent)

-----

The best solution is the one you find it by yourself
0 Kudos
Message 10 of 15
(1,857 Views)