Re: How to save output log by profiler [message #49367] |
Wed, 19 July 2006 00:03  |
peter.albert@gmx.de
Messages: 108 Registered: July 2005
|
Senior Member |
|
|
Hi,
under Linux, an alternative would be to use the "screen" command to log
the complete IDL session and afterwards grep the output generated by
IDL's "save" command out of the logfile. In a nutshell, it would work
like this:
(I'll use "$" as Linux prompt, "IDL> " for the IDL prompt and "<....>"
for comments )
$ screen
<Now the "screen" splash screen appears, and you have to press Space or
Return. Having done this, you are back on the Linux Prompt>
<Now we want to start logging, therefore you have to press "<ctrl> a",
followed by "<shift> h". A message should appear at the bottom of the
shell, saying "Logfile screenlog.0 created">
<Now you can satrt IDL as usual>
$ idl
IDL> ; Now in the IDL session you can do whatever is necessary, and
IDL> ; at one point there will come the
IDL>
IDL> save, /verbose
IDL> ; Now we can exit IDL
IDL> exit
< And we exit the screen session, thereby closing the logfile>
$ exit
<Now you just want to fetch "save"'s output from the logfile:
$ grep "% SAVE:" screenlog.0
Well, that sounds complicated, but it's not. Just give it a try if you
like.
Cheers,
Peter
>
> Ah, I see. You want to save the output of the VERBOSE keyword to SAVE? I
> don't think there is a straightforward way to do this. My suggestion
> would be to just save the file with SAVE, then use IDL_Savefile to query
> the savefile for the information that you would get with the VERBOSE
> keyword. I'll see if I can give an example later, but I have to run now...
>
> Mike
> --
> www.michaelgalloy.com
|
|
|