IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 34361 for trunk


Ignore:
Timestamp:
Aug 28, 2012, 2:11:59 PM (14 years ago)
Author:
bills
Message:

fix bug in addstar in which a source gets matched to objects in 2 catalog files.
The fix is to repair the logic where star->found is set.

found >= 0 measurement matched to current catalog
found == -1 not matched anywhere yet
found == -2 found in a previously processed catalog

Location:
trunk/Ohana/src/addstar/src
Files:
3 edited

Legend:

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

    r34260 r34361  
    313313    if (stars[i].found > -1) {
    314314      stars[i].found = -2;
    315     } else {
    316       stars[i].found = -3;
    317315    }
    318316  }
  • trunk/Ohana/src/addstar/src/find_matches_closest.c

    r34260 r34361  
    130130      j++;
    131131      continue;
     132    }
     133
     134    if (stars[N1[i]].found != -1) {
     135        /* this star has already been assigned to an object in this or another catalog */
     136        i++;
     137        continue;
    132138    }
    133139
     
    249255    }
    250256
    251     if (stars[i].found >= 0) continue;
     257    if (stars[i].found != -1) continue;
    252258    if (!IN_REGION (stars[i].average.R, stars[i].average.D)) continue;
    253259
     
    315321    if (stars[i].found > -1) {
    316322      stars[i].found = -2;
    317     } else {
    318       stars[i].found = -3;
    319323    }
    320324  }
  • trunk/Ohana/src/addstar/src/find_matches_closest_refstars.c

    r34260 r34361  
    320320    if (stars[i][0].found > -1) {
    321321      stars[i][0].found = -2;
    322     } else {
    323       stars[i][0].found = -3;
    324322    }
    325323  }
Note: See TracChangeset for help on using the changeset viewer.