IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 39306 for trunk


Ignore:
Timestamp:
Jan 10, 2016, 6:59:48 AM (11 years ago)
Author:
eugene
Message:

address found_t

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Ohana/src/addstar/src/find_matches_refstars.c

    r38986 r39306  
    2222  ALLOCATE (N1, off_t,  srccat->Naverage);
    2323
    24   myAbort ("figure out if found_t needs to be tracking Naverage or Nmeasure");
     24  // found_t[] has the following values:
     25  // -1: not found
     26  // -2: found on another catalog
     27  //  1: found (we used to use Nmeas, but we are now matching by star not measure
     28
    2529  if (!srccat->found_t) {
    2630    ALLOCATE (srccat->found_t, off_t, srccat->Naverage);
     
    218222        /** don't update average / secfilt values for REF photcodes **/
    219223
    220         myAbort ("fix logic on multiple detections");
    221 
    222224        /*** flag multiple stars */
     225        /* this code is a bit too crude */
    223226        /* this image star matches more than one tgtcat star */
     227        /* here found_t[N] = tgtcat.measure[N] */
    224228        if (srccat->found_t[N] > -1) {
    225           tgtcat[0].measure[srccat->found_t[N]].dbFlags |= ID_MEAS_BLEND_MEAS;
     229          // tgtcat[0].measure[srccat->found_t[N]].dbFlags |= ID_MEAS_BLEND_MEAS;
    226230          tgtcat[0].measure[Nmeas].dbFlags |= ID_MEAS_BLEND_MEAS;
    227231        }
     
    230234        }
    231235        if (srccat->found_t[N] == -1) { /* this image star matches only this tgtcat star */
    232           srccat->found_t[N] = Nmeas;  /* save first match, in case coincidences are found */
     236          srccat->found_t[N] = 1;  /* save first match, in case coincidences are found */
    233237        }
    234238        /* this tgtcat star matches more than one image star */
    235239        if (tgtcat[0].found_t[n] > -1) {
    236           tgtcat[0].measure[tgtcat[0].found_t[n]].dbFlags |= ID_MEAS_BLEND_OBJ;
     240          // tgtcat[0].measure[tgtcat[0].found_t[n]].dbFlags |= ID_MEAS_BLEND_OBJ;
    237241          tgtcat[0].measure[Nmeas].dbFlags |= ID_MEAS_BLEND_OBJ;
    238242        } else {
    239           tgtcat[0].found_t[n] = Nmeas;
     243          tgtcat[0].found_t[n] = 1;
    240244        }
    241245        tgtcat[0].average[n].Nmeasure ++;
     
    321325      /* next[Nmeas] should always be -1 in this context (it is always the only
    322326         measurement for the star) */
    323       srccat->found_t[i] = Nmeas;
     327      srccat->found_t[i] = 1;
    324328      Nmeas ++;
    325329
Note: See TracChangeset for help on using the changeset viewer.