09-28-2008 11:53 PM
You are not quite there yet. The code does not really improve any memory allocations, because you are still no treating the 3D array "in place" (see below in red).
Just glancing at the code, here are a few things I noticed:
09-29-2008 11:11 AM
10-10-2008 07:37 AM
I attached three vi's: hrec_before is the original scanning vi, hrec_no array initialization is the modified hrec_before without initializing the 3D array, and hrec_array initialization is the modified hrec_before with the 3D array initialization. Also, the zip file contains a *.doc file with the memory performance.
Once again I want to build up a 3D array of N 2D arrays (holograms). N is the number of wavelengths which is equal to the number of holograms. What I have noticed? When I save the data file (3D array) there is not a significant difference in the file size (about 13.0 MB). The array is made of 50x256x256 for 13.0 MB (N=50). It's any way to further improve the program to get a small file size or that is it?Thanks.
10-10-2008 07:46 AM - edited 10-10-2008 07:48 AM
Arrays of more than 2D make me nervous since they can grow by a cube factor. Also singel arrays require contiguous memory.
60 single elements queues each containing a 2d array could be used to hold the data. Read the queue when you want that slice, write it back to the same queue after crunching.
[Edit]
Hold it! DF already said that! I guess I owe him a Kudos. ![]()
Ben