IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Nov 22, 2009, 2:57:41 PM (16 years ago)
Author:
eugene
Message:

various fixes to psastro:

1) added bootstrap resampling to zero point error analysis
2) added iterative clump removal from refstars and rawstars
3) added unique reference match option
4) some improved visualizations
5) improved mosaic iterations

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/psastro/src/psastroMosaicSetMatch.c

    r21422 r26259  
    2626    double RADIUS = psMetadataLookupF32 (&status, recipe, radiusWord);
    2727    if (!status) {
    28         psError(PS_ERR_IO, false, "Failed to lookup matching radius: %s", radiusWord);
    29         psFree (view);
    30         return false;
     28        psAbort("Failed to lookup matching radius: %s", radiusWord);
     29    }
     30
     31    int uniqIter = psMetadataLookupS32 (&status, recipe, "PSASTRO.MOSAIC.UNIQ.ITER");
     32    if (!status) {
     33        psAbort("Failed to lookup matching PSASTRO.MOSAIC.UNIQ.ITER");
    3134    }
    3235
     
    5861
    5962                // select the raw objects for this readout
    60                 psArray *rawstars = psMetadataLookupPtr (NULL, readout->analysis, "PSASTRO.RAWSTARS");
     63                psArray *rawstars = psMetadataLookupPtr (NULL, readout->analysis, "PSASTRO.RAWSTARS.SUBSET");
    6164                if (rawstars == NULL) { continue; }
    6265
    6366                // select the raw objects for this readout
    64                 psArray *refstars = psMetadataLookupPtr (NULL, readout->analysis, "PSASTRO.REFSTARS");
     67                psArray *refstars = psMetadataLookupPtr (NULL, readout->analysis, "PSASTRO.REFSTARS.SUBSET");
    6568                if (refstars == NULL) { continue; }
    6669                psTrace ("psastro", 4, "Trying %ld refstars\n", refstars->n);
     
    6871                psArray *matches = pmAstromRadiusMatchChip (rawstars, refstars, RADIUS);
    6972                psTrace ("psastro", 4, "Matched %ld refstars\n", matches->n);
     73
     74                if (iteration >= uniqIter) {
     75                    psArray *unique = pmAstromRadiusMatchUniq (rawstars, refstars, matches);
     76                    if (!unique) {
     77                        psLogMsg ("psastro", 3, "failed to generate a uniq set of matched sources\n");
     78                        return false;
     79                    }
     80                    psFree (matches);
     81                    matches = unique;
     82                }
    7083
    7184                pmAstromVisualPlotMosaicMatches(rawstars, refstars, matches, iteration, recipe);
Note: See TracChangeset for help on using the changeset viewer.