IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 12368


Ignore:
Timestamp:
Mar 8, 2007, 5:41:36 PM (19 years ago)
Author:
Paul Price
Message:

Fixing up workdir, so that operations go into the current directory if workdir is NULL

Location:
trunk/ippTasks
Files:
10 edited

Legend:

Unmodified
Added
Removed
  • trunk/ippTasks/camera.pro

    r12240 r12368  
    132132
    133133    # output log from filerule
    134     $outroot = `ipp_datapath.pl $WORKDIR`
     134    if ($WORKDIR == NULL)
     135      $outroot = `pwd`
     136    else
     137      $outroot = `ipp_datapath.pl $WORKDIR`
     138    end
    135139    $outroot = $outroot/$EXP_ID
    136140    $logfile = $outroot/cam.log
     
    144148    # create the command line
    145149    if ($VERBOSE > 1)
    146       echo command camera_exp.pl --exp_id $EXP_ID --cam_id $CAM_ID --camera $CAMERA $ARGS
     150      echo command camera_exp.pl --exp_id $EXP_ID --cam_id $CAM_ID --camera $CAMERA --workdir $outroot $ARGS
    147151    end
    148     command camera_exp.pl --exp_id $EXP_ID --cam_id $CAM_ID --camera $CAMERA $ARGS
     152    command camera_exp.pl --exp_id $EXP_ID --cam_id $CAM_ID --camera $CAMERA --workdir $outroot $ARGS
    149153  end
    150154
  • trunk/ippTasks/chip.pro

    r12224 r12368  
    135135
    136136    ## generate output log based on filerule
    137     $outroot = `ipp_datapath.pl $WORKDIR`
     137    if ($WORKDIR == NULL)
     138      $outroot = `pwd`
     139    else
     140      $outroot = `ipp_datapath.pl $WORKDIR`
     141    end
    138142    $outroot = $outroot/$EXP_ID
    139143    $logfile = $outroot/chip.$CLASS_ID.log
     
    147151    # create the command line
    148152    if ($VERBOSE > 1)
    149       echo command chip_imfile.pl --exp_id $EXP_ID --chip_id $CHIP_ID --class_id $CLASS_ID --uri $URI --camera $CAMERA $ARGS
     153      echo command chip_imfile.pl --exp_id $EXP_ID --chip_id $CHIP_ID --class_id $CLASS_ID --uri $URI --camera $CAMERA --workdir $outroot $ARGS
    150154    end
    151     command chip_imfile.pl --exp_id $EXP_ID --chip_id $CHIP_ID --class_id $CLASS_ID --uri $URI --camera $CAMERA $ARGS
     155    command chip_imfile.pl --exp_id $EXP_ID --chip_id $CHIP_ID --class_id $CLASS_ID --uri $URI --camera $CAMERA --workdir $outroot $ARGS
    152156  end
    153157
  • trunk/ippTasks/detrend.norm.pro

    r12126 r12368  
    164164    end
    165165
    166     # XXX add $WORKDIR/$LOG_DIR
    167     # XXX use ipp_filename.pl to lookup output file names
    168     $outroot = `ipp_datapath.pl $WORKDIR`
     166    if ($WORKDIR == NULL)
     167      $outroot = `pwd`
     168    else
     169      $outroot = `ipp_datapath.pl $WORKDIR`
     170    end
    169171    $outroot = $outroot/$CAMERA.$DET_TYPE.$DET_ID
    170172    $logfile = $outroot/norm.$DET_ID.$ITERATION.log
     
    178180    # create example job options as a demonstration
    179181    if ($VERBOSE > 1)
    180       echo command detrend_norm_calc.pl --det_id $DET_ID --iteration $ITERATION --det_type $DET_TYPE $ARGS
    181     end
    182     command detrend_norm_calc.pl --det_id $DET_ID --iteration $ITERATION --det_type $DET_TYPE $ARGS
     182      echo command detrend_norm_calc.pl --det_id $DET_ID --iteration $ITERATION --det_type $DET_TYPE --workdir $outroot $ARGS
     183    end
     184    command detrend_norm_calc.pl --det_id $DET_ID --iteration $ITERATION --det_type $DET_TYPE --workdir $outroot $ARGS
    183185  end
    184186
     
    280282
    281283    # XXX use ipp_filename.pl to lookup output file names
    282     $outroot = `ipp_datapath.pl $WORKDIR`
     284    if ($WORKDIR == NULL)
     285      $outroot = `pwd`
     286    else
     287      $outroot = `ipp_datapath.pl $WORKDIR`
     288    end
    283289    $outroot = $outroot/$CAMERA.$DET_TYPE.$DET_ID
    284290    $logfile = $outroot/norm.$DET_ID.$ITERATION.$CLASS_ID.log
     
    292298    # create example job options as a demonstration
    293299    if ($VERBOSE > 1)
    294       echo command detrend_norm_apply.pl --det_id $DET_ID --iteration $ITERATION --class_id $CLASS_ID --value $NORM --input_uri $URI --camera $CAMERA --det_type $DET_TYPE $ARGS
    295     end
    296     command detrend_norm_apply.pl --det_id $DET_ID --iteration $ITERATION --class_id $CLASS_ID --value $NORM --input_uri $URI --camera $CAMERA --det_type $DET_TYPE $ARGS
     300      echo command detrend_norm_apply.pl --det_id $DET_ID --iteration $ITERATION --class_id $CLASS_ID --value $NORM --input_uri $URI --camera $CAMERA --det_type $DET_TYPE --workdir $outroot $ARGS
     301    end
     302    command detrend_norm_apply.pl --det_id $DET_ID --iteration $ITERATION --class_id $CLASS_ID --value $NORM --input_uri $URI --camera $CAMERA --det_type $DET_TYPE --workdir $outroot $ARGS
    297303  end
    298304
     
    391397
    392398    # XXX add $WORKDIR/$LOG_DIR
    393     $outroot = `ipp_datapath.pl $WORKDIR`
     399    if ($WORKDIR == NULL)
     400      $outroot = `pwd`
     401    else
     402      $outroot = `ipp_datapath.pl $WORKDIR`
     403    end
    394404    $outroot = $outroot/$CAMERA.$DET_TYPE.$DET_ID
    395405    $logfile = $outroot/norm.$DET_ID.$ITERATION.log
     
    403413    # create example job options as a demonstration
    404414    if ($VERBOSE > 1)
    405       echo command detrend_norm_exp.pl --det_id $DET_ID --iteration $ITERATION --camera $CAMERA --det_type $DET_TYPE $ARGS
    406     end
    407     command detrend_norm_exp.pl --det_id $DET_ID --iteration $ITERATION --camera $CAMERA --det_type $DET_TYPE $ARGS
     415      echo command detrend_norm_exp.pl --det_id $DET_ID --iteration $ITERATION --camera $CAMERA --det_type $DET_TYPE --workdir $outroot $ARGS
     416    end
     417    command detrend_norm_exp.pl --det_id $DET_ID --iteration $ITERATION --camera $CAMERA --det_type $DET_TYPE --workdir $outroot $ARGS
    408418  end
    409419
  • trunk/ippTasks/detrend.process.pro

    r12361 r12368  
    154154
    155155    ## output log filename
    156     $outroot = `ipp_datapath.pl $WORKDIR`
     156    if ($WORKDIR == NULL)
     157      $outroot = `pwd`
     158    else
     159      $outroot = `ipp_datapath.pl $WORKDIR`
     160    end
    157161    $outroot = $outroot/$EXP_TAG
    158162    $logfile = $outroot/detproc.$DET_ID.$CLASS_ID.log
     
    166170    # create example job options as a demonstration
    167171    if ($VERBOSE > 1)
    168       echo command detrend_process_imfile.pl --det_id $DET_ID --det_type $DET_TYPE --exp_tag $EXP_TAG --class_id $CLASS_ID --input_uri $URI --camera $CAMERA $ARGS
    169     end
    170     command detrend_process_imfile.pl --det_id $DET_ID --det_type $DET_TYPE --exp_tag $EXP_TAG --class_id $CLASS_ID --input_uri $URI --camera $CAMERA $ARGS
     172      echo command detrend_process_imfile.pl --det_id $DET_ID --det_type $DET_TYPE --exp_tag $EXP_TAG --class_id $CLASS_ID --input_uri $URI --camera $CAMERA --workdir $outroot $ARGS
     173    end
     174    command detrend_process_imfile.pl --det_id $DET_ID --det_type $DET_TYPE --exp_tag $EXP_TAG --class_id $CLASS_ID --input_uri $URI --camera $CAMERA --workdir $outroot $ARGS
    171175  end
    172176
     
    267271
    268272    # XXX push this into the filerules?
    269     $outroot = `ipp_datapath.pl $WORKDIR`
     273    if ($WORKDIR == NULL)
     274      $outroot = `pwd`
     275    else
     276      $outroot = `ipp_datapath.pl $WORKDIR`
     277    end
    270278    $outroot = $outroot/$EXP_TAG
    271279    $logfile = $outroot/detproc.$DET_ID.$ITERATION.log
     
    279287    # create example job options as a demonstration
    280288    if ($VERBOSE > 1)
    281       echo command detrend_process_exp.pl --det_id $DET_ID --exp_tag $EXP_TAG --camera $CAMERA $ARGS
    282     end
    283     command detrend_process_exp.pl --det_id $DET_ID --exp_tag $EXP_TAG --camera $CAMERA $ARGS
     289      echo command detrend_process_exp.pl --det_id $DET_ID --exp_tag $EXP_TAG --camera $CAMERA --workdir $outroot $ARGS
     290    end
     291    command detrend_process_exp.pl --det_id $DET_ID --exp_tag $EXP_TAG --camera $CAMERA --workdir $outroot $ARGS
    284292  end
    285293
  • trunk/ippTasks/detrend.reject.pro

    r12126 r12368  
    133133    end
    134134
    135     # I'd like to add CAMERA to the log file...
    136     $outroot = `ipp_datapath.pl $WORKDIR`
     135    if ($WORKDIR == NULL)
     136      $outroot = `pwd`
     137    else
     138      $outroot = `ipp_datapath.pl $WORKDIR`
     139    end
    137140    $outroot = $outroot/$CAMERA.$DET_TYPE.$DET_ID
    138141    $logfile = $outroot/reject.$DET_ID.$ITERATION.log
     
    146149    # create example job options as a demonstration
    147150    if ($VERBOSE > 1)
    148       echo command detrend_reject_exp.pl --det_id $DET_ID --iteration $ITERATION --det_type $DET_TYPE --camera $CAMERA $ARGS
     151      echo command detrend_reject_exp.pl --det_id $DET_ID --iteration $ITERATION --det_type $DET_TYPE --camera $CAMERA --workdir $outroot $ARGS
    149152    end
    150     command detrend_reject_exp.pl --det_id $DET_ID --iteration $ITERATION --det_type $DET_TYPE --camera $CAMERA $ARGS
     153    command detrend_reject_exp.pl --det_id $DET_ID --iteration $ITERATION --det_type $DET_TYPE --camera $CAMERA --workdir $outroot $ARGS
    151154 end
    152155
  • trunk/ippTasks/detrend.resid.pro

    r12126 r12368  
    154154
    155155    # XXX use ipp_filename.pl to lookup output file names
    156     $outroot = `ipp_datapath.pl $WORKDIR`
     156    if ($WORKDIR == NULL)
     157      $outroot = `pwd`
     158    else
     159      $outroot = `ipp_datapath.pl $WORKDIR`
     160    end
    157161    $outroot = $outroot/$EXP_TAG
    158162    $logfile = $outroot/detresid.$DET_ID.$ITERATION.$CLASS_ID.log
     
    166170    # create command
    167171    if ($VERBOSE > 1)
    168       echo command detrend_resid.pl --det_id $DET_ID --iteration $ITERATION --exp_tag $EXP_TAG --class_id $CLASS_ID --det_type $DET_TYPE --detrend $DET_URI --input_uri $URI --camera $CAMERA --mode $MODE $ARGS
    169     end
    170     command detrend_resid.pl --det_id $DET_ID --iteration $ITERATION --exp_tag $EXP_TAG --class_id $CLASS_ID --det_type $DET_TYPE --detrend $DET_URI --input_uri $URI --camera $CAMERA --mode $MODE $ARGS
     172      echo command detrend_resid.pl --det_id $DET_ID --iteration $ITERATION --exp_tag $EXP_TAG --class_id $CLASS_ID --det_type $DET_TYPE --detrend $DET_URI --input_uri $URI --camera $CAMERA --mode $MODE --workdir $outroot $ARGS
     173    end
     174    command detrend_resid.pl --det_id $DET_ID --iteration $ITERATION --exp_tag $EXP_TAG --class_id $CLASS_ID --det_type $DET_TYPE --detrend $DET_URI --input_uri $URI --camera $CAMERA --mode $MODE --workdir $outroot $ARGS
    171175  end
    172176
     
    268272
    269273    # XXX use ipp_filename.pl to lookup output file names
    270     $outroot = `ipp_datapath.pl $WORKDIR`
     274    if ($WORKDIR == NULL)
     275      $outroot = `pwd`
     276    else
     277      $outroot = `ipp_datapath.pl $WORKDIR`
     278    end
    271279    $outroot = $outroot/$EXP_TAG
    272280    $logfile = $outroot/detresid.$DET_ID.$ITERATION.log
     
    280288    # create example job options as a demonstration
    281289    if ($VERBOSE > 1)
    282       echo command detrend_reject_imfile.pl --det_id $DET_ID --iteration $ITERATION --exp_tag $EXP_TAG --det_type $DET_TYPE --camera $CAMERA $ARGS
    283     end
    284     command detrend_reject_imfile.pl --det_id $DET_ID --iteration $ITERATION --exp_tag $EXP_TAG --det_type $DET_TYPE --camera $CAMERA $ARGS
     290      echo command detrend_reject_imfile.pl --det_id $DET_ID --iteration $ITERATION --exp_tag $EXP_TAG --det_type $DET_TYPE --camera $CAMERA --workdir $outroot $ARGS
     291    end
     292    command detrend_reject_imfile.pl --det_id $DET_ID --iteration $ITERATION --exp_tag $EXP_TAG --det_type $DET_TYPE --camera $CAMERA --workdir $outroot $ARGS
    285293  end
    286294
  • trunk/ippTasks/detrend.stack.pro

    r12126 r12368  
    134134    end
    135135
    136     # XXX add $WORKDIR/$LOG_DIR
    137     # XXX use ipp_filename.pl to lookup output file names
    138     $outroot = `ipp_datapath.pl $WORKDIR`
     136    if ($WORKDIR == NULL)
     137      $outroot = `pwd`
     138    else
     139      $outroot = `ipp_datapath.pl $WORKDIR`
     140    end
    139141    $outroot = $outroot/$CAMERA.$DET_TYPE.$DET_ID
    140142    $logfile = $outroot/detstack.$DET_ID.$ITERATION.$CLASS_ID.log
     
    148150    # create the command line
    149151    if ($VERBOSE > 1)
    150       echo command detrend_stack.pl --det_id $DET_ID --iteration $ITERATION --class_id $CLASS_ID --det_type $DET_TYPE --camera $CAMERA $ARGS
     152      echo command detrend_stack.pl --det_id $DET_ID --iteration $ITERATION --class_id $CLASS_ID --det_type $DET_TYPE --camera $CAMERA --workdir $outroot $ARGS
    151153    end
    152     command detrend_stack.pl --det_id $DET_ID --iteration $ITERATION --class_id $CLASS_ID --det_type $DET_TYPE --camera $CAMERA $ARGS
     154    command detrend_stack.pl --det_id $DET_ID --iteration $ITERATION --class_id $CLASS_ID --det_type $DET_TYPE --camera $CAMERA --workdir $outroot $ARGS
    153155  end
    154156
  • trunk/ippTasks/diff.pro

    r12113 r12368  
    141141
    142142    ## generate output log based on filerule
    143     $outroot = `ipp_datapath.pl $WORKDIR`
     143    if ($WORKDIR == NULL)
     144      $outroot = `pwd`
     145    else
     146      $outroot = `ipp_datapath.pl $WORKDIR`
     147    end
    144148    $outroot = $outroot/diff$DIFF_ID
    145149    $logfile = $outroot/skycell.log
     
    153157    # create the command line
    154158    if ($VERBOSE > 1)
    155       echo command diff_skycell.pl --diff_id $DIFF_ID --workdir $WORKDIR $ARGS
     159      echo command diff_skycell.pl --diff_id $DIFF_ID --workdir $outroot $ARGS
    156160    end
    157     command diff_skycell.pl --diff_id $DIFF_ID --workdir $WORKDIR $ARGS
     161    command diff_skycell.pl --diff_id $DIFF_ID --workdir $outroot $ARGS
    158162  end
    159163
  • trunk/ippTasks/stack.pro

    r12116 r12368  
    141141
    142142    ## generate output log based on filerule
    143     $outroot = `ipp_datapath.pl $WORKDIR`
     143    if ($WORKDIR == NULL)
     144      $outroot = `pwd`
     145    else
     146      $outroot = `ipp_datapath.pl $WORKDIR`
     147    end
    144148    $outroot = $outroot/stack$STACK_ID
    145149    $logfile = $outroot/skycell.log
     
    153157    # create the command line
    154158    if ($VERBOSE > 1)
    155       echo command stack_skycell.pl --stack_id $STACK_ID --workdir $WORKDIR $ARGS
     159      echo command stack_skycell.pl --stack_id $STACK_ID --workdir $outroot $ARGS
    156160    end
    157     command stack_skycell.pl --stack_id $STACK_ID --workdir $WORKDIR $ARGS
     161    command stack_skycell.pl --stack_id $STACK_ID --workdir $outroot $ARGS
    158162  end
    159163
  • trunk/ippTasks/warp.pro

    r12109 r12368  
    158158
    159159    ## generate output log based on filerule
    160     $outroot = `ipp_datapath.pl $WORKDIR`
     160    if ($WORKDIR == NULL)
     161      $outroot = `pwd`
     162    else
     163      $outroot = `ipp_datapath.pl $WORKDIR`
     164    end
    161165    $outroot = $outroot/warp$WARP_ID
    162166    $logfile = $outroot/overlap.log
     
    170174    # create the command line
    171175    if ($VERBOSE > 1)
    172       echo command warp_overlap.pl --warp_id $WARP_ID --camera $CAMERA --workdir $WORKDIR $ARGS
    173     end
    174     command warp_overlap.pl --warp_id $WARP_ID --camera $CAMERA --workdir $WORKDIR $ARGS
     176      echo command warp_overlap.pl --warp_id $WARP_ID --camera $CAMERA --workdir $outroot $ARGS
     177    end
     178    command warp_overlap.pl --warp_id $WARP_ID --camera $CAMERA --workdir $outroot $ARGS
    175179  end
    176180
     
    272276
    273277    ## generate output log based on filerule
    274     $outroot = `ipp_datapath.pl $WORKDIR`
     278    if ($WORKDIR == NULL)
     279      $outroot = `pwd`
     280    else
     281      $outroot = `ipp_datapath.pl $WORKDIR`
     282    end
    275283    $outroot = $outroot/warp$WARP_ID
    276284    $logfile = $outroot/skycell.log
     
    284292    # create the command line
    285293    if ($VERBOSE > 1)
    286       echo command warp_skycell.pl --warp_id $WARP_ID --skycell_id $SKYCELL_ID --tess_id $TESS_ID --camera $CAMERA --workdir $WORKDIR $ARGS
    287     end
    288     command warp_skycell.pl --warp_id $WARP_ID --skycell_id $SKYCELL_ID --tess_id $TESS_ID --camera $CAMERA --workdir $WORKDIR $ARGS
     294      echo command warp_skycell.pl --warp_id $WARP_ID --skycell_id $SKYCELL_ID --tess_id $TESS_ID --camera $CAMERA --workdir $outroot $ARGS
     295    end
     296    command warp_skycell.pl --warp_id $WARP_ID --skycell_id $SKYCELL_ID --tess_id $TESS_ID --camera $CAMERA --workdir $outroot $ARGS
    289297  end
    290298
Note: See TracChangeset for help on using the changeset viewer.