IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Jun 10, 2008, 8:46:59 AM (18 years ago)
Author:
bills
Message:

Resolve log file and redirect output in scripts not in tasks

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/ippTasks/detrend.resid.pro

    r17699 r18048  
    55# test for required global variables
    66check.globals
    7 
    8 $LOGSUBDIR = $LOGDIR/detrend
    9 exec mkdir -p $LOGSUBDIR
    107
    118book init detPendingResidImfile
     
    6865
    6966  stdout NULL
    70   stderr $LOGSUBDIR/detresid.log
     67  stderr $LOGDIR/detresid.load.log
    7168
    7269  task.exec
     
    145142    sprintf outroot "%s/%s.%s.%s/%s/%s.detresid.%s.%s" $WORKDIR $CAMERA $DET_TYPE $DET_ID $EXP_TAG $EXP_TAG $DET_ID $ITERATION
    146143
    147     ## generate output log based on filerule (convert the URI to a PATH)
    148     $logfile = `ipp_filename.pl --touch --filerule LOG.IMFILE --camera $CAMERA --class_id $CLASS_ID --basename $outroot`
    149     if ("$logfile" == "")
    150       echo "WARNING: logfile not defined in detrend.resid.pro:161"
    151       break
    152     end
    153 
    154     stdout $logfile
    155     stderr $logfile
    156     dirname $logfile -var outpath
    157     mkdir $outpath
    158 
    159     $run = detrend_resid.pl --det_id $DET_ID --iteration $ITERATION --exp_id $EXP_ID --exp_tag $EXP_TAG --class_id $CLASS_ID --det_type $DET_TYPE --detrend $DET_URI --input_uri $URI --camera $CAMERA --mode $MODE --outroot $outroot
     144    stdout $LOGDIR/detresid.run.log
     145    stderr $LOGDIR/detresid.run.log
     146
     147    $run = detrend_resid.pl --det_id $DET_ID --iteration $ITERATION --exp_id $EXP_ID --exp_tag $EXP_TAG --class_id $CLASS_ID --det_type $DET_TYPE --detrend $DET_URI --input_uri $URI --camera $CAMERA --mode $MODE --outroot $outroot --redirect-output
    160148    if ("$REDUCTION" != "NULL")
    161149      $run = $run --reduction $REDUCTION
     
    197185
    198186  stdout NULL
    199   stderr $LOGSUBDIR/detresid.exp.log
     187  stderr $LOGDIR/detresid.exp.load.log
    200188
    201189  task.exec
     
    271259    sprintf outroot "%s/%s.%s.%s/%s/%s.detresid.%s.%s" $WORKDIR $CAMERA $DET_TYPE $DET_ID $EXP_TAG $EXP_TAG $DET_ID $ITERATION
    272260
    273     ## generate output log based on filerule (convert the URI to a PATH)
    274     $logfile = `ipp_filename.pl --touch --filerule LOG.IMFILE --camera $CAMERA --class_id NONE --basename $outroot`
    275     if ("$logfile" == "")
    276       echo "WARNING: logfile not defined in detrend.process.pro:285"
    277       break
    278     end
    279 
    280     stdout $logfile
    281     stderr $logfile
    282     dirname $logfile -var outpath
    283     mkdir $outpath
    284 
    285     $run = detrend_reject_imfile.pl --det_id $DET_ID --iteration $ITERATION --exp_id $EXP_ID --exp_tag $EXP_TAG --det_type $DET_TYPE --camera $CAMERA --outroot $outroot
     261    stdout $LOGDIR/detresid.exp.run.log
     262    stderr $LOGDIR/detresid.exp.run.log
     263
     264    $run = detrend_reject_imfile.pl --det_id $DET_ID --iteration $ITERATION --exp_id $EXP_ID --exp_tag $EXP_TAG --det_type $DET_TYPE --camera $CAMERA --outroot $outroot --redirect-output
    286265    add_standard_args run
    287266
Note: See TracChangeset for help on using the changeset viewer.