IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 10691


Ignore:
Timestamp:
Dec 12, 2006, 10:36:33 PM (19 years ago)
Author:
eugene
Message:

added subdirs to output log files, added verbosity

Location:
trunk/ippTasks
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/ippTasks/pantasks.pro

    r10678 r10691  
    11
     2# XXX make these upper-case
    23$network = 1
    34$parallel = 1
     5$VERBOSE = 1
     6
    47# $scripts = $HOME/src/pantasks/ipp/ippTasks
    58$scripts = .
  • trunk/ippTasks/phase0.pro

    r10675 r10691  
    1818$Phase0ExpFail = 0
    1919
     20if ($?VERBOSE == 0)
     21  echo "VERBOSE not defined: load pantasks.pro first"
     22  break
     23end
    2024if ($?LOGDIR == 0)
    2125  echo "LOGDIR not defined: load pantasks.pro first"
     
    2428$LOGSUBDIR = $LOGDIR/phase0
    2529exec mkdir -p $LOGSUBDIR
     30
     31macro phase0.status
     32  queueprint Phase0Imfiles
     33  queueprint Phase0Exposures
     34  echo "Phase0ImfileFail: $Phase0ImfileFail"
     35  echo "Phase0ExpFail: $Phase0ExpFail"
     36end
    2637
    2738# select images ready for phase0 analysis
     
    5263    for i 0 $Nqueue
    5364      queuepop stdout -var line
    54       echo $line
     65      if ($VERBOSE > 2)
     66        echo $line
     67      end
    5568      list word -split $line
    5669      $EXP_TAG  = $word:0
     
    6780  # locked list
    6881  task.exit    default
    69     echo "phase0 pending imfiles: failure"
     82    if ($VERBOSE)
     83      echo "phase0 pending imfiles: failure"
     84    end
    7085    $Phase0ImfileFail ++
    7186  end
     
    7388  # operation times out?
    7489  task.exit    timeout
    75     echo "phase0 pending imfiles: timeout"
     90    if ($VERBOSE)
     91      echo "phase0 pending imfiles: timeout"
     92    end
    7693  end
    7794end
     
    116133    list word -split $word
    117134    $base = $word:0
    118     stdout $LOGSUBDIR/$base.p0.log
    119     stderr $LOGSUBDIR/$base.p0.log
     135    stdout $LOGSUBDIR/$base/$EXP_TAG.p0.log
     136    stderr $LOGSUBDIR/$base/$EXP_TAG.p0.log
     137    exec mkdir -p $LOGSUBDIR/$base
    120138
    121139    # create the command line
    122140    options "$line"
    123     echo command phase0_imfile.pl --exp_tag $EXP_TAG --class_id $CLASS_ID --uri $URI
     141    if ($VERBOSE > 1)
     142      echo command phase0_imfile.pl --exp_tag $EXP_TAG --class_id $CLASS_ID --uri $URI
     143    end
    124144    command phase0_imfile.pl --exp_tag $EXP_TAG --class_id $CLASS_ID --uri $URI
    125145  end
     
    133153  # default exit status
    134154  task.exit    default
    135     echo "failure for phase0imfile.pl: $options:0"
     155    if ($VERBOSE)
     156      echo "failure for phase0imfile.pl: $options:0"
     157    end
    136158    queuepush Phase0Imfiles -replace -key 1 "FAIL $options:0"
    137159    $Phase0ImfileFail ++
     
    140162  # operation times out?
    141163  task.exit    timeout
    142     echo "timeout for phase0imfile.pl: $options:0"
     164    if ($VERBOSE)
     165      echo "timeout for phase0imfile.pl: $options:0"
     166    end
    143167    queuepush Phase0Imfiles -replace -key 1 "TIMEOUT $options:0"
    144168  end
     
    192216  # default exit status
    193217  task.exit    default
    194     echo       "phase0 pending exp: failure"
    195   end
    196 
    197   # operation times out?
    198   task.exit    timeout
    199     echo       "phase0 pending exp: timeout"
     218    if ($VERBOSE)
     219      echo       "phase0 pending exp: failure"
     220    end
     221  end
     222
     223  # operation times out?
     224  task.exit    timeout
     225    if ($VERBOSE)
     226      echo       "phase0 pending exp: timeout"
     227    end
    200228  end
    201229end
     
    230258    list word -split $word
    231259    $base = $word:0
    232     stdout $LOGSUBDIR/$base.p0.log
    233     stderr $LOGSUBDIR/$base.p0.log
     260    stdout $LOGSUBDIR/$base/$EXP_TAG.p0.log
     261    stderr $LOGSUBDIR/$base/$EXP_TAG.p0.log
     262    exec mkdir -p $LOGSUBDIR/$base
    234263
    235264    # specify choice of remote host:(need to choose based on chips)
     
    242271    # create the command line
    243272    options "$line"
    244     echo command phase0_exp.pl --exp_tag $EXP_TAG
     273    if ($VERBOSE > 1)
     274      echo command phase0_exp.pl --exp_tag $EXP_TAG
     275    end
    245276    command phase0_exp.pl --exp_tag $EXP_TAG
    246277  end
Note: See TracChangeset for help on using the changeset viewer.