IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Jul 9, 2010, 10:56:32 AM (16 years ago)
Author:
eugene
Message:

changed pmSourceFitModel and related APIs to pass a structure of fit options; this lets us change the options between soruces within the multithreaded context; also re-organized the include orders to avoid conflicts

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/eam_branches/ipp-20100621/psModules/src/objects/pmSourcePhotometry.c

    r28440 r28643  
    2222#include "pmFPA.h"
    2323#include "pmFPAMaskWeight.h"
     24
     25#include "pmTrend2D.h"
     26#include "pmResiduals.h"
     27#include "pmGrowthCurve.h"
    2428#include "pmSpan.h"
     29#include "pmFootprintSpans.h"
    2530#include "pmFootprint.h"
    2631#include "pmPeaks.h"
    2732#include "pmMoments.h"
    28 #include "pmGrowthCurve.h"
    29 #include "pmResiduals.h"
    30 #include "pmTrend2D.h"
     33#include "pmModelFuncs.h"
     34#include "pmModel.h"
     35#include "pmModelUtils.h"
     36#include "pmModelClass.h"
     37#include "pmSourceMasks.h"
     38#include "pmSourceExtendedPars.h"
     39#include "pmSourceDiffStats.h"
     40#include "pmSource.h"
     41#include "pmSourceFitModel.h"
    3142#include "pmPSF.h"
    32 #include "pmModel.h"
    33 #include "pmSource.h"
    34 #include "pmModelClass.h"
     43#include "pmPSFtry.h"
     44
    3545#include "pmSourcePhotometry.h"
    3646
     
    257267    PS_ASSERT_PTR_NON_NULL(image, false);
    258268    PS_ASSERT_PTR_NON_NULL(mask, false);
    259     PS_ASSERT_PTR_NON_NULL(model, false);
     269
     270    if (DO_SKY) {
     271        PS_ASSERT_PTR_NON_NULL(model, false);
     272    }
    260273
    261274    float apSum = 0;
     
    271284    psF32 **imData = image->data.F32;
    272285    psImageMaskType **mkData = mask->data.PS_TYPE_IMAGE_MASK_DATA;
     286    int nAperPix = 0;
    273287
    274288    // measure apMag
    275     for (int ix = 0; ix < image->numCols; ix++) {
    276         for (int iy = 0; iy < image->numRows; iy++) {
     289    for (int iy = 0; iy < image->numRows; iy++) {
     290        for (int ix = 0; ix < image->numCols; ix++) {
    277291            if (mkData[iy][ix] & maskVal)
    278292                continue;
    279293            apSum += imData[iy][ix] - sky;
     294            nAperPix ++;
     295            // fprintf (stderr, "aper: %d %d  %f  %f  %f\n", ix, iy, sky, imData[iy][ix], apSum);
    280296        }
    281297    }
Note: See TracChangeset for help on using the changeset viewer.