IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Aug 3, 2011, 10:30:02 AM (15 years ago)
Author:
eugene
Message:

add new window function using first radial moment; use new sersic guess function

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/eam_branches/ipp-20110710/psphot/src/psphotSersicModelClass.c

    r31966 r31990  
    505505}
    506506
    507 void psphotWriteGuess(pmModel *model, float dKronMag, float PSFratio, float ASPratio);
     507# define TIMING false
    508508
    509509bool psphotSersicModelClassGuessPCM (pmPCMdata *pcm, pmSource *source) {
     510
     511    float t1, t2, t4, t5;
     512    if (TIMING) { psTimerStart ("SersicGuess"); }
    510513
    511514    psF32 *PAR = pcm->modelConv->params->data.F32;
     
    549552
    550553    // find the containing model class:
     554
     555    if (TIMING) { t1 = psTimerMark ("SersicGuess"); }
    551556
    552557    psphotSersicModelClass *class = NULL;   
     
    561566    }
    562567       
     568    if (TIMING) { t2 = psTimerMark ("SersicGuess"); }
     569
    563570    psAssert (class, "PSFratio and ASPratio must be in range");
    564571
     
    610617    PAR[PM_PAR_I0]  = 1.0;
    611618
     619    if (TIMING) { t4 = psTimerMark ("SersicGuess"); }
     620
    612621    // set the normalization by linear fit between model and data
    613622    psphotSersicModelNorm (pcm, source);
     623
     624    if (TIMING) { t5 = psTimerMark ("SersicGuess"); }
     625
     626    if (TIMING) {
     627        fprintf (stderr, "guess, t1: %6.4f, t2: %6.4f, t4: %6.4f, t5: %6.4f\n", t1, t2, t4, t5);
     628    }
    614629
    615630    // float flux = pcm->modelConv->modelFlux(pcm->modelConv->params);
     
    617632    // float Io = pow(10.0, -0.4*(totalMag - normMag));
    618633    // PAR[PM_PAR_I0] = Io;
    619 
    620     psphotWriteGuess(pcm->modelConv, dKronMag, PSFratio, ASPratio);
    621634
    622635    return true;
Note: See TracChangeset for help on using the changeset viewer.