Changeset 14655 for trunk/psphot/src/psphotRadiusChecks.c
- Timestamp:
- Aug 23, 2007, 2:40:16 PM (19 years ago)
- File:
-
- 1 edited
-
trunk/psphot/src/psphotRadiusChecks.c (modified) (7 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/psphot/src/psphotRadiusChecks.c
r13035 r14655 6 6 static float PSF_FIT_RADIUS = 0; // radius to use in fitting (ignored if <= 0, 7 7 // and a per-object radius is calculated) 8 static pmModelRadius modelRadiusPSF;9 8 10 9 bool psphotInitRadiusPSF(const psMetadata *recipe, … … 17 16 PSF_FIT_RADIUS = psMetadataLookupF32(&status, recipe, "PSF_FIT_RADIUS"); 18 17 19 // this function specifies the radius at this the model hits the given flux20 modelRadiusPSF = pmModelRadius_GetFunction (type);21 18 return true; 22 19 } … … 34 31 if (radiusFit <= 0) { // use fixed radius 35 32 if (moments == NULL) { 36 radiusFit = model RadiusPSF(model->params, PSF_FIT_NSIGMA*moments->dSky);33 radiusFit = model->modelRadius(model->params, PSF_FIT_NSIGMA*moments->dSky); 37 34 } else { 38 radiusFit = model RadiusPSF(model->params, 1.0);35 radiusFit = model->modelRadius(model->params, 1.0); 39 36 } 40 37 } … … 62 59 63 60 // set the fit radius based on the object flux limit and the model 64 model->radiusFit = (RADIUS_TYPE) (model RadiusPSF(model->params, PSF_FIT_NSIGMA*moments->dSky) + dR + PSF_FIT_PADDING);61 model->radiusFit = (RADIUS_TYPE) (model->modelRadius (model->params, PSF_FIT_NSIGMA*moments->dSky) + dR + PSF_FIT_PADDING); 65 62 if (isnan(model->radiusFit)) psAbort("error in radius"); 66 63 … … 78 75 static float EXT_FIT_NSIGMA; 79 76 static float EXT_FIT_PADDING; 80 static pmModelRadius modelRadiusEXT;81 77 82 78 bool psphotInitRadiusEXT (psMetadata *recipe, pmModelType type) { … … 87 83 EXT_FIT_PADDING = psMetadataLookupF32 (&status, recipe, "EXT_FIT_PADDING"); 88 84 89 // this function specifies the radius at this the model hits the given flux90 modelRadiusEXT = pmModelRadius_GetFunction (type);91 85 return true; 92 86 } … … 101 95 102 96 // set the fit radius based on the object flux limit and the model 103 model->radiusFit = (RADIUS_TYPE) (model RadiusEXT(model->params, EXT_FIT_NSIGMA*moments->dSky) + EXT_FIT_PADDING);97 model->radiusFit = (RADIUS_TYPE) (model->modelRadius (model->params, EXT_FIT_NSIGMA*moments->dSky) + EXT_FIT_PADDING); 104 98 if (isnan(model->radiusFit)) psAbort("error in radius"); 105 99
Note:
See TracChangeset
for help on using the changeset viewer.
