Changeset 32348 for trunk/psphot/src/psphotFitSourcesLinear.c
- Timestamp:
- Sep 6, 2011, 1:32:31 PM (15 years ago)
- Location:
- trunk/psphot
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/psphot
-
trunk/psphot/src
- Property svn:ignore
-
old new 22 22 psphotMakePSF 23 23 psphotStack 24 psphotModelTest
-
- Property svn:ignore
-
trunk/psphot/src/psphotFitSourcesLinear.c
r31452 r32348 17 17 bool status = true; 18 18 19 fprintf (stdout, "\n"); 20 psLogMsg ("psphot", PS_LOG_INFO, "--- psphot Fit Source (Linear) ---"); 21 19 22 // select the appropriate recipe information 20 23 psMetadata *recipe = psMetadataLookupPtr (&status, config->recipes, PSPHOT_RECIPE); … … 23 26 int num = psphotFileruleCount(config, filerule); 24 27 28 // skip the chisq image (optionally?) 29 int chisqNum = psMetadataLookupS32 (&status, config->arguments, "PSPHOT.CHISQ.NUM"); 30 if (!status) chisqNum = -1; 31 25 32 // loop over the available readouts 26 33 for (int i = 0; i < num; i++) { 34 if (i == chisqNum) continue; // skip chisq image 27 35 28 36 // find the currently selected readout … … 190 198 pmModel *model = pmSourceGetModel (&isPSF, source); 191 199 200 // clear the 'mark' pixels and remask on the fit aperture 192 201 psImageMaskPixels (source->maskObj, "AND", PS_NOT_IMAGE_MASK(markVal)); 193 202 psImageKeepCircle (source->maskObj, source->peak->x, source->peak->y, model->fitRadius, "OR", markVal); … … 349 358 model->dparams->data.F32[PM_PAR_I0] = errors->data.F32[i]; 350 359 351 // subtract object 360 // clear the 'mark' pixels so the subtraction covers the full window 361 psImageMaskPixels (source->maskObj, "AND", PS_NOT_IMAGE_MASK(markVal)); 362 363 // subtract object & add noise 352 364 pmSourceSub (source, PM_MODEL_OP_FULL, maskVal); 353 365 } … … 374 386 psFree (border); 375 387 376 psLogMsg ("psphot.ensemble", PS_LOG_ INFO, "measure ensemble of PSFs: %f sec\n", psTimerMark ("psphot.linear"));388 psLogMsg ("psphot.ensemble", PS_LOG_WARN, "measure ensemble of PSFs: %f sec\n", psTimerMark ("psphot.linear")); 377 389 378 390 psphotVisualPlotChisq (sources);
Note:
See TracChangeset
for help on using the changeset viewer.
