10-23-2012 03:40 AM
I was using an algorithm written in Matlab that executed in less than 2 seconds. Now I need to use it within a Labview program and I am using Matlab script with the same algorithm, but it lasts 10 times longer than in Matlab. Is this normal? Thank you!
10-23-2012 04:01 AM
How do you know that it is 10 times? Did you create a benchmark?
What are the conditions for the benchmark? Can you provide the code for it?
I am asking this because if you create the VI and put the m-script in the script node, and then press run (looking on the watch) and wait for the VI to finish, you "benchmarked" compile times, memory allocation as well as the complete VI's execution (including the script node of course). I doubt that this will ever be comparable to the "benchmark" in MatLab.
If you provide your VI, we might also be able to give some hints to increase performance.
Norbert