IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

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

File:
1 edited

Legend:

Unmodified
Added
Removed
  • 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
Note: See TracChangeset for help on using the changeset viewer.