Changeset 32348 for trunk/psphot/src/psphotReadout.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/psphotReadout.c
r31452 r32348 102 102 return psphotReadoutCleanup (config, view, filerule); 103 103 } 104 105 # if (0)106 // XXX test to mask outliers, not very helpful107 // mask the high values in the image (with MARK)108 if (!psphotMaskBackground (config, view, filerule)) {109 return psphotReadoutCleanup (config, view, filerule);110 }111 112 // generate a background model (median, smoothed image)113 if (!psphotModelBackground (config, view, filerule)) {114 return psphotReadoutCleanup (config, view, filerule);115 }116 # endif117 118 104 if (!psphotSubtractBackground (config, view, filerule)) { 119 105 return psphotReadoutCleanup (config, view, filerule); … … 137 123 } 138 124 139 // construct sources and measure basic stats (saved on detections->newSources) 125 // construct sources and measure moments and other basic stats (saved on detections->newSources) 126 // all sources use the auto-scaled window appropriate to a PSF, except for the saturated 127 // stars : these use a larger window (3x the basic window) 140 128 if (!psphotSourceStats (config, view, filerule, true)) { // pass 1 141 129 psError(PSPHOT_ERR_UNKNOWN, false, "failure to generate sources"); … … 153 141 154 142 // mark blended peaks PS_SOURCE_BLEND (detections->newSources) 155 if (!psphotBasicDeblend (config, view, filerule)) { 143 // XXX I've deactivated this because it was preventing galaxies close to stars from being 144 // XXX fitted as an extended source. 145 if (false && !psphotBasicDeblend (config, view, filerule)) { 156 146 psError (PSPHOT_ERR_UNKNOWN, false, "failed on deblend analysis"); 157 147 return psphotReadoutCleanup (config, view, filerule); … … 200 190 psphotDumpChisqs (config, view, filerule); 201 191 202 // XXX re-measure the kron mags with models subtracted 203 psphotKronMasked(config, view, filerule); 192 // re-measure the kron mags with models subtracted. this pass uses a circular window of size PSF_MOMENTS_RADIUS (same window used to measure the psf-scale moments) 193 194 // but this is chosen above to be appropriate for the PSF objects (not galaxies) 195 // psphotKronMasked(config, view, filerule); 196 psphotKronIterate(config, view, filerule); 204 197 205 198 // identify CRs and extended sources (only unmeasured sources are measured) … … 240 233 psphotSubNoise (config, view, filerule); // pass 1 (detections->allSources) 241 234 242 // define new sources based on only the new peaks 235 // define new sources based on only the new peaks & measure moments 243 236 // NOTE: new sources are saved on detections->newSources 244 237 psphotSourceStats (config, view, filerule, false); // pass 2 (detections->newSources) … … 312 305 pass1finish: 313 306 314 // XXX re-measure the kron mags with models subtracted 315 psphotKronMasked(config, view, filerule); 307 // re-measure the kron mags with models subtracted 308 // psphotKronMasked(config, view, filerule); 309 psphotKronIterate(config, view, filerule); 316 310 317 311 // measure source size for the remaining sources … … 321 315 psphotExtendedSourceAnalysis (config, view, filerule); // pass 1 (detections->allSources) 322 316 psphotExtendedSourceFits (config, view, filerule); // pass 1 (detections->allSources) 323 psphotRadialApertures(config, view, filerule );317 psphotRadialApertures(config, view, filerule, 0); 324 318 325 319 finish: … … 359 353 } 360 354 355 psLogMsg ("psphot.readout", PS_LOG_WARN, "complete psphot readout : %f sec\n", psTimerMark ("psphotReadout")); 356 361 357 // create the exported-metadata and free local data 362 358 return psphotReadoutCleanup(config, view, filerule);
Note:
See TracChangeset
for help on using the changeset viewer.
