Re: maximum LUN [message #64006 is a reply to message #63928] |
Mon, 24 November 2008 19:46   |
Jeremy Bailin
Messages: 618 Registered: April 2008
|
Senior Member |
|
|
On Nov 24, 1:30 pm, Reimar Bauer <R.Ba...@fz-juelich.de> wrote:
> greg.a...@googlemail.com schrieb:
>
>
>
>>> What reason could there possibly be for having hundreds
>>> of files open simultaneously? The only thing that comes
>>> immediately to mind for me is a poor programming concept. :-)
>
>> I kind of expected that reply... :) I think I do have a valid
>> application, though. I have an archive of a few thousand satellite
>> images, each of which has 6 bands, stored in separate files. I've made
>> an object which can handle the six bands and return a subset image for
>> a selected region processed as I want it. It also returns the image's
>> coverage of the region, so that I can fill in any gaps with data from
>> other images. This I do by opening further image objects. So far, I
>> can use four of these to make an on-the-fly mosaic before I run out of
>> LUNs - and it works well up to that point. The program allows zooming
>> and panning, so I need repeat access to similar regions of the same
>> files. I think it would be too slow to close and reopen them every
>> time, so the objects hold the files open. The archive is several
>> terabytes, changing, and not in my control - so preprocessing is out.
>> With 128 LUNs instead of 28 I could mosaic about 20 image subsets,
>> which will be enough for the moment. Still, if the number 128 was just
>> an arbitrary choice long ago, I'd like to ask early for a bigger one!
>
>> cheers,
>> Greg
>
> close and open costs nothing. The code between both lines can be
> efficient or not.
>
> cheers
> Reimar
Not exactly "nothing", but about 0.2 ms for me:
IDL> s1=systime(/sec) & openr,1,'foo' & close,1 & s2=systime(/sec) &
print, s2-s1
0.00021815300
IDL> s3=systime(/sec) & s4=systime(/sec) & print, s4-s3
6.9141388e-06
-Jeremy.
|
|
|