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

Home » Public Forums » archive » Re: How to know how much memory (in Mb) takes an object ? 1700 on memory grObjects is too much?
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: How to know how much memory (in Mb) takes an object ? 1700 on memory grObjects is too much? [message #64979] Fri, 06 February 2009 21:32 Go to next message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
bernat writes:

> Ahora estoy como al principio (I know u undertand spanish David :P)

S�, pero yo entienda solamente un poco. :-)

> Have we the same oppinion when I say that object graphics have a
> better look-and-feel (looks more nice) than Direct Graphics ?

Yes, we are in absolute agreement about this.

> The most important difference between my application (in
> ObjectGraphics) and the last application version (in Direct Graphics)
> is the appearence of the fonts.

Yes, but is a lot of work for fonts, verdad? :-)


> But.... maybe there is a way to represents a nice Fonts using Direct
> Graphics and all of my work was for nothing (useless).

Very few ways to get nice fonts using direct graphics
in display windows. But I get great looking viewgraphs,
etc., now that I know how to use ImageMagik to turn
PostScript files into PDF or PNG files. :-)

See, for example, the PS_START/PS_END programs on my web page.

Cheers,

David

P.S. Donde vive usted? Quisiera visitarle. Comprar� la cerveza. :-)

--
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: How to know how much memory (in Mb) takes an object ? 1700 on memory grObjects is too much? [message #64980 is a reply to message #64979] Fri, 06 February 2009 20:57 Go to previous messageGo to next message
Giorgio is currently offline  Giorgio
Messages: 31
Registered: March 2008
Member
> The other question was how to know how much memory is an object
> taken...


One possibility which I did not explore is to use the memory function.
One issue will be when dynamic variables change size.

Cheers,

Giorgio
Re: How to know how much memory (in Mb) takes an object ? 1700 on memory grObjects is too much? [message #64996 is a reply to message #64980] Fri, 06 February 2009 12:44 Go to previous messageGo to next message
natha is currently offline  natha
Messages: 482
Registered: October 2007
Senior Member
Ok,

Ahora estoy como al principio (I know u undertand spanish David :P)

Have we the same oppinion when I say that object graphics have a
better look-and-feel (looks more nice) than Direct Graphics ?
The most important difference between my application (in
ObjectGraphics) and the last application version (in Direct Graphics)
is the appearence of the fonts.

But.... maybe there is a way to represents a nice Fonts using Direct
Graphics and all of my work was for nothing (useless).

I agree your oppinions

Thanks

B.
Re: How to know how much memory (in Mb) takes an object ? 1700 on memory grObjects is too much? [message #64997 is a reply to message #64996] Fri, 06 February 2009 12:16 Go to previous messageGo to next message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
bernat writes:

> I had an application writted using direct graphics and I converted it
> to object graphics. I prefer object graphics because the fonts and all
> the interaction (in general) are better
> The problem is, for example, when I convert a loop like this:
>
> plot, x, y
> For i=0, 1500 Do oplot, x2[i,*], y2[i,*]
>
> For this example I use 1500 IDLgrPlot objects and I save all of that
> in an IDLgrModel.
> Now I'm asking if it's correct to save all of this references in
> memory.
> Maybe this a crazy question....

Well, if you want to redraw the plot (maybe you resized the
window or something), then you are either going to have to
have all these objects available, or you are going to have
to re-create them. (By the way, I think I would have used
polylines rather than plots, but I don't know if one is
better than the other or not.)

> I used the IDLgrBuffer for convert all of that to an IDLgrImage. So, I
> only have 1 object in memory.

If your application allows this (not much interactivity, I guess)
then what the heck, destroy all those overplot objects. You
aren't going to use them anyway.

> The other question was how to know how much memory is an object
> taken...

I don't know. Objects are implemented as named structures, so...
Some overhead, I guess, but not that much. I suppose there much
be a place where the overhead of storage has to be balanced against
the time needed to create and destroy all these objects. Hard to
say if 1500 is the limit. What kind of performance to you get
if you have to re-draw?

> What do you think about that David ?

I think unless you are throwing this plot onto the screen
of your local movie theater, that plot is going to be damned
hard to read! :-)

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: How to know how much memory (in Mb) takes an object ? 1700 on memory grObjects is too much? [message #64998 is a reply to message #64997] Fri, 06 February 2009 12:08 Go to previous messageGo to next message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
bernat writes:

> I had an application writted using direct graphics and I converted it
> to object graphics. I prefer object graphics because the fonts and all
> the interaction (in general) are better
> The problem is, for example, when I convert a loop like this:
>
> plot, x, y
> For i=0, 1500 Do oplot, x2[i,*], y2[i,*]
>
> For this example I use 1500 IDLgrPlot objects and I save all of that
> in an IDLgrModel.
> Now I'm asking if it's correct to save all of this references in
> memory.
> Maybe this a crazy question....

Well, if you want to redraw the plot (maybe you resized the
window or something), then you are either going to have to
have all these objects available, or you are going to have
to re-create them. (By the way, I think I would have used
polylines rather than plots, but I don't know if one is
better than the other or not.)

> I used the IDLgrBuffer for convert all of that to an IDLgrImage. So, I
> only have 1 object in memory.

If your application allows this (not much interactivity, I guess)
then what the heck, destroy all those overplot objects. You
aren't going to use them anyway.

> The other question was how to know how much memory is an object
> taken...

I don't know. Objects are implemented as named structures, so...
Some overhead, I guess, but not that much. I suppose there much
be a place where the overhead of storage has to be balanced against
the time needed to create and destroy all these objects. Hard to
say if 1500 is the limit. What kind of performance to you get
if you have to re-draw?

> What do you think about that David ?

I think unless you are throwing this plot onto the screen
of your local movie theater, that plot is going to be damned
hard to read! :-)

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: How to know how much memory (in Mb) takes an object ? 1700 on memory grObjects is too much? [message #64999 is a reply to message #64998] Fri, 06 February 2009 11:42 Go to previous messageGo to next message
natha is currently offline  natha
Messages: 482
Registered: October 2007
Senior Member
Ok,

I had an application writted using direct graphics and I converted it
to object graphics. I prefer object graphics because the fonts and all
the interaction (in general) are better
The problem is, for example, when I convert a loop like this:

plot, x, y
For i=0, 1500 Do oplot, x2[i,*], y2[i,*]

For this example I use 1500 IDLgrPlot objects and I save all of that
in an IDLgrModel.
Now I'm asking if it's correct to save all of this references in
memory.
Maybe this a crazy question....

I used the IDLgrBuffer for convert all of that to an IDLgrImage. So, I
only have 1 object in memory.
The other question was how to know how much memory is an object
taken...

What do you think about that David ?
Thanks,

Bernat
Re: How to know how much memory (in Mb) takes an object ? 1700 on memory grObjects is too much? [message #65031 is a reply to message #64999] Mon, 09 February 2009 15:13 Go to previous messageGo to next message
Giorgio is currently offline  Giorgio
Messages: 31
Registered: March 2008
Member
Que bueno es ver que existe una pequeña comunidad de hispano-hablantes
que usa IDL! O en todo caso, que existe gente que usa IDL y le gusta
el español :-).
Bernat, en que parte de Canada estas? Yo estoy en Vancouver y soy
argentino.

Giorgio
Re: How to know how much memory (in Mb) takes an object ? 1700 on memory grObjects is too much? [message #65055 is a reply to message #64979] Mon, 09 February 2009 06:10 Go to previous messageGo to next message
natha is currently offline  natha
Messages: 482
Registered: October 2007
Senior Member
I'm form Barcelona (Spain) but now I'm working in Canada.

We talk to you before, when u went to Spain (I invited you to see our
university but you was too busy in Madrid I think)
I'll continue using object graphics but thank you for the PS_START/
PS_END programs. It looks so interesting.






> See, for example, the PS_START/PS_END programs on my web page.
>
> Cheers,
>
> David
>
> P.S. Donde vive usted? Quisiera visitarle. Compraré la cerveza. :-)
>
> --
> 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: How to know how much memory (in Mb) takes an object ? 1700 on memory grObjects is too much? [message #65115 is a reply to message #65031] Tue, 10 February 2009 08:33 Go to previous message
natha is currently offline  natha
Messages: 482
Registered: October 2007
Senior Member
Soy de Barcelona, estoy en la otra punta de Canada. Montreal !
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Re: How to define resolution (not dimension!) for IDLanRoi->computeMask
Next Topic: Nice Fonts in Direct Graphics

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

Current Time: Wed Oct 08 20:01:53 PDT 2025

Total time taken to generate the page: 0.40791 seconds