IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 42032


Ignore:
Timestamp:
Feb 9, 2022, 5:34:17 PM (4 years ago)
Author:
eugene
Message:

add options to compare smfs by data_group, and sets of smfs by data_group

Location:
branches/eam_branches/ipp-20211108/ippTests/ippCheck
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/eam_branches/ipp-20211108/ippTests/ippCheck/ippCheck

    r42031 r42032  
    229229  echo "   EG: ippCheck dvo  (expname) (dgroup)"
    230230  echo "   EG: ippCheck smf  (outroot) (smf1) (smf2) [+plot]"
    231   echo "   EG: ippCheck smf.dgrp (outroot) (smf1) (smf2) [+plot]"
     231  echo "   EG: ippCheck smf.dgrp.exp (outroot) (expname) (dgroup1) (dgroup2) [+plot]"
     232  echo "   EG: ippCheck smf.dgrp.all (outroot) (dgroup1) (dgroup2) [+plot]"
    232233  echo "   EG: ippCheck plot (expname)"
    233234  echo "   EG: ippCheck plot.glob (expglob) (outroot)"
     
    263264  end
    264265
    265   if ("$argv:0" == "smf.dgrp")
    266     smf.compare.by.datagroups $arglist
     266  if ("$argv:0" == "smf.dgrp.exp")
     267    smf.compare.exp.by.datagroups $arglist
     268    exit 0
     269  end
     270
     271  if ("$argv:0" == "smf.dgrp.all")
     272    smf.compare.allexp.by.datagroups $arglist
    267273    exit 0
    268274  end
  • branches/eam_branches/ipp-20211108/ippTests/ippCheck/smfcheck.pro

    r42031 r42032  
    66module tap.pro
    77
    8 macro smf.compare.by.datagroups
     8macro smf.compare.allexp.by.datagroups
     9  $CAMERA = gpc1 
     10
     11  getargs +plot     BOOL  -var SAVEPLOT
     12  getargs -camera   VALUE -var CAMERA
     13
     14  if ($0 != 4)
     15    echo "USAGE: smf.compare.allexp.by.datagroups (outdir) (DG1) (DG2) [+plot] [-camera gpc2]"
     16    break
     17  end
     18
     19  local outdir dgrp1 dgrp2 command i npages expname
     20  $outdir = $1
     21  $dgrp1 = $2
     22  $dgrp2 = $3
     23
     24  # identify the list of exposures in the data groups
     25  $command = camtool -dbname $CAMERA -processedexp -data_group $dgrp2
     26 
     27  queueload  myqueue -x "$command"
     28  queue2book myqueue mybook
     29 
     30  $camPath = NONE
     31  book npages mybook -var npages
     32 
     33  if ($npages < 1)
     34   echo "ERROR: missing exposures for $dgrp2 : $command"
     35   book delete mybook
     36   next
     37  end
     38 
     39  for i 0 $npages 
     40    sprint pagename page.%03d $i
     41    book getword mybook $pagename exp_name -var expname
     42    $expnames:$i = $expname
     43  end
     44  $expnames:n = $npages
     45
     46  book delete mybook
     47
     48  $options =
     49  setargs +plot   BOOL  $SAVEPLOT
     50  setargs -camera VALUE $CAMERA
     51
     52  mkdir $outdir
     53
     54  for i 0 $expnames:n
     55    echo smf.compare.exp.by.datagroups $outdir/$expnames:$i $expnames:$i $dgrp1 $dgrp2 $options
     56    exec ippCheck smf.dgrp.exp $outdir/$expnames:$i $expnames:$i $dgrp1 $dgrp2 $options >& $outdir/$expnames:$i.log
     57  end
     58end
     59
     60macro smf.compare.exp.by.datagroups
    961  $CAMERA = gpc1 
    1062
     
    3183  $smf2    = `neb-locate -p $smffile`
    3284
    33   $saveplot =
    34   if ($SAVEPLOT)
    35     $saveplot = +plot
    36   end
    37   smf.compare.all.extensions $output $smf1 $smf2
     85  $options =
     86  setargs +plot   BOOL  $SAVEPLOT
     87  smf.compare.all.extensions $output $smf1 $smf2 $options
    3888end
    3989
     
    697747end
    698748
     749## XXX this macro is sort of the opposite of getargs: it
     750## appends values to the variable options
     751macro setargs
     752  if ("$2" == "BOOL")
     753    if ($3)
     754      $options = $options $1
     755    end
     756  end
     757
     758  if ("$2" == "VALUE")
     759    $options = $options $1 $3
     760  end
     761end
     762
    699763########## EXAMPLES:
    700764
Note: See TracChangeset for help on using the changeset viewer.