IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 37603


Ignore:
Timestamp:
Nov 14, 2014, 8:41:13 PM (12 years ago)
Author:
eugene
Message:

update relphot tap tests

Location:
branches/eam_branches/ipp-20140904/Ohana/src/addstar
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • branches/eam_branches/ipp-20140904/Ohana/src/addstar/src/find_matches_ICRF.c

    r37570 r37603  
    136136
    137137    // measure now carries R,D (not dR,dD)
    138     catalog[0].measure[Nmeas].dbFlags  = 0;
    139138    catalog[0].measure[Nmeas].averef   = n;
    140139    catalog[0].measure[Nmeas].objID    = catalog[0].average[n].objID;
  • branches/eam_branches/ipp-20140904/Ohana/src/addstar/src/mkcmf.c

    r37386 r37603  
    294294  gfits_modify (&header, "NASTRO",   "%d", 1, 100);
    295295
    296   if (imageID == -1) imageID = 1000.0*drand48();
    297   if (sourceID == -1) sourceID = 100.0*drand48();
     296  if (imageID == -1) imageID = 100000.0*drand48();
     297  if (sourceID == -1) sourceID = 1000.0*drand48();
    298298  gfits_modify (&header, "IMAGEID",  "%d", 1, imageID);
    299299  gfits_modify (&header, "SOURCEID", "%d", 1, sourceID);
  • branches/eam_branches/ipp-20140904/Ohana/src/addstar/test/relphot.parallel.dvo

    r33653 r37603  
    2525  if (not($?VERBOSE)) set VERBOSE = 0
    2626
    27   # images are loaded into dvo with GPC1 photcodes, so we need to get the nominal zps for those filters
    28   $zpt_nominal:g = 24.58
    29   $zpt_nominal:r = 24.80
    30   $zpt_nominal:i = 24.74
    31   $zpt_nominal:z = 24.26
    32   $zpt_nominal:y = 23.41
    33 
    34   # klam is negative, so klam*(airmass - 1) increase the zero point
    35   $klam_nominal:g = -0.15
    36   $klam_nominal:r = -0.10
    37   $klam_nominal:i = -0.04
    38   $klam_nominal:z = -0.03
    39   $klam_nominal:y = -0.03
     27# images are loaded into dvo with GPC1 photcodes, so we need to get the nominal zps for those filters
     28# $zpt_nominal:g = 24.58
     29# $zpt_nominal:r = 24.80
     30# $zpt_nominal:i = 24.74
     31# $zpt_nominal:z = 24.26
     32# $zpt_nominal:y = 23.41
     33
     34# klam is negative, so klam*(airmass - 1) increase the zero point
     35# $klam_nominal:g = -0.15
     36# $klam_nominal:r = -0.10
     37# $klam_nominal:i = -0.04
     38# $klam_nominal:z = -0.03
     39# $klam_nominal:y = -0.03
     40
     41  $zpt_nominal:g = 24.563; $klam_nominal:g = -0.147
     42  $zpt_nominal:r = 24.750; $klam_nominal:r = -0.085
     43  $zpt_nominal:i = 24.611; $klam_nominal:i = -0.044
     44  $zpt_nominal:z = 24.250; $klam_nominal:z = -0.033
     45  $zpt_nominal:y = 23.320; $klam_nominal:y = -0.073
    4046
    4147  # we have two sets of images: ubercaled and not-ubercaled
     
    111117  mksequence $fileroot $catdir
    112118  for i 0 mjd_nc[]
    113     ckexposure $catdir mjd_nc[$i] zpt_nc[$i] exptime_nc[$i] airmass_nc[$i] $filt_nc:$i raw
     119    ckexposure $catdir mjd_nc[$i] zpt_nc[$i] exptime_nc[$i] airmass_nc[$i] $filt_nc:$i raw 0
    114120  end
    115121
     
    121127
    122128  # run relphot on the serial db and check that the images now match the expected values
    123   exec relphot g,r,i -v -region 9.5 10.5 19.5 20.5 -D CATDIR $catdir -D STAR_TOOFEW 1 -D SIGMA_LIM 0.07 -statmode WT_MEAN -cloud-limit 0.5 -keep-ubercal -D IMAGE_OFFSET 0.5 -update >& log.relphot.s0
     129  exec relphot -images g,r,i -v -region 9.5 10.5 19.5 20.5 -D CATDIR $catdir -D STAR_TOOFEW 1 -D SIGMA_LIM 0.07 -statmode WT_MEAN -cloud-limit 0.5 -D IMAGE_OFFSET 0.5 -update >& log.relphot.s0
    124130
    125131  for i 0 mjd_nc[]
     
    128134    # matching the mean zp of photometric data, which we calculate in
    129135    # 'init'
    130     ckexposure $catdir mjd_nc[$i] $zpt_nc_$filt_nc:$i exptime_nc[$i] airmass_nc[$i] $filt_nc:$i relphot_nc
     136    ckexposure $catdir mjd_nc[$i] $zpt_nc_$filt_nc:$i exptime_nc[$i] airmass_nc[$i] $filt_nc:$i relphot_nc 0
    131137  end
    132138
    133139  # run relphot on the parallel db and check that the images now match the expected values
    134   exec relphot -parallel g,r,i -v -region 9.5 10.5 19.5 20.5 -D CATDIR $catdir.p0 -D STAR_TOOFEW 1 -D SIGMA_LIM 0.07 -statmode WT_MEAN -cloud-limit 0.5 -keep-ubercal -D IMAGE_OFFSET 0.5 -update >& log.relphot.p0
    135 
    136   exec dvodist -in $catdir.p0 >& log.dvodist.in
     140  exec relphot -images -parallel g,r,i -v -region 9.5 10.5 19.5 20.5 -D CATDIR $catdir.p0 -D STAR_TOOFEW 1 -D SIGMA_LIM 0.07 -statmode WT_MEAN -cloud-limit 0.5 -D IMAGE_OFFSET 0.5 -update >& log.relphot.p0
    137141
    138142  for i 0 mjd_nc[]
     
    141145    # matching the mean zp of photometric data, which we calculate in
    142146    # 'init'
    143     ckexposure $catdir.p0 mjd_nc[$i] $zpt_nc_$filt_nc:$i exptime_nc[$i] airmass_nc[$i] $filt_nc:$i relphot_nc
     147    ckexposure $catdir.p0 mjd_nc[$i] $zpt_nc_$filt_nc:$i exptime_nc[$i] airmass_nc[$i] $filt_nc:$i relphot_nc 1
    144148  end
    145149
     
    148152
    149153macro ckexposure
    150   if ($0 != 8)
    151     echo "ckexposure (catdir) (mjd) (zpt) (exptime) (airmass) (filter) (mode)"
     154  if ($0 != 9)
     155    echo "ckexposure (catdir) (mjd) (zpt) (exptime) (airmass) (filter) (mode) (isParallel)"
    152156    echo "  mode == raw or corr"
    153157    break
     
    163167  $FILTER      = $6
    164168  $MODE        = $7
     169  $PARALLEL    =
     170  if ($8)
     171    $PARALLEL = "-parallel"
     172  end
    165173
    166174  # XXX need a function to extract the nominal zpt for a given filter / photcode from the db
     
    182190
    183191  skyregion {$RA_CENTER - 0.2/dcos($DEC_CENTER)} {$RA_CENTER + 0.2/dcos($DEC_CENTER)} {$DEC_CENTER - 0.2} {$DEC_CENTER + 0.2}
    184   mextract ra dec mag xccd yccd where (abs(time - $MJD_IMAGE) < 0.0001)
     192  mextract $PARALLEL ra dec mag xccd yccd where (abs(time - $MJD_IMAGE) < 0.0001)
    185193  if (not(ra[]))
    186194    echo "no matching data for MJD = $MJD_IMAGE"
     
    344352    # the fake images have inconsistent ra,dec and airmass,sidtime values
    345353    if ($VERBOSE) echo addstar $ROOT.$ix.$iy.cmf -D CATDIR $CATDIR -D CAMERA gpc1 -quick-airmass
    346     exec addstar $ROOT.$ix.$iy.cmf -D CATDIR $CATDIR -D CAMERA gpc1 -quick-airmass >& /dev/null
     354    exec addstar $ROOT.$ix.$iy.cmf -D CATDIR $CATDIR -D CAMERA gpc1 -quick-airmass >& log.addstar
    347355    # costs 10/36 sec / chip
    348356  end
     
    432440  $catdir = $tmp1/$tmp2
    433441
     442  if ($VERBOSE) echo rsync -auv $catdir/ $catdir.p0/
    434443  exec rsync -auv $catdir/ $catdir.p0/ >& log.rsync
    435444  mkdir $catdir.d1
     
    442451  exec echo "3 $hostname $catdir.d3" >> $catdir.p0/HostTable.dat
    443452
     453  if ($VERBOSE) echo dvodist -out $catdir.p0
    444454  exec dvodist -out $catdir.p0 >& log.dvodist.out
    445455end
Note: See TracChangeset for help on using the changeset viewer.