IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 20077


Ignore:
Timestamp:
Oct 12, 2008, 3:59:05 PM (18 years ago)
Author:
eugene
Message:

pixel weight now measured for sources without valid apertures; different result for SN < lim vs NaN ap mag

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/psModules/src/objects/pmSourcePhotometry.c

    r19905 r20077  
    33 *  @author EAM, IfA; GLG, MHPCC
    44 *
    5  *  @version $Revision: 1.44 $ $Name: not supported by cvs2svn $
    6  *  @date $Date: 2008-10-06 13:03:40 $
     5 *  @version $Revision: 1.45 $ $Name: not supported by cvs2svn $
     6 *  @date $Date: 2008-10-13 01:59:05 $
    77 *
    88 *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
     
    141141    }
    142142
    143     if (!isfinite(SN) || (SN < AP_MIN_SN)) {
     143    // measure the contribution of included pixels
     144    if (mode & PM_SOURCE_PHOT_WEIGHT) {
     145        pmSourcePixelWeight (&source->pixWeight, model, source->pixels, source->maskObj, maskVal);
     146    }
     147
     148    // measure the aperture magnitude, if (SN > AP_MIN_SN)
     149    if (!isfinite(SN)) {
    144150        psTrace ("psModules.objects", 3, "fail mag : bad SN: %f (limit: %f)", SN, AP_MIN_SN);
    145151        return false;
     152    }
     153
     154    // measure the aperture magnitude, if (SN > AP_MIN_SN)
     155    if (SN < AP_MIN_SN) {
     156        psTrace ("psModules.objects", 3, "skip ap mag : SN < limit : %f vs %f)", SN, AP_MIN_SN);
     157        return true;
    146158    }
    147159
     
    230242    }
    231243
    232     // measure the contribution of included pixels
    233     if (mode & PM_SOURCE_PHOT_WEIGHT) {
    234         pmSourcePixelWeight (&source->pixWeight, model, source->pixels, source->maskObj, maskVal);
    235     }
    236 
    237244    // measure object aperture photometry
    238245    status = pmSourcePhotometryAper  (&source->apMag, model, flux, mask, maskVal);
Note: See TracChangeset for help on using the changeset viewer.