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

Home » Public Forums » archive » Re: My code is way to slow.. How can I optimize!?
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: My code is way to slow.. How can I optimize!? [message #46577 is a reply to message #46576] Mon, 28 November 2005 15:42 Go to previous messageGo to previous message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
jelle.ferwerda@rmit.edu.au writes:

> Anyway. It basically is a series of nested routines, within which I
> perform regressions on subsets, and generate statistics of these
> regressions.

I assume you mean nested loops, which is the usual culprit with
slow routines written in IDL. And you are right, we have (as a group)
had some success speeding this kind of code up:

http://www.dfanning.com/code_tips/slowloops.html

> Since about 300 lines of the code fall within these loops,
> i am not particularly sure which parts take most of the time.

Since it takes a day to run, I can understand not wanting to
run it with timing code. :-)

Still it would be worth while knowing what is slow and what
is REALLY slow.

> It probably is part of an array concenation part, which in a normal
> dataset is performed about 500,000 times. But it could also be the
> regression which is also performed about 500,000 times.

I expect you could find tips for improving the array concatenation
part up by searching through the archives of this newsgroup. If JD
hasn't written about it 50 times it would be a small miracle.

> I am convinced that my code is sub-sub-sub optimal. Just do not know
> where to start optimizing it, as I am not a programmer, but a mere
> ecologist :-(

I'll take your word for its optimized nature. I'm just saying I
don't care to look at 400 lines of code unless I'm also looking at your
credit card details. :-)

But why speed it up? It's served its purpose, it sounds like.
Maybe this is one mess that should just be buried and forgotten.
Let those guys who read your paper figure it out! :-)

Cheers,

David
--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.dfanning.com/
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Re: Quick question about creating tiff files.
Next Topic: Re: Large array memory problem.

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

Current Time: Sat Nov 29 17:22:17 PST 2025

Total time taken to generate the page: 0.40052 seconds