Re: Memory deallocate problem [message #11295] |
Fri, 27 March 1998 00:00 |
Liam Gumley
Messages: 473 Registered: November 1994
|
Senior Member |
|
|
Ying Jin wrote:
> Does anyone know the mechanism of memory deallocation of IDL ?
> My problem is :
> When I open several big arrays, I literally exhaust all the available
> memory, but I need more. And I don't care to deallocate the memory
> for the previous arrays.
> I have digged through the help and manual of the IDL version 4.0.3.
> It turns out that IDL seems to not want user to tackle the issue by
> themselves.
IDL isn't going to change in a hurry, so you've got to adapt. Here's
some strategies:
(1) Don't use huge arrays. Spend a few minutes thinking about the
problem, and see if you can come up with an algorithm that handles the
problem in more reasonable chunks.
(2) Whenever you're done processing a large array, make sure you use
TEMPORARY() to undefine it, e.g. TVSCL, TEMPORARY(IMAGE). This makes a
big difference if you use it consistently. David Fanning's UNDEFINE
program (http://www.dfanning.com/programs/undefine.pro) is very useful
in this respect.
(3) If you're using a PC or Mac, buy more memory. On a PC 32MB can be
had for $75 or less, so why not stick and extra 64MB in that old PC.
Cheers,
Liam.
|
|
|
Re: Memory deallocate problem [message #11296 is a reply to message #11295] |
Fri, 27 March 1998 00:00  |
davidf
Messages: 2866 Registered: September 1996
|
Senior Member |
|
|
Ying Jin (yjin@eosdis.atmos.uah.edu) writes:
> Does anyone know the mechanism of memory deallocation of IDL ?
> My problem is :
> When I open several big arrays, I literally exhaust all the available
> memory, but I need more. And I don't care to deallocate the memory
> for the previous arrays.
Maybe I'm missing the point, but if you don't *want* to
deallocate the memory, why would you be interested in what
deallocation mechanism IDL uses?
What you need is more virtual memory. If you have the jack,
you can buy a bigger disk (or allocate more on the one you
have). If you have a systems administrator, you can give
him your first-born son. It's up to you. :-)
Cheers,
David
-----------------------------------------------------------
David Fanning, Ph.D.
Fanning Software Consulting
E-Mail: davidf@dfanning.com
Phone: 970-221-0438
Coyote's Guide to IDL Programming: http://www.dfanning.com/
|
|
|