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

Home » Public Forums » archive » Re: IDL procedure to test/cerify IDL routines
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
Re: IDL procedure to test/cerify IDL routines [message #41199] Tue, 19 October 2004 09:47
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
Gianluca Li Causi writes:

> Anyway, I don't know what LINIX is: could you tell me about?

Oh, I am so confused trying to speak three or four languages,
my spelling is gone all the hell. You probably know this
as LINUX. :-)

Cheers,

David

P.S. I know of no way to test mathematical procedures
except to, well, just test them. As bug reports come in,
you get better at anticipating where problems are likely
to occur.

--
David W. Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http:/www.dfanning.com/
Phone: 970-221-0438, IDL Book Orders: 1-888-461-0155
Re: IDL procedure to test/cerify IDL routines [message #41200 is a reply to message #41199] Tue, 19 October 2004 08:57 Go to previous message
licausi is currently offline  licausi
Messages: 4
Registered: January 2003
Junior Member
David Fanning <david@dfanning.com> wrote in message news:<MPG.1bdd70a5deacce809896a1@news.frii.com>...
> Gianluca Li Causi writes:
>
>> I'm collecting a group of people in order to make an IDL library out
>> of our own routines,
>> so that I'm wondering if there exists an IDL routine able to test our
>> routines to be sure that they will work in any possible situation.
>
> Yeah, you and me, both!
>
> Cheers,
>
> David
>
> P.S. All I can tell you is LINIX is hell on IDL programs! :-(

Thank you all for your discussion on my topic: really I was intending
"mathematical errors", but of course I also would need all the other
kind of testing as well...
Anyway, I don't know what LINIX is: could you tell me about?
It seems from one of the replyes to this post that it makes hell just
with object graphics, which I'm not interested to (I'm an astronomer,
so...).


The question arises to me when I wrote a routine to compute
rototranslation between two images of stars: I've tested it with
various trial coordinate sets and all went ok, until a friend of mine
tried with an exact 45 degrees rotation and it doesn't work!
The reason was that I had a (sin(theta)-cos(theta)) within a matrix
and this made a singular matrix if theta=45 degrees, which was not
produced in my random tests!

So, I wonder if there is a routine able to parse the IDL program, find
that there is a sin(x)-cos(x) case and try it with an x=45 degrees
input automatically. And the same for any "special" case within the
program.

Thank you so much
Gianluca
Re: IDL procedure to test/cerify IDL routines [message #41209 is a reply to message #41200] Mon, 18 October 2004 13:14 Go to previous message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
JD Smith writes:

> It would be interesting to have a list of potential pitfalls for
> cross-platform compatibility... David?

I'm always fixing them so fast I forget to write them down. :-(

It's usually in the middle of a class, since I don't spend too
much time on UNIX machines, generally. And there, I usually
just want the problem to go away. Later, I can't recall what
the problem was, exactly.

Today, however, I happened to be setting the size of a text
widget, so that the widgets would align themselves properly.
They did, only on windows the text widget is about an inch long
and on LINUX is was about 2 feet long. Just exactly the kind
of problem I usually find.

I do agree that most of the problems are widget programs, IF
you are careful, as JD suggests with new RSI tools. And most
of the widget problems only show up if you are fairly anal about
how things look. If you are just slopping it together, the default
stuff works pretty well.

Cheers,

David

--
David W. Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http:/www.dfanning.com/
Phone: 970-221-0438, IDL Book Orders: 1-888-461-0155
Re: IDL procedure to test/cerify IDL routines [message #41211 is a reply to message #41209] Mon, 18 October 2004 10:16 Go to previous message
JD Smith is currently offline  JD Smith
Messages: 850
Registered: December 1999
Senior Member
On Mon, 18 Oct 2004 10:12:37 -0600, David Fanning wrote:

> Reimar Bauer writes:
>
>> what is "any possible situation" for you.
>
> I think he wants to know if the RSI marketing hype about
> IDL code being "cross-platform" is really true. I think
> the honest answer is "Uh, not exactly. Better test like
> crazy."
>
> Cheers,
>
> David
>
> P.S. Let's just say there are ways to write your programs
> so that they are *more* cross-platform compatible, but
> even careful coders get surprised more often than you might
> expect.

It would be interesting to have a list of potential pitfalls for
cross-platform compatibility... David? That said, from the
obviously-biased point of view of someone who almost never runs
anything under Windows (so take this with a grain of salt), I'd say
about the only real cross platform issues anymore, assuming you are
intelligent about filepaths, are problems with widget layout.

Smart use of things like:

files=file_search(filepath(ROOT=some_dir,SUBDIRECTORY='other s','*.txt'))

instead of

files=file_search(some_dir+'\'+others+'\*.txt')

will save you lots of trouble. When you need to decompose file
strings yourself, use PATH_SEP() instead of '\', or '/'. Stay away
from calls to SPAWN (much easier now that IDL offers lots of
cross-platform file status and directory listing/search commands
internally). Even DLMs and CALL_EXTERNAL libraries can be
automatically built cross-platform (with some amount of up-front
effort) -- see MAKE_DLL.

Current IDL (V6.x) is much more homogenous than older versions, where
VMS and other vestigial systems were supported. In fact, there are
now only two windowing systems still supported: Motif (Linux, Solaris,
AIX, IRIX, HP-UX, Mac OSX), and Windows. For the most part, widget
layouts designed for any of the Motif systems will work well with any
of the other Motif systems (assuming you don't make too many
assumptions about font size). Windows is a bit of a separate world,
and most layout issues you hear about come from crossing the boundary
dividing Windows & Motif.

As a side note, I believe Motif is essentially dead, supported
in-house for legacy applications or by proprietary software
developers, but less and less deployed on the "frontline" of Unix
development. The last widely used Motif application was probably
Netscape 4.X, and that, thankfully, is gone the way of the dodo. Even
Solaris is moving to GNOME/GTK. My personal view is that GTK+ would
be a much more capable target widget set than Motif, and that, at some
point, RSI is going to have to bite the bullet and re-target their
widgets (or cut off half of their user base, drop cross-platform from
their sales pitches, and become a Windows-only program). For this
effort they get a much more compelling toolkit, with many more native
widget components, and better platform integration. But it's no small
task.

JD
Re: IDL procedure to test/cerify IDL routines [message #41213 is a reply to message #41211] Mon, 18 October 2004 09:12 Go to previous message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
Reimar Bauer writes:

> what is "any possible situation" for you.

I think he wants to know if the RSI marketing hype about
IDL code being "cross-platform" is really true. I think
the honest answer is "Uh, not exactly. Better test like
crazy."

Cheers,

David

P.S. Let's just say there are ways to write your programs
so that they are *more* cross-platform compatible, but
even careful coders get surprised more often than you might
expect.

--
David W. Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http:/www.dfanning.com/
Phone: 970-221-0438, IDL Book Orders: 1-888-461-0155
Re: IDL procedure to test/cerify IDL routines [message #41214 is a reply to message #41213] Mon, 18 October 2004 08:39 Go to previous message
R.Bauer is currently offline  R.Bauer
Messages: 1424
Registered: November 1998
Senior Member
Gianluca Li Causi wrote:
> Hello guys,
> I'm collecting a group of people in order to make an IDL library out
> of our own routines,
> so that I'm wondering if there exists an IDL routine able to test our
> routines to be sure that they will work in any possible situation.
>
> Somebody in the area maybe knows a similar program or can suggest how
> to make it?
>
> Thank you so much
> Gianluca

Hm,

what is "any possible situation" for you.

We have a lot of CASE TOOLS. If you could better describe what you want
probably I could tell to use this one or this one.

Reimar
Re: IDL procedure to test/cerify IDL routines [message #41216 is a reply to message #41214] Mon, 18 October 2004 06:36 Go to previous message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
Ben Panter writes:

> Now you see why astronomers only ever use direct graphics and postscript
> output!!

Indeed, my biggest challenge so far is to make astronomers
use IDL instead of Ghostview to see their output. :-)

Cheers,

David

--
David W. Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http:/www.dfanning.com/
Phone: 970-221-0438, IDL Book Orders: 1-888-461-0155
Re: IDL procedure to test/cerify IDL routines [message #41217 is a reply to message #41216] Mon, 18 October 2004 06:30 Go to previous message
Ben Panter is currently offline  Ben Panter
Messages: 102
Registered: July 2003
Senior Member
David Fanning wrote:

> P.S. All I can tell you is LINIX is hell on IDL programs! :-(

Well, only if you want to make those pretty picture things work!

Now you see why astronomers only ever use direct graphics and postscript
output!!

Ben
--
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
Ben Panter, Garching, Germany
email via www.benpanter.co.uk
Re: IDL procedure to test/cerify IDL routines [message #41218 is a reply to message #41217] Mon, 18 October 2004 06:18 Go to previous message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
Gianluca Li Causi writes:

> I'm collecting a group of people in order to make an IDL library out
> of our own routines,
> so that I'm wondering if there exists an IDL routine able to test our
> routines to be sure that they will work in any possible situation.

Yeah, you and me, both!

Cheers,

David

P.S. All I can tell you is LINIX is hell on IDL programs! :-(
--
David W. Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http:/www.dfanning.com/
Phone: 970-221-0438, IDL Book Orders: 1-888-461-0155
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Shade_surf problem
Next Topic: JOB: IDL in sunny Seattle

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

Current Time: Wed Oct 08 19:39:14 PDT 2025

Total time taken to generate the page: 0.00555 seconds