IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 13375


Ignore:
Timestamp:
May 14, 2007, 11:00:36 AM (19 years ago)
Author:
rhl
Message:

Don't subtract saturated stars

Location:
trunk/psphot/src
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/psphot/src/psphotFitSourcesLinear.c

    r13035 r13375  
    5555        if (source->type == PM_SOURCE_TYPE_DEFECT) continue;
    5656        if (source->type == PM_SOURCE_TYPE_SATURATED) continue;
     57        if (source->type == PM_SOURCE_TYPE_STAR &&
     58            source->mode & PM_SOURCE_MODE_SATSTAR) continue;
    5759        if (final) {
    5860            if (source->mode &  PM_SOURCE_MODE_SUBTRACTED) continue;
  • trunk/psphot/src/psphotReadout.c

    r13374 r13375  
    6363    // find the peaks in the image
    6464    psArray *peaks;
     65    psArray *footprints = NULL;
    6566    if (useFootprints) {
    66        psArray *footprints = psphotFindPeaks (readout, recipe, useFootprints, 1);
     67       footprints = psphotFindPeaks (readout, recipe, useFootprints, 1);
    6768       int growRadius = psMetadataLookupS32(NULL, recipe, "FOOTPRINT_GROW_RADIUS");
    6869       if (growRadius > 0) {
     
    7172           footprints = tmp;
    7273       }
     74       psphotCullPeaks(readout->image, readout->weight, recipe, footprints);
    7375
    7476       peaks = pmFootprintArrayToPeaks(footprints);
    75        psFree(footprints);
    7677    } else {
    7778       peaks = psphotFindPeaks (readout, recipe, useFootprints, 1);
     
    184185       }
    185186
    186        psphotCullPeaks(readout->image, readout->weight, recipe, newFootprints);
    187 
    188        newPeaks = pmFootprintArrayToPeaks(newFootprints);
    189 
     187       // merge in old peaks
     188       const int includePeaks = 0x0 | 0x2; // i.e. just from newFootprints
     189       psArray *mergedFootprints = pmMergeFootprintArrays(footprints, newFootprints, includePeaks);
     190       psFree(footprints);
    190191       psFree(newFootprints);
     192
     193       psphotCullPeaks(readout->image, readout->weight, recipe, mergedFootprints);
     194
     195       newPeaks = pmFootprintArrayToPeaks(mergedFootprints);
     196
     197       psFree(mergedFootprints);
    191198    } else {
    192199       newPeaks = psphotFindPeaks(readout, recipe, useFootprints, 2);
Note: See TracChangeset for help on using the changeset viewer.