IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Sep 6, 2011, 1:32:31 PM (15 years ago)
Author:
eugene
Message:
  • clarified the output to show the stages and their timing more clearly
  • psphotStackReadout now uses the same functions as psphotReadout (deprecated FitLinearStack, ExtendedAnalysisByObject, RadialAnalysisByObject, etc)
  • psphotStack now does 2nd (5 sigma) detection pass and radial photometry of the un-matched image (as well as the matched images)
  • for speed, fitting uses a smaller subset of pixels than subtraction: the model is extended when the subtraction is performed to avoid a discontinuity
  • extended source analysis (petrosians) is threaded
  • iterative kron radius / magnitude analysis with down-weighted neighbors replaces the masked neighbor kron analysis. the result of this analysis is used by fitting guesses and is the value written to the PSF and XFIT tables.
  • the target matched PSFs are determined in advance and the 0 element of this array is always the unmatched image (with target PSF of NAN)
  • dQ, the difference between the upper and lower quartile, is measured (but not yet used to adjust the sky level. sky should be FITTED_MEAN - 2.5*dQ
  • fake sources inserted for the efficiency analysis are removed at the end of the analysis
  • radial apertures is now threaded
  • edge case petrosian mags are now handled without aborts (may still have a problem with the measured error of the petrosian radius)
  • new sersic model guess based on the psf size, the moments, and the kron flux. the psf - kron mag is used to guess the index, then the index is used to convert measured moments into model guess parameters. this uses empirical relationships between the quantities generated from fake images.
  • define the fit region and window region based on the 1st radial moments
  • use the kron S/N to determine if analysis is performed for extended sources, not the psf S/N
  • remove the old 'basic deblend' which did not really do any deblending and is superceeded by the deblending in KronIterate and the footprint analysis
Location:
trunk/psphot
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/psphot

  • trunk/psphot/src

    • Property svn:ignore
      •  

        old new  
        2222psphotMakePSF
        2323psphotStack
         24psphotModelTest
  • trunk/psphot/src/psphotReadout.c

    r31452 r32348  
    102102        return psphotReadoutCleanup (config, view, filerule);
    103103    }
    104 
    105 # if (0)
    106     // XXX test to mask outliers, not very helpful
    107     // mask the high values in the image (with MARK)
    108     if (!psphotMaskBackground (config, view, filerule)) {
    109         return psphotReadoutCleanup (config, view, filerule);
    110     }
    111 
    112     // generate a background model (median, smoothed image)
    113     if (!psphotModelBackground (config, view, filerule)) {
    114         return psphotReadoutCleanup (config, view, filerule);
    115     }
    116 # endif
    117 
    118104    if (!psphotSubtractBackground (config, view, filerule)) {
    119105        return psphotReadoutCleanup (config, view, filerule);
     
    137123    }
    138124
    139     // construct sources and measure basic stats (saved on detections->newSources)
     125    // construct sources and measure moments and other basic stats (saved on detections->newSources)
     126    // all sources use the auto-scaled window appropriate to a PSF, except for the saturated
     127    // stars : these use a larger window (3x the basic window)
    140128    if (!psphotSourceStats (config, view, filerule, true)) { // pass 1
    141129        psError(PSPHOT_ERR_UNKNOWN, false, "failure to generate sources");
     
    153141
    154142    // mark blended peaks PS_SOURCE_BLEND (detections->newSources)
    155     if (!psphotBasicDeblend (config, view, filerule)) {
     143    // XXX I've deactivated this because it was preventing galaxies close to stars from being
     144    // XXX fitted as an extended source.
     145    if (false && !psphotBasicDeblend (config, view, filerule)) {
    156146        psError (PSPHOT_ERR_UNKNOWN, false, "failed on deblend analysis");
    157147        return psphotReadoutCleanup (config, view, filerule);
     
    200190    psphotDumpChisqs (config, view, filerule);
    201191
    202     // XXX re-measure the kron mags with models subtracted
    203     psphotKronMasked(config, view, filerule);
     192    // re-measure the kron mags with models subtracted.  this pass uses a circular window of size PSF_MOMENTS_RADIUS (same window used to measure the psf-scale moments)
     193   
     194    // but this is chosen above to be appropriate for the PSF objects (not galaxies)
     195    // psphotKronMasked(config, view, filerule);
     196    psphotKronIterate(config, view, filerule);
    204197
    205198    // identify CRs and extended sources (only unmeasured sources are measured)
     
    240233        psphotSubNoise (config, view, filerule); // pass 1 (detections->allSources)
    241234
    242         // define new sources based on only the new peaks
     235        // define new sources based on only the new peaks & measure moments
    243236        // NOTE: new sources are saved on detections->newSources
    244237        psphotSourceStats (config, view, filerule, false); // pass 2 (detections->newSources)
     
    312305pass1finish:
    313306
    314     // XXX re-measure the kron mags with models subtracted
    315     psphotKronMasked(config, view, filerule);
     307    // re-measure the kron mags with models subtracted
     308    // psphotKronMasked(config, view, filerule);
     309    psphotKronIterate(config, view, filerule);
    316310
    317311    // measure source size for the remaining sources
     
    321315    psphotExtendedSourceAnalysis (config, view, filerule); // pass 1 (detections->allSources)
    322316    psphotExtendedSourceFits (config, view, filerule); // pass 1 (detections->allSources)
    323     psphotRadialApertures(config, view, filerule);
     317    psphotRadialApertures(config, view, filerule, 0);
    324318
    325319finish:
     
    359353    }
    360354
     355    psLogMsg ("psphot.readout", PS_LOG_WARN, "complete psphot readout : %f sec\n", psTimerMark ("psphotReadout"));
     356
    361357    // create the exported-metadata and free local data
    362358    return psphotReadoutCleanup(config, view, filerule);
Note: See TracChangeset for help on using the changeset viewer.