Electronic Data Logs

Created 01/01/99 NC
Updated 09/06/06 TG
Updated 07/07/11 EF

Working with code written by Tod Lauer and Rob Seaman of NOAO, we have developed a system for logging the images taken with Keplercam and FAST automatically. Our code was produced by Ted Groner and Nelson Caldwell. Here are the things you need to know.

Whenever an image is taken,  certain header items are extracted and written to a file with suffix .lis and located in the current data directory (which of course changes at noon each day).  This file is used as input to a program that creates a tex file and a resultant postscript file; however only the rootname.lis file should be edited by the user.

The programs are run under iraf,  the commands below are all iraf commands.  The package  nobs_logging should be loaded by the login.cl file, if not, the program will not work. .

Before taking any data, execute the command initlog.  This will first ask a question as to the instrument being used. (ech, fast, 4sh etc.)  Next it will bring up an iraf parameter file, looking like this (for the 48"):

(startpa=                    1) Starting page number
(date   =             05/07/99) UT date, mm/dd/yy   [Please verify]
(observe=           N Caldwell) Observers' names 
(detname=                  4sh) 1sh or 4sh
(remarks=          Ellipticals) Program title or remarks
(binning=                  2x2) Binning (2x2?)
(mode   =                    m)

Edit this parameter file the way you would edit any iraf parameter file, exiting with Ctrl-D.  Make sure the date is correct.  You may wish to make the starting page number different from 1 (for instance for the voluminous FAST data which is kept in books).

This command does a number of things,  such as create a file called .kpccdlog, in the home (~) directory, that lets the program know that logging is on, and what the instrument is. You don't need to know the other things.

Now, if you take an image of any kind, several things happen.  First, the file rootname.lis (fastlog.lis, echlog.lis or ccdlog.lis on the Ridge) is created in the data directory and contains information on the first image.  This file looks like this for 4shooter data:
0086.RU149 7:24:15 -0:32:55 2000 BH 6  3:06   3:16 1.81 5235 21 " "

and like this for FAST data:
0187.BIAS 0 13:22 06:16:39.0 31:30:00 300 90 3.0 "\#57 Velocity S" " " " "

The items will become clear if you now type the iraf command viewlog, which creates a tex file (rootname.tex) and a postscript file (rootname.ps) also in the data directory, and displays the postscript file using ghostview.  4shooter logs display the image name, RA, Dec, Epoch, filter, exptime, UT start, HA, Airmass, Focus, guide segment and comments. FAST logs display the name, exposure time, UT, RA, Dec, grating, position angle, slit size, program ID, and two blank areas for the binning, and comments. Other instruments have different formats.

The comments do not at present come from the "comment" command executed in the telshell. Rather, if you wish to add a comment to this log, you must use the command remark filename . This will take you into an parameter file editing session, showing you all of the items extracted from the header. You can edit these as usual, ending by CTRL-D. However, some parameters are protected (you can change them here, but the changes won't show up in the .lis file). These are the filename, RA, Dec, exposure time - all items that should be correct, that is don't originate in your typing something in. Mainly, you can add comments, change the PA, slit, and binning. remark does not presently work on the 48" or the MMT.

remark alone will edit the most recent entry. Otherwise, you have to enter the whole filename (sans ".fits") to edit the entry.

You may also edit the .lis file. HOWEVER, if the format isn't kept exactly right, an error will result. Place any comments between each pair of double quotes. Make sure that you do NOT have a newline at the end of the last line (otherwise, viewlog will hang).

Long lines are allowed in comments (the font size is decreased accordingly).  Now if you run viewlog again, the comment will appear in the proper place.

The rootname.ps file is also recreated after each new image is taken.

Typically, one would check the log throughout the night, using viewlog, and then print the log at the end of the night, using printlog.  You can also merely issue xpp rootname.ps, if you like.

Here are examples of successful log pages for the 4shooter and for FAST .  Note that the rootname.lis file was edited to combine the listings for the flat field exposures, thus saving some space.  This must be done by editing the .lis with an editor (not remark ).

Problems in the output are usually due to problems with the rootname.lis file.  If your output has extra spaces, or missing lines, check the rootname.lis file and correct any mistakes.  The items are delimited by spaces, so extra spaces create problems.  As an example, if you want to replace the filter name HA with Halpha (using greek), you would change HA to H$\alpha$, in the rootname.lis file, being careful not to put an extra space.  Sometimes it's best to edit the .tex file, but then you have to be careful with the tex command (not latex).

Other things to watch out for: