From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
03-18-2016 02:11 AM
Hi frndz...
I am using CPU with 4-GB RAM, My labview application does following things
1) It loads the an excel sheet with memory size( 5MB to 60MB)
2) Analyze the rows and columns with some formula, example avaeraging some columns, finding max value, min value, finding average by omitting 0s, some formulas, etc
3) And finally the consolidated data will be written in another excel file
Issues
1) This application only works for the excel files with size upto(25MB)
2) If file size goes beyond that " Not have enough memory to complete this operation" error is displayed and RAM memory utilization is upto 3.00GB
Observations
1) WHen i am developing this software, whilw working with the source code only max 5MB file i can use and test. but after building exe it is taking files upto 25 to 30 MB
2) Looking for advice in handling memory here.
Thanks in Advance..
03-18-2016 03:03 AM - edited 03-18-2016 03:10 AM
Well, it would be useful to see some code.
4GB is not that much these days. What else is running on the computer?
03-18-2016 03:27 AM
Hi altenbach
--- Its an excel file generated from other application
---I am deleting it by passing every index into loop and comapare it to delete )
----Size on the Disk
----Yes its Computer RAM Memory
----32-Bit Windows 7
4GB is not that much these days. What else is running on the computer?
-----I accept it,
I have attached the complete Code kindly have a glance at it.
.
03-18-2016 04:30 AM
How to handle memory in these kinds of situations?
03-18-2016 05:14 AM - edited 03-18-2016 05:15 AM
After a very quick glance, the glaring spot to me is in your Modes To Remove. Instead of using Build Array inside of a FOR loop, use Autoindexing Tunnels. This will prevent a lot of duplicating of memory.
Also, your ModeToRemove event should call the state that does the exact same thing. No need to duplicate code.
03-18-2016 05:56 AM
Hi Crossrulz
Thank you for the reply, I have altered the code as per above in every part of code. And it seems works like the same. Is there anyother things u can observe apart from this. I tried doing all i know.
03-18-2016 11:30 AM
@karthickkece wrote:----32-Bit Windows 7
Have a look here. LabVIEW can only use 2GB of RAM in 32bit windows. You can possibly change the boot configuration to allow 3GB, but I don't think that will help you much. The solution is in efficient code.
(Sorry, I have not looked at your code. Not sure when I will have time....)
03-18-2016 11:41 AM
OK, looking at your code...
What is the toplevel VI?
Looking at "ExcelRead.vi" and "consolidatetograph.vi":
You don't seem to understand the "request deallocation" function at all, else why would you place it inside a sequence frame?
If these subVIs typically operate on similar size data, requesting deallocation forces it to allocate the same amount of memory again on the next run while without this function it can re-use the already allocated memory, a much cheaper scenario.
I'll have another look later....
03-18-2016 11:49 PM
You are using "Excel" functions that I don't recognize. Is this a third-party package to read/write Excel? I have a fair amount of experience with the Report Generation Toolkit that NI supplies, which "hooks" into Excel and appears to be pretty efficient.
I just checked our Experiment machine, where we use Excel mainly to provide the hundred-or-so parameters necessary for every Experiment Trial (and there can be several hundred trials) -- most of the cells are "read-only", but we do write back into some to record, for example, how much LabVIEW (analog and Event) data we took during that trial. We are also running Win 7 32-bit (for the life of me, I'm not sure why), but we have 8GB of memory on that PC. [If memory is your only problem, memory is really cheap these days ...].
Bob Schor
03-19-2016 12:22 AM - edited 03-19-2016 12:29 AM
Windows 32bit cannot address more than 4GB, so 8GB would not make any difference. (See here for example)