IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Nov 19, 2006, 7:26:08 PM (20 years ago)
Author:
eugene
Message:

working on global linear fit with sky level

File:
1 edited

Legend:

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

    r9813 r10096  
    1818
    1919    // set fitting method to use non-poisson errors (local sky error)
    20     pmSourceFitModelInit (15, 0.1, false);
     20    float SKY_STDEV = psMetadataLookupF32 (&status, recipe, "SKY_STDEV");
     21    if (!status) {
     22      SKY_STDEV = 1.0;
     23        psWarning("SKY_STDEV is not set --- defaulting to %f\n", SKY_STDEV);
     24    }
     25    // use poissonian errors or local-sky errors
     26    bool POISSON_ERRORS = psMetadataLookupBool (&status, recipe, "POISSON_ERRORS");
     27    if (!status) {
     28        POISSON_ERRORS = true;
     29        psWarning("POISSON_ERRORS is not set in the recipe --- defaulting to true.\n");
     30    }
     31    pmSourceFitModelInit (15, 0.1, PS_SQR(SKY_STDEV), POISSON_ERRORS);
    2132
    2233    // option to limit analysis to a specific region
Note: See TracChangeset for help on using the changeset viewer.