05-24-2018 03:19 AM
Hi,
I am a pretty much new LabVIEW user. I have written a program to average images. I have attached the vi here. But, when I try to run the program it returns an error in the end "Image Is Not Large Enough for The Operation". I have tried with all the formats. None worked.
Regards,
Hudson.
Solved! Go to Solution.
05-25-2018 04:01 PM - edited 05-25-2018 04:04 PM
Hi,
I found two problems in your VI. The result of adding an array to a blank array is a blank array so you must initialize the array with 0 prior to adding the images.
You should also convert back to U32 before using the ArraytoColorImage.vi as that VI expects U32 data instead of Doubles.
Cheers!
05-27-2018 09:07 PM
I am using LabVIEW 2015 and that's why cannot open your vi. Can you please save it for v15 and send back. Many thanks.
05-27-2018 10:48 PM
I agree that the method you have for averaging Arrays is "fatally flawed" by forming a running sum that starts (and therefore ends) with an Empty Array, there is an even more fundamental error in your code -- what do you mean by "averaging Images"?
What is the nature of the Images? Are they GrayScale? Color? How many bits?
Have you considered that Image Intensity is usually represented by (at some level) a U8 or a U16 quantity? Have you thought about how you "average", say, 1000 U8 values? Here's something to try -- compute the average of 1000 U8 constant values of 100 -- do you get the answer of 100 when you add it to itself (as a U8!) 1000 times and then divide by 1000? Oops ...
Bob Schor
05-27-2018 11:35 PM
Bob already mentioned some glaring mistakes, here are a few more.
05-28-2018 02:39 PM - edited 05-28-2018 02:45 PM
I apologize for posting on the latest version. My comments above only address the error. Bob and Altenbach are right about everything else.
05-28-2018 07:47 PM
Thanks for helping 🙂