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

Home » Public Forums » archive » Re: IDL out of range error
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: IDL out of range error [message #70157 is a reply to message #70154] Mon, 15 March 2010 18:57 Go to previous messageGo to previous message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
Suguru Amakubo writes:

> Hi, I have an error that has been bugging me for 3 weeks that I am
> hoping you could shed some light on.
>
> I am currently trying to create a subset of an image from a bigger
> image and comparing it to another subset of the same dimention.
>
> When I run the program however I recieve an error:
>
> Subscript range values of the form low:high must be >= 0, < size, with
> low <= high:

Three weeks!? And you haven't learned yet how to put a breakpoint
in your program and have a look around?

This kind of error is a user error 100% of the time.
I've never known it to be anything else in 25 years
of IDL programming. You are making an assumption about
your data that isn't true. When the program crashes,
have a look around. Look at the size of the images
you are subscripting, print out the values you are
using as subscripts. Don't assume anything, your assumptions
are wrong. This is an easy error to spot if you check
*everything*. There is no need to wait three more weeks
to solve this. :-)

Cheers,

David



--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Sepore ma de ni thui. ("Perhaps thou speakest truth.")
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: SIGN function: signof(num or array of num)
Next Topic: Re: SIGN function: signof(num or array of num)

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

Current Time: Wed Oct 08 19:35:20 PDT 2025

Total time taken to generate the page: 0.00395 seconds