Changeset 28399
- Timestamp:
- Jun 17, 2010, 2:25:17 PM (16 years ago)
- File:
-
- 1 edited
-
trunk/psphot/src/psphotFitSourcesLinear.c (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/psphot/src/psphotFitSourcesLinear.c
r28013 r28399 27 27 for (int i = 0; i < num; i++) { 28 28 29 // find the currently selected readout30 pmFPAfile *file = pmFPAfileSelectSingle(config->files, filerule, i); // File of interest31 psAssert (file, "missing file?");32 33 pmReadout *readout = pmFPAviewThisReadout(view, file->fpa);34 psAssert (readout, "missing readout?");35 36 pmDetections *detections = psMetadataLookupPtr (&status, readout->analysis, "PSPHOT.DETECTIONS");37 psAssert (detections, "missing detections?");38 39 psArray *sources = detections->allSources;40 psAssert (sources, "missing sources?");41 42 pmPSF *psf = psMetadataLookupPtr (&status, readout->analysis, "PSPHOT.PSF");43 psAssert (psf, "missing psf?");44 45 if (!psphotFitSourcesLinearReadout (recipe, readout, sources, psf, final)) {29 // find the currently selected readout 30 pmFPAfile *file = pmFPAfileSelectSingle(config->files, filerule, i); // File of interest 31 psAssert (file, "missing file?"); 32 33 pmReadout *readout = pmFPAviewThisReadout(view, file->fpa); 34 psAssert (readout, "missing readout?"); 35 36 pmDetections *detections = psMetadataLookupPtr (&status, readout->analysis, "PSPHOT.DETECTIONS"); 37 psAssert (detections, "missing detections?"); 38 39 psArray *sources = detections->allSources; 40 psAssert (sources, "missing sources?"); 41 42 pmPSF *psf = psMetadataLookupPtr (&status, readout->analysis, "PSPHOT.PSF"); 43 psAssert (psf, "missing psf?"); 44 45 if (!psphotFitSourcesLinearReadout (recipe, readout, sources, psf, final)) { 46 46 psError (PSPHOT_ERR_CONFIG, false, "failed to fit sources (linear) for %s entry %d", filerule, i); 47 return false;48 }47 return false; 48 } 49 49 } 50 50 return true; … … 59 59 60 60 if (!sources->n) { 61 psLogMsg ("psphot", PS_LOG_INFO, "no sources, skipping linear fit");62 return true;61 psLogMsg ("psphot", PS_LOG_INFO, "no sources, skipping linear fit"); 62 return true; 63 63 } 64 64 … … 150 150 151 151 if (fitSources->n == 0) { 152 psFree(fitSources); 152 153 return true; 153 154 }
Note:
See TracChangeset
for help on using the changeset viewer.
