onlinesdfits responsible for filling all DCR, Spectral Processor, and Spectrometer data into Sdfits files. This filling happens at the end of each successfull scan.
onlinesdfits is to provide the GBTIDL program access to current data, and provide the user with a quasi real-time display and data reduction environment. This is the reason why Index and Flag files are created. GBTIDL users cannot modify their FITS or Index files, but they can write to the Flag file, and thus are able to use all the flagging functionality in GBTIDL.
As GBTIDL evolves, the onlinesdfits filler will also have to adapt to meet GBTIDL's needs.
onlinesdfits
onlinesdfits, that point to this directory.
onlinesdfits is a state engine that is capable of detecting scan transitions (when they begin and end), project transitions, and backends selected in the Scan Coordinator. When the end of a scan is detected, the sdfits program is called, via a system call, filling in the scan that just ended, as well as any scans that it may have missed while it was filling previous scans. A system call is used to avoid a memory leak in sdfits, which has since been fixed. This approach needs to be refactored to improve performance.
The state engine, communicating with M&C with Grail, provides the information needed to construct a command string for the sdfits program. This includes the current project, current scan, and backend used. The command used in the system call takes this form:
sdfits /home/gbtdata/project -backends=backend -scans=scan -append -debug /home/sdfits/project > /home/sdfits/sdfitsLog.txtIn addition to appending to an sdfits file to /home/sdfits, both an index file (for spectral line scans only) and a log file are updated at the end of each scan. When an sdfits file is first created, a symbolic link is created in /home/sdfits pointing to a blank GBTIDL flagging file created in /home/sdfits-flags. A lock file is also created and destroyed while the system call is blocking in /home/sdfits-locks. More on this below.
sdfits application.
sdfits, backups are made before each new scan is filled. If the scan is not succesfully filled, the backup is copied back over to the original file. These backups all are labeled the same as above, except with the *.backup extension.
sdfits, it creates a link in /home/sdfits to an empty flag file, also created by sdfits in /home/sdfits-flags. This step is necessary so that GBTIDL users can modify the blank flag file (set a flag, for example), which they have permission to since it is in /home/sdfits-flags as opposed to /home/sdfits. Like the Index File, GBTIDL also contains code for producing flag files, and the maintanence of two pieces of code for producing the same product is troublesome.
onlinesdfits is ready to fill the latest scan, but there exists a project.lock file, it will wait until this lock file is removed before proceeding. There is a time-out period for this waiting, whereupon an excpetion will be raised and onlinesdfits will terminate.
This lock file can be used by any consumer of the FITS file in /home/sdfits, to know when the FITS file is in the process of being written to. The GBTIDL program formerly interacted with onlinesdfits through this lock file, but that practice has been terminated; the use of this lock file with onlinesdfits remains, however.
sdfits, the results of the call are appended as a line to this file (ex: Wed Apr 12 20:59:23 2006 : Scan(s) 13, Backend: dcr written.)
onlinesdfits maintain a log file. This log file is timestamped, and can be found in /home/gbt/etc/log/datacapture. It contains all the stdout from the process, which, in this case, includes basic info regarding the state engine, as well as all the output from each sdfits call (this is why the -debug flag is used).
gbtstatus so you can find out the project name and latest scan number.
sdfits program, try to replicate them by filling the same scan(s) by hand. If you get the same error messages, then the problem does not lie with onlinesdfits, but with sdfits and/or the data that is being taken.
onlinesdfits, like a stale lock file that needs to be removed, that info should reside here.
onlinesdfits, and waiting to see if it fills the next scan is all thats needed. To restart it, you can either ask the operator to do this (which they should be able to do easily), or you can:
| Topic OnlineSdfitsDesign . { Edit | Attach | Ref-By | Printable | Diffs | r1.4 | > | r1.3 | > | r1.2 | More } |
|
Revision r1.4 - 28 Apr 2008 - 20:36 GMT - AmyShelton Parents: Sdfits |
Content copyright © 1999-2007 by the contributing authors. All material on this collaboration platform is the property of the contributing authors. |