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

Home » Public Forums » archive » large info structure?
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
large info structure? [message #56127] Tue, 02 October 2007 08:10 Go to next message
markb77 is currently offline  markb77
Messages: 217
Registered: July 2006
Senior Member
Hi,

I'm writing a widget application which will serve as a data analysis
platform for scientific image data. The idea is that after loading
the image, there are many different types of analysis that the user
may wish to run on it, and this application will support them all.
There will be an 'Analysis' dropdown menu, for instance, with several
options. I also want to make it easy to add new analysis methods to
the program.

I've finished writing the front end and now I'm in the process of
adding some analysis. What I'm noticing is that the info structure
that gets passed around between event handlers is getting to be very
large. Mine is up to 130 variables, at the moment.

Does anyone have a strategy to suggest for dealing with this type of
situation? I'm worried that this info data will spiral out of
control. I was thinking that I could break down the info data into a
bunch of smaller structures, and hold pointers to each of those
structures in one higher level info structure..

thanks,
Mark
Re: large info structure? [message #56151 is a reply to message #56127] Fri, 05 October 2007 12:07 Go to previous messageGo to next message
markb77 is currently offline  markb77
Messages: 217
Registered: July 2006
Senior Member
Ok, I'm starting to see where you guys are coming from. I pulled out
David's book and read the last chapter. Very intriguing. I'm already
using object graphics, and I love not having to keep track of all the
details that are stored in IDL graphics objects. I can see how this
concept fits well with what I'm trying to do.

I wish I had two more chapters of David's book : Chapter 14 where he
integrates objects with widget programming and IDL object graphics,
and Chapter 15 where he actually writes my application for me :)

Mark
Re: large info structure? [message #56176 is a reply to message #56127] Thu, 04 October 2007 20:01 Go to previous messageGo to next message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
David Fanning writes:

> And I second JD's call to get rid of the
> NO_COPY keyword. There are MUCH better ways to pass information
> around in widget programs!

After getting a beer and thinking about this some, I have
to admit teaching about this is a VERY good way to
introduce the TEMPORARY function. And I don't think you
can really appreciate the most important parts of the
Pointer Tutorial without understanding the role of
NO_COPY. So I guess I'd probably still teach it, but
abandon it fairly quickly after I exhausted its
pedological properties. :-)

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.")
Re: large info structure? [message #56177 is a reply to message #56127] Thu, 04 October 2007 19:44 Go to previous messageGo to next message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
markb77@gmail.com writes:

> It isn't the actual size of the info structure that I'm worried about,
> it's the sheer number of entries in it. I tend to get lost in pages
> and pages of variables...

I've written a couple of what I consider to be fairly
big applications, but I don't remember pages and pages
of variables. Much closer to 100 than to 1000, certainly.
Although, I just counted 90 in PSConfig, which is the
last big program I wrote before I learned how to write
with objects in a sensible way. Maybe 1000 is not far
out of the ballpark. :-(

Cheers,

David

P.S. Let's just say, if I were to write PSConfig over, I'm
certain it wouldn't have anywhere close to 90 variables in
the info structure. And I second JD's call to get rid of the
NO_COPY keyword. There are MUCH better ways to pass information
around in widget programs!

--
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.")
Re: large info structure? [message #56178 is a reply to message #56127] Thu, 04 October 2007 18:06 Go to previous messageGo to next message
markb77 is currently offline  markb77
Messages: 217
Registered: July 2006
Senior Member
It isn't the actual size of the info structure that I'm worried about,
it's the sheer number of entries in it. I tend to get lost in pages
and pages of variables...

Mark
Re: large info structure? [message #56386 is a reply to message #56127] Wed, 24 October 2007 11:06 Go to previous message
R.Bauer is currently offline  R.Bauer
Messages: 1424
Registered: November 1998
Senior Member
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

markb77@gmail.com schrieb:
> Hi,
>
> I'm writing a widget application which will serve as a data analysis
> platform for scientific image data. The idea is that after loading
> the image, there are many different types of analysis that the user
> may wish to run on it, and this application will support them all.
> There will be an 'Analysis' dropdown menu, for instance, with several
> options. I also want to make it easy to add new analysis methods to
> the program.
>
> I've finished writing the front end and now I'm in the process of
> adding some analysis. What I'm noticing is that the info structure
> that gets passed around between event handlers is getting to be very
> large. Mine is up to 130 variables, at the moment.
>
> Does anyone have a strategy to suggest for dealing with this type of
> situation? I'm worried that this info data will spiral out of
> control. I was thinking that I could break down the info data into a
> bunch of smaller structures, and hold pointers to each of those
> structures in one higher level info structure..
>
> thanks,
> Mark
>

Hi

lots of comments already. I am not sure if you know uname and that you
can get quite everything back you added to widget elements. So the
question is why do you like to duplicate this data?

cheers
Reimar






-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (GNU/Linux)
Comment: Using GnuPG with SUSE - http://enigmail.mozdev.org

iD8DBQFHH4ma5aOc3Q9hk/kRAgxKAKCLR7KRJNXsL/46lxrN3Qt1xZFTSgCf U4xu
IvrwWeTiGfyvXczNSM1HSpw=
=f0F/
-----END PGP SIGNATURE-----
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Re: weighted average for label_region
Next Topic: Recognizing double precision?

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

Current Time: Wed Oct 08 13:44:08 PDT 2025

Total time taken to generate the page: 0.01270 seconds