comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » for loops and calls to functions/objects
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
for loops and calls to functions/objects [message #59864] Tue, 15 April 2008 08:11
Charles at AER is currently offline  Charles at AER
Messages: 2
Registered: April 2008
Junior Member
Dear Newsgroup,

A program I am optimizing loads a series of images from netcdf files,
the user may select an arbitrary number of images to display. Within
a for loop, the program calls a netcdf reader that initializes a
netcdf object, gets lat and lon info and then grabs an image. If the
user wants to look at 10 images, the read net cdf is called 10 times,
and the time to initialize the netcdf object takes 0.1 seconds, and to
get the image takes 0.2 seconds. Here's the rub, if the user wants
to investigate 70 images, the netcdf initialization is 10 times longer
- about 1 second, similarly, the get method loads the image in 2
seconds. So to read 10 images takes 3 seconds, and to read 70 images
takes 210 seconds. The exponential increase is untenable. Does any
one understand what is happening, and are there work-arounds? Thanks.

Sincerely,

Charles
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Re: Array plotting and segmentation
Next Topic: Re: for loops and calls to functions/objects

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 18:11:27 PDT 2025

Total time taken to generate the page: 0.00560 seconds