#! /bin/sh eval ' exec perl -x $0 ${1+"$@"} ' #! perl # ----------------------------------------------------------------------------- # Name: ima_pick # Purpose: Extract results from ISGRI IMA and save in ASCII files # Author: Mark.Gaber@obs.unige.ch, Ada.Paizis@obs.unige.ch # Version: 1.03 # # Description: # Invoke: Please see the pod EXAMPLES section at the end of this file. # Revisions: Please see the pod HISTORY section at the end of this file. #------------------------------------------------------------------------------ use File::Basename; # for basename #------------------------------------------------------------------------------ # Initializations #1 #------------------------------------------------------------------------------ my $launchCmd = "$0 @ARGV"; my $FUNCNAME = basename($0); my $FUNCDIR = &dirRelative2Absolute(dirname $0); my $FUNCVERSION = &getVersion($0); my $FUNCNAMEFULL = $FUNCDIR."/".$FUNCNAME; (my $FUNCNAME_NS = $FUNCNAME) =~ s/(.*)(\..*)/$1/; # _NS means no suffix $DBASE_RES_DIR = ""; #------------------------------------------------------------------------------ # Preparing for SYSTEM LOG file #------------------------------------------------------------------------------ $LOGPRINTSYS = $FUNCDIR."/".$FUNCNAME_NS."_sys.log"; open(FH_LOGPRINTSYS, ">>$LOGPRINTSYS") or die "\nERROR: Could not open logfile:\n" ." logfile: + $LOGPRINTSYS +\n" ." user: + $ENV{USER} +\n" ." Possibly due to privileges or disk space. Aborting ...\n\n"; $FH_LOGPRINT = "FH_LOGPRINTSYS"; &logPrint(LOG, 1, "$FUNCNAME $FUNCVERSION ------------- BEG -----------"); &logPrint(LOG, 1, ""); #------------------------------------------------------------------------------ # Command line argument processing. #------------------------------------------------------------------------------ while ($_ = $ARGV[0]) { if ($_ eq "-h" || $_ eq "--h" || $_ eq "--help") { &printUsage; exit 0; } elsif ($_ eq "-v" || $_ eq "--v" || $_ eq "--version") { print "Log_1 : Version : $FUNCNAME $FUNCVERSION\n"; exit 0; } elsif (/^--dbase_res_dir$/i) { shift @ARGV; $DBASE_RES_DIR = $ARGV[0]; } else { # all other cases print "ERROR: unrecognized option +$ARGV[0]+. Aborting...\n"; print "\n"; exit 2; } shift @ARGV; } # while options left on the command line #------------------------------------------------------------------------------ # Validation of the inputs. #------------------------------------------------------------------------------ $errMsg = ""; if ("" eq $DBASE_RES_DIR) { $errMsg = $errMsg ."ERROR: the --dbase_res_dir given was empty. Aborting...\n" ." your value was: $DBASE_RES_DIR\n" ."\n" ; # closing semi-colon } # elsif (-d $DBASE_RES_DIR) { # $errMsg = $errMsg # ."ERROR: --dbase_res_dir exists! Being safe: exiting.\n" # ." your value was: $DBASE_RES_DIR\n" # ."\n" # ; # closing semi-colon elsif (-d $DBASE_RES_DIR) { $errMsg = ""; } else { # We create the directory since it was absent. &runCmd ("mkdir $DBASE_RES_DIR", # !! may be a relative path !! "mkdir of DBASE_RES_DIR", "0"); } # Finally, print error message if any (and exit). if ($errMsg ne "") { print $errMsg ."\n" ."Use -h for more info. Aborting...\n\n"; exit 2; } #------------------------------------------------------------------------------ # Preparing for LOG file #------------------------------------------------------------------------------ $LOGPRINT = $DBASE_RES_DIR."/".$FUNCNAME_NS.".log"; open(FH_LOGPRINT, ">>$LOGPRINT") or die "\nERROR: Could not open logfile:\n" ." logfile: + $LOGPRINT +\n" ." user: + $ENV{USER} +\n" ." Possibly due to privileges or disk space. Aborting ...\n\n"; $FH_LOGPRINT = "FH_LOGPRINT"; &logPrint(LOG, 1, "$FUNCNAME $FUNCVERSION ------------- BEG -----------"); &logPrint(LOG, 1, ""); #------------------------------------------------------------------------------ # Initializations #------------------------------------------------------------------------------ # @skyResFileList = `ls -1 /unsaved_data/scratch2/paizis/LMgroup/obs/0049*/scw/*/isgri_sky_res.fits.gz`; @skyResFileList = `ls -1 \$REP_BASE_PROD/obs/0*0/scw/*/isgri_sky_res.fits.gz`; chomp(@skyResFileList); $SRC_NLENGTH = "20"; # Max length of source name in fits file. # enList (energy band list) is the data structure number of each energy band. push(@enList, "2"); push(@enList, "3"); push(@enList, "4"); #------------------------------------------------------------------------------ # Collect source info. #------------------------------------------------------------------------------ foreach $skyResFile (@skyResFileList) { print "$skyResFile\n"; undef %srcInfo; $strCmdTSTART ="fkeyprint $skyResFile+2 \"TSTART\" exact=yes | tail -1 | awk \'{print \$3}\'"; chomp ($TSTART = `$strCmdTSTART`); $strCmdTSTOP ="fkeyprint $skyResFile+2 \"TSTOP\" exact=yes | tail -1 | awk \'{print \$3}\'"; chomp ($TSTOP = `$strCmdTSTOP`); $strCmdEXPO ="fkeyprint $skyResFile+2 \"EXPOSURE\" exact=yes | tail -1 | awk \'{print \$2}\'"; chomp ($EXPO = `$strCmdEXPO`); $strCmdSWID ="fkeyprint $skyResFile+2 \"SWID\" exact=yes | tail -1 | awk \'{print \$3}\'"; chomp ($SWID = `$strCmdSWID`); $SWID =~ s/\'//g; # remove quotes (otherwise end up with '005100950010') for $en (@enList) { $strCmd ="fdump $skyResFile+$en STDOUT \"NAME FLUX FLUX_ERR DETSIG RA_FIN DEC_FIN\" - prhead=no page=no showcol=no showunit=no showrow=n pagewidth=256"; @enInfoAll =`$strCmd`; # TBD: check for exit status of fdump for $enInfoLine (@enInfoAll) { chomp $enInfoLine; next if ($enInfoLine =~ m/^\s*$/); # skip {0,n} whitespace lines $srcName = substr($enInfoLine, 0, $SRC_NLENGTH); $enInfoRemStr = substr($enInfoLine, $SRC_NLENGTH+1); #REMainder of string $enInfoRemStr =~ s/ INDEF / -1.0 /; @enInfoRem = split(" ",$enInfoRemStr); $srcInfo{"$srcName"}{"$en"}{"FLUX" } = $enInfoRem[0]; $srcInfo{"$srcName"}{"$en"}{"FLUX_ERR"} = $enInfoRem[1]; $srcInfo{"$srcName"}{"$en"}{"DETSIG" } = $enInfoRem[2]; $srcInfo{"$srcName"}{"$en"}{"RA_FIN" } = $enInfoRem[3]; $srcInfo{"$srcName"}{"$en"}{"DEC_FIN" } = $enInfoRem[4]; if (0) { print "en +$en+\n"; print "strCmd +$strCmd+\n"; print "enInfoLine +$enInfoLine+\n"; print "srcName +$srcName+\n"; print "enInfoRemStr +$enInfoRemStr+\n"; print "srcInfo FLUX +".$srcInfo{"$srcName"}{"$en"}{"FLUX"}."+\n"; print "srcInfo ERRO +".$srcInfo{"$srcName"}{"$en"}{"FLUX_ERR"}."+\n"; print "srcInfo DETS +".$srcInfo{"$srcName"}{"$en"}{"DETSIG"}."+\n"; print "srcInfo RA +".$srcInfo{"$srcName"}{"$en"}{"RA_FIN"}."+\n"; print "srcInfo DEC +".$srcInfo{"$srcName"}{"$en"}{"DEC_FIN"}."+\n"; print "enInfoRem +@enInfoRem+\n"; print "\n"; } # endif print info } # next Line of All } # next en of enList #------------------------------------------------------------------------------ # Print source info to appropriate file. #------------------------------------------------------------------------------ chdir $DBASE_RES_DIR; for $srcName (keys %srcInfo) { ($srcNameNB = $srcName) =~ s/ //g; # ($srcNameNB = $srcName) =~ s/ /_/g; # $srcNameNB =~ s/_*$//g; $fileSrc = "isgri_".$srcNameNB.".dat"; open(FH_SRC, ">>$fileSrc"); for $en (@enList) { if ("" eq $srcInfo{"$srcName"}{"$en"}{"FLUX"}) { $srcInfo{"$srcName"}{"$en"}{"FLUX"} = 0.0; } # endif empty if ("" eq $srcInfo{"$srcName"}{"$en"}{"FLUX_ERR"}) { $srcInfo{"$srcName"}{"$en"}{"FLUX_ERR"} = 0.0; } # endif empty if ("" eq $srcInfo{"$srcName"}{"$en"}{"DETSIG"}) { $srcInfo{"$srcName"}{"$en"}{"DETSIG"} = 0.0; } # endif empty if ("" eq $srcInfo{"$srcName"}{"$en"}{"RA_FIN"}) { $srcInfo{"$srcName"}{"$en"}{"RA_FIN"} = 0.0; } # endif empty if ("" eq $srcInfo{"$srcName"}{"$en"}{"DEC_FIN"}) { $srcInfo{"$srcName"}{"$en"}{"DEC_FIN"} = 0.0; } # endif empty } # next en printf(FH_SRC "%-20s %8.3f %8.3f %8.3f " , $SWID , $TSTART , $TSTOP , $EXPO ); # closing semicolon for $en (@enList) { printf(FH_SRC "%8.3f %8.3f %8.3f %8.3f %8.3f" , $srcInfo{"$srcName"}{"$en"}{"FLUX"} , $srcInfo{"$srcName"}{"$en"}{"FLUX_ERR"} , $srcInfo{"$srcName"}{"$en"}{"DETSIG"} , $srcInfo{"$srcName"}{"$en"}{"RA_FIN"} , $srcInfo{"$srcName"}{"$en"}{"DEC_FIN"} ); # closing semicolon } # next en print FH_SRC "\n"; close(FH_SRC); if (0) { print "srcName hash +$srcName+\n"; print "fileSrc +$fileSrc+\n"; print "strInfo +$strInfo+\n"; print "\n"; } # endif print } # next key # print"09 skyResFile + $skyResFile +\n"; } # end foreach skyResFile # print"10 skyResFile + $skyResFile +\n"; #------------------------------------------------------------------------------ # Closing the log file. #------------------------------------------------------------------------------ &printState; &logPrint(LOG, 1, ""); &logPrint(LOG, 1, "------------------------------ END -----------"); &logPrint(LOG, 1, ""); &logPrint(LOG, 1, ""); close FH_LOGPRINT; &logPrint(LOG, 1, "","FH_LOGPRINTSYS"); &logPrint(LOG, 1, "------------------------------ END -----------","FH_LOGPRINTSYS"); &logPrint(LOG, 1, "","FH_LOGPRINTSYS"); &logPrint(LOG, 1, "","FH_LOGPRINTSYS"); close FH_LOGPRINTSYS; exit 0; #============================================================================== #============================================================================== #============================================================================== #============================================================================== #============================================================================== #===================== End of Main ========================== #============================================================================== #============================================================================== #============================================================================== #============================================================================== #============================================================================== #------------------------------------------------------------------------------ # Function #------------------------------------------------------------------------------ sub printUsage(){ if ("" eq $ENV{PAGER}) { $ENV{PAGER} = "less -i"; } system("pod2man $FUNCNAMEFULL | nroff -man| $ENV{PAGER}"); } #------------------------------------------------------------------------------ # Function #------------------------------------------------------------------------------ sub printState () { # Build the string containing the state. It will be output to the screen and # to the log file. $strState = "State of key variables:\n" . "\n" . "About this function:\n" . " launchCmd + $launchCmd +\n" . " FUNCDIR + $FUNCDIR +\n" . " FUNCNAME + $FUNCNAME +\n" . " FUNCNAME_NS + $FUNCNAME_NS +\n" . " FUNCNAMEFULL + $FUNCNAMEFULL +\n" . " LOGPRINT + $LOGPRINT +\n" . "\n" . "Version numbers:\n" . " FUNCVERSION + $FUNCVERSION +\n" . "\n" . "Key environment variables:\n" . " ENV{HOST} + $ENV{HOST} +\n" . "\n" . "Key variables:\n" . " #skyResFileList + $#skyResFileList +\n" . " skyResFile + $skyResFile +\n" . " TSTART + $TSTART +\n" . " TSTOP + $TSTOP +\n" . " EXPOSURE + $EXPO +\n" . " SWID + $SWID +\n" . " enList (whole table) + @enList +\n" . " enList[0] + $enList[0] +\n" . " enList[1] + $enList[1] +\n" . " enList[2] + $enList[2] +\n" . "\n" ; # ending semicolon print "\n$strState\n"; # to screen &logPrint(LOG, 1, ""); &logPrint(LOG, 1, "$strState"); # to logfile } #------------------------------------------------------------------------------ # Function #------------------------------------------------------------------------------ sub runCmd () { local $cmd = $_[0]; local $name = $_[1]; # Description of what is done for the log file local $eRes = $_[2]; # eRes = expected result local $out; &logPrint(LOG, 1, "Command is + $cmd +"); $out = `$cmd`; $res = $?/256; chomp $out; if ($eRes != $res) { $msgStr = "Bad exit value for $name. Aborting ...\n" ."out + $out +" ."res + $res +" ."" ; # closing semicolon &logPrint(ERROR, 1, "\n$msgStr"); exit 1; # eg abort } else { &logPrint(LOG, 1, "Screen out for $name: + $out +"); &logPrint(LOG, 1, "Exit value for $name: + $res +"); &logPrint(LOG, 1, ""); } } # end of function #------------------------------------------------------------------------------ # Function #------------------------------------------------------------------------------ #sub runCmd () { #} # end of function #============================================================================== #============================================================================== #============================================================================== #============================================================================== # Below are functions copied from ~isdc_cms/icms/scripts/isdc.pm-1.2.1. #============================================================================== #============================================================================== #============================================================================== #============================================================================== #------------------------------------------------------------------------------ # Function #------------------------------------------------------------------------------ sub logPrint() { # This function is not ready for general distribution (MG 2002-02-01). # The file to which log print writes is controlled by the caller. Here are # the different ways the file can be specified. The first match is the one # used: # 1. The 4th argument contains an array of filehandle names # 2. The 4th argument contains a name of a filehandle (eg,"LOGFILE") # 3. The variable $FH_LOGPRINT contains a name of a filehandle (eg,"LOGFILE") # 4. The filehandle LOGFILE is open # # Notice that in all cases, it is up to the user to do open a filehandle. # If this has not been done, the print will not return a success; this is # checked for and will result in a warning message being output to STDOUT # after which the function returns (it is not considered a fatal error so # it does not exit). # # EXAMPLES: =start open(LOGFILE, ">>zzlogfile.log\n"); open(FH_1, ">>zzFH_1.log\n"); open(FH_2, ">>zzFH_2.log\n"); push(@FH_ARRAY, "FH_1"); push(@FH_ARRAY, "FH_2"); &logPrint(LOG,1,"message will be in zzlogfile.log"); &logPrint(LOG,1,"message will still be in zzlogfile.log"); &logPrint(LOG,1,"message will now be in zzFH_1.log", FH_1); &logPrint(LOG,1,"message will be in zzlogfile.log"); $FH_LOGPRINT = "FH_2"; &logPrint(LOG,1,"message will now be in zzFH_2.log"); &logPrint(LOG,1,"message will be in both zzFH_1 and zzFH_2", \@FH_ARRAY); =cut # The four approaches have different advantages: # - use LOGFILE when it is the only file to which you are logging # - specify the filehandle in the call when often switching file to which # you are logging # - use the $FH_LOGPRINT= assignment when loggiing to different files, but # without frequent switching. # - specify an array when you want to log the same message to several files # using just one Perl statement. my $type = $_[0]; my $level = $_[1]; my $msg = $_[2]; my $fhStr = $_[3]; my $typeStr; my @fhArray; # print "INSIDE ".(caller(0))[3]." About to print\n"; $typeStr = ""; if ($type eq "LOG") { $typeStr = "Log\_$level "; } elsif ($type eq "WARN") { $typeStr = "Warn\_$level "; } elsif ($type eq "ERROR") { $typeStr = "Error\_$level"; } else { print "Invalid type $type",(caller(0))[3]."\n"; exit 3; } if (defined $fhStr) { # print "Arg 4 is defined\n"; if (ref($fhStr) eq 'ARRAY') { # see Perl Cookbook Recipe 10.5 @fhArray = @{$fhStr}; } else { push(@fhArray,$fhStr); } } elsif (defined $FH_LOGPRINT) { # print "dollar FH_LOGPRINT is defined\n"; push(@fhArray,$FH_LOGPRINT); } else { # print "LOGFILE will be used\n"; push(@fhArray,"LOGFILE"); } if ($msg eq "") { $typTimMsg = ""; # eg. print blank line (no type, no time, no nothing) } else { $timeISO8601 = &getTimeISO8601(); $typTimMsg = "$typeStr $timeISO8601: $msg"; } # This is the actual (attempt to) print. foreach $FH (@fhArray) { $sts = print $FH "$typTimMsg\n"; # Check to see if the print attempt succeeded. if (1 != $sts) { print "" ."\n" ."$timeISO8601 WARNING! ".(caller(0))[3]." failed to log message:\n" ."\n" ." + $typTimMsg +\n" ."\n" ." A possible cause is that it does not know where to print \n" ." because no filehandle was specified in the call to this function\n" ." AND filehandle LOGFILE has not been opened. Here are the internal\n" ." variables at the time of the failure:\n" ."\n" ." fhStr (4th arg) + $fhStr +\n" ." fhArray + @fhArray +\n" ." FH + $FH +\n" ." FH_LOGPRINT + $FH_LOGPRINT +\n" ." sts (of print) + $sts + (1=good not1=fail)\n" ." \n" ." Continuing, but the code should be corrected.\n" ." \n" ; # closing semi-colon } } # next filehandle } #------------------------------------------------------------------------------ # Function #------------------------------------------------------------------------------ sub getTimeISO8601() { # Subroutine to convert time from sec since Epoch to the ISO 8601 format. # Inputs: (optional) num sec since epoch (default is seconds for time now) # Outputs: $timeISO8601 (eg. 2004-07-27T10:06:47) # This function corrects the Y2K bug (eg adds 1900 to convert from 2 digit # to a proper 4-digit value). local $timeSec = $_[0]; # print "INSIDE ".(caller(0))[3]." timeSec +$timeSec+\n"; # If no input was provided, the current time will be used. if ("" eq $timeSec) { $timeSec = time; } # Get the time in the tm format ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst)=localtime($timeSec); $year = $year + 1900; # Y2K correction $mon_p_1 = $mon + 1; # renumber months [1,12]; previously [0,11] # Add leading 0 if single digit if ($sec <= 9) {substr($sec , 0, 0) = "0";} if ($min <= 9) {substr($min , 0, 0) = "0";} if ($hour <= 9) {substr($hour , 0, 0) = "0";} if ($mday <= 9) {substr($mday , 0, 0) = "0";} if ($mon_p_1 <= 9) {substr($mon_p_1, 0, 0) = "0";} $timeStr = "$year-$mon_p_1-$mday\T$hour:$min:$sec"; return $timeStr; } #------------------------------------------------------------------------------ # Function #------------------------------------------------------------------------------ sub getVersion { my $file = $_[0]; my $fileVersion = ""; if (! -r $file) { chomp ($pwdRes = `pwd`); print "ERROR in getVersion: could not read the following file:\n" ."file + $file +.\n" ."pwdRes + $pwdRes +\n" ."Aborting ...\n\n"; exit 3; } chomp ($fileVersion = `grep Version: $file| \\ head -1|sed s/Version:// |sed s/\#//|sed s/\\ //g`); return $fileVersion; } #------------------------------------------------------------------------------ # Function #------------------------------------------------------------------------------ sub dirRelative2Absolute(){ # converts a dirname from relative to absolute. # input: .. from cwd = /home/isdc/gaber/WWW/pdb/0.7 # output: /home/isdc/gaber/WWW/pdb local($dirCwd); local($dirAbsolute); local($dirRelative); chomp ($dirRelative = $_[0]); chomp ($dirCwd = `\pwd`); # print "cwd at beg of 2cvt: $dirCwd\n"; chdir $dirRelative; chomp ($dirAbsolute = `pwd`); chdir $dirCwd; # chomp ($dirCwd = `\pwd`); # print "cwd at exit of 2cvt: $dirCwd\n"; return $dirAbsolute; } __END__ #last line =cut =head1 NAME ima_pick.pl =head1 USAGE ima_pick.pl --dbase_res_dir ./RESULTS =head1 DESCRIPTION This script will extract the results from the ISGRI IMA analysis and save them in an $dbase_res_dir/isgri.source.dat ASCII file. The location of the data is hardcoded in the script as @skyResFileList = `ls -1 /THE-RIGHT-PATH/isgri_sky_res.fits.gz`; and might need to be personalized for your needs. Each ASCII file is for one source and it contains the results of the science window by science window imaging step. In detail: COLUMN | TYPE | DESCRIPTION ------------------------------------------------------------------- 1 SCWID Science Window identifier 2 TSTART Start time of the Science Window (IJD) 3 TSTOP End time of the Science Window (IJD) 4 EXPOSURE Effective exposure time (sec) 5 FLUX 1 Detected flux in en. band 1 6 ERROR_FLUX 1 Detected flux error in en.band 1 7 DETSIG 1 Detection significance in en. band 1 8 RA_FIN 1 Detected source RA in en. band 1 9 DEC_FIN 1 Detected source DEC in en. band 1 10 FLUX 2 Detected flux in en. band 2 11 ERROR_FLUX 2 Detected flux error in en.band 2 12 DETSIG 2 Detection significance in en. band 2 13 RA_FIN 2 Detected source RA in en. band 2 14 DEC_FIN 2 Detected source DEC in en. band 2 [...] This version assumes that at least 3 energy bands have been analysed (extentions 2, 3, 4 of isgri_sky_res.fits.gz ). This can be modified changing the part in the code that looks like: # enList (energy band list) is the data structure number of each energy band. push(@enList, "2"); push(@enList, "3"); push(@enList, "4"); Multilple runs with same directory name will append the results the already existing ASCII files. This is useful for large data bases for whch shell commands like ls -l might fail. =head1 WORK STILL TO BE DONE - A more user friendly formating of the output. Possibly a title. - Include ANGLE - Investigate why the skyResFile is "forgotten" when the skyResFileList foreach is completed. =head2 Limitations: 1. There is no way to distinguish between the case of the source in the FOV but not detected and source not in the FOV. =head1 OPTIONS --help --h -h Print this info --version --v -v Print out version info =head1 RETURN VALUE 0 - Normal termination 1 - System error (eg. mkdir of --dbase_res_dir failed) 2 - user error (eg. no --dbase_res_dir specified) 3 - coding anomaly detected (please notify the author) =head1 EXAMPLES 1. To get help: ima_pick.pl --help 2. to save the results under a ./RESULTS directory ima_pick.pl --dbase_res_dir ./RESULTS =head1 ENVIRONMENT This tool sets the following environment variables which are used by the executables that are under its control: $DBASE_RES_DIR set to the value --dbase_res_dir received in the required arguments. =head1 BUGS None known at this time. =head1 SEE ALSO =head1 AUTHOR Mark Gaber mark.gaber@obs.unige.ch Ada Paizis ada.paizis@obs.unige.ch =head1 HISTORY 05 Oct 2005 Mark Gaber 1.03 - Removed the -I/home/isdc/isdc_cms/icms/scripts in the hash bang line (line 3) as it this script is now completely self-sufficient. - Replaced \$HOME in a sh call with $ENV{HOME} to be consistent with the rest of the code in the way to specify environment variables. - Introduced a check to see if the $PAGER environment variable is set in the pod2man call (it was causing a funny "sh: -c: line 2: syntax error: unexpected end of file" error when not set). 19 Aug 2005 Ada Paizis 1.02 - Minor changes in documentation part. Increased description. - Allowed to run multiple times with same directory name to append the results. This is useful for large data bases for which "ls -1" fails. 14 Jul 2005 Ada Paizis 1.01 - Included RA_FIN and DEC_FIN 14 Jul 2005 Ada Paizis 1.00 - Corrected HISTORY and WORK STILL TO BE DONE. 05 Jul 2005 Mark Gaber 0.07 - Simplified the calculation of @skyResFileList - Restored the print of the skyResFile being treated (it was unintentionally removed in version 0.08. - Introduced leading space in pod HISTORY section. This helps to preserve line feeds 14 Jul 2005 Mark Gaber 0.08 - Fixed initialization bug by putting in undef %srcInfo - Fixed accumulation bug by taking push enList out of foreach skyResFile loop 05 Jul 2005 Mark Gaber 0.07 - Switched from triplet string (FLUX, FLUX_ERR,DETSIG) to array 05 Jul 2005 Ada Paizis 0.06 - Included the SCW loop. 05 Jul 2005 Ada Paizis 0.05 - Extraction of TSTART (instead of TFIRST), TSTOP, EXPOSURE, SWID 05 Jul 2005 Ada Paizis 0.04 - The log file was put to $dbase_res_dir. - Update of the documentation part 04 Jul 2005 Mark Gaber 0.03 - Still in early development - many mods. 04 Jul 2005 Mark Gaber 0.02 - Still in early development - many mods. 04 Jul 2005 Mark Gaber 0.01 - initial creation following a version 0.00 by Simon Shaw