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/psphotBlendFit.c

    r31452 r32348  
    55{
    66    bool status = true;
     7
     8    fprintf (stdout, "\n");
     9    psLogMsg ("psphot", PS_LOG_INFO, "--- psphot Fit Sources (Non-Linear) ---");
    710
    811    // select the appropriate recipe information
     
    186189    psFree (fitOptions);
    187190
    188     psLogMsg ("psphot.psphotBlendFit", PS_LOG_INFO, "fit models: %f sec for %d objects (%d psf, %d ext, %d failed, %ld skipped)\n", psTimerMark ("psphot.fit.nonlinear"), Nfit, Npsf, Next, Nfail, sources->n - Nfit);
     191    psLogMsg ("psphot.psphotBlendFit", PS_LOG_WARN, "fit models: %f sec for %d objects (%d psf, %d ext, %d failed, %ld skipped)\n", psTimerMark ("psphot.fit.nonlinear"), Nfit, Npsf, Next, Nfail, sources->n - Nfit);
    189192
    190193    psphotVisualShowResidualImage (readout, false);
     
    233236        pmSource *source = sources->data[i];
    234237
     238# define TEST_X -420.0
     239# define TEST_Y 300.0
     240   
     241        if ((fabs(source->peak->xf - TEST_X) < 5) && (fabs(source->peak->yf - TEST_Y) < 5)) {
     242            fprintf (stderr, "test galaxy\n");
     243        }
     244
     245# undef TEST_X
     246# undef TEST_Y
     247
    235248        // skip non-astronomical objects (very likely defects)
    236249        if (source->mode &  PM_SOURCE_MODE_BLEND) continue;
     
    246259
    247260        // limit selection to some SN limit
    248         if (sqrt(source->peak->detValue) < FIT_SN_LIM) continue;
    249 
     261        if (source->mode & PM_SOURCE_MODE_EXT_LIMIT) {
     262            if (source->moments->KronFlux < FIT_SN_LIM * source->moments->KronFluxErr) continue;
     263        } else {
     264            if (sqrt(source->peak->detValue) < FIT_SN_LIM) continue;
     265        }
    250266        // exclude sources outside optional analysis region
    251267        if (source->peak->xf < AnalysisRegion.x0) continue;
     
    267283        }
    268284
    269         // replace object in image
     285        // replace object in image & remove excess noise
    270286        if (source->tmpFlags & PM_SOURCE_TMPF_SUBTRACTED) {
    271287            pmSourceAdd (source, PM_MODEL_OP_FULL, maskVal);
     
    305321        Nfail ++;
    306322
    307         // re-subtract the object, leave local sky
     323        // re-subtract the object, leave local sky, re-bump noise
    308324        pmSourceCacheModel (source, maskVal);
    309325        pmSourceSub (source, PM_MODEL_OP_FULL, maskVal);
Note: See TracChangeset for help on using the changeset viewer.