Changeset 21450
- Timestamp:
- Feb 11, 2009, 6:43:55 PM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/eam_branch_20090208/psphot/src/psphotDetectReadout.c
r21392 r21450 22 22 // Generate the mask and weight images, including the user-defined analysis region of interest 23 23 psphotSetMaskAndWeight (config, readout, recipe); 24 if (!strcasecmp (breakPt, "NOTHING")) {25 return psphotReadoutCleanup(config, readout, recipe, NULL, NULL, NULL);26 }27 24 28 25 // load the psf model, if suppled. FWHM_X,FWHM_Y,etc are saved in the recipe … … 38 35 39 36 // include externally-supplied sources (supplied as PSPHOT.INPUT.CMF) 40 pmDetections *detections = psphotDetectionsFromSources (config, inSources); 41 if (!detections || !detections->peaks) { 42 psError(PSPHOT_ERR_ARGUMENTS, true, "Can't find PSF stars"); 43 return psphotReadoutCleanup(config, readout, recipe, detections, NULL, NULL); 44 } 45 46 // construct sources and measure basic stats 47 psArray *sources = psphotSourceStats (config, readout, detections); 48 if (!sources) return false; 49 if (!strcasecmp (breakPt, "PEAKS")) { 50 return psphotReadoutCleanup(config, readout, recipe, detections, psf, sources); 51 } 52 53 // classify sources based on moments, brightness 54 if (!psphotRoughClass (readout, sources, recipe, havePSF)) { 55 psLogMsg ("psphot", 3, "failed to find a valid PSF clump for image"); 56 return psphotReadoutCleanup (config, readout, recipe, detections, psf, sources); 57 } 37 psphotSetSourceParams (config, sources, psf); 58 38 59 39 // calculate source magnitudes … … 63 43 return psphotReadoutCleanup(config, readout, recipe, detections, psf, sources); 64 44 } 45 46 // deep in pmSourcePixelWeight, we need the following items for each location of interest: 47 // pmModel *model (should be a realized version of the PSF, can have unity normalization) 48 // psImage *mask (local subimage of mask for source) 49 // psImageMaskType maskVal (from recipe & mask header) 50 51 { 52 pmModel *model = pmModelFromPSFforXY (psf, x, y, 1.0); 53 } 54
Note:
See TracChangeset
for help on using the changeset viewer.
