Changeset 17819
- Timestamp:
- May 28, 2008, 8:20:44 AM (18 years ago)
- Location:
- trunk/ppSub/src
- Files:
-
- 2 edited
-
ppSubCamera.c (modified) (2 diffs)
-
ppSubReadout.c (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ppSub/src/ppSubCamera.c
r17813 r17819 142 142 return false; 143 143 } 144 if ( input->type != PM_FPA_FILE_IMAGE) {144 if (psphot->type != PM_FPA_FILE_IMAGE) { 145 145 psError(PS_ERR_IO, true, "PSPHOT.INPUT is not of type IMAGE"); 146 146 return false; … … 151 151 return false; 152 152 } 153 154 // Internal-ish file for getting the PSF from the matched addition 155 pmFPAfile *psf = pmFPAfileDefineSkycell(config, output->fpa, "PSPHOT.PSF.LOAD"); 156 if (!psf) { 157 psError(PS_ERR_IO, false, "Failed to build FPA from PSPHOT.PSF.LOAD"); 158 return false; 159 } 160 if (psf->type != PM_FPA_FILE_PSF) { 161 psError(PS_ERR_IO, true, "PSPHOT.PSF.LOAD is not of type PSF"); 162 return false; 163 } 164 pmFPAfileActivate(config->files, false, "PSPHOT.PSF.LOAD"); 165 153 166 } 154 167 -
trunk/ppSub/src/ppSubReadout.c
r17813 r17819 213 213 return false; 214 214 } 215 const char *breakpoint = psMetadataLookupStr( NULL, recipe, "BREAK_POINT"); // Current break point215 const char *breakpoint = psMetadataLookupStr(&mdok, recipe, "BREAK_POINT"); // Current break point 216 216 psMetadataAddStr(recipe, PS_LIST_TAIL, "BREAK_POINT", PS_META_REPLACE, 217 217 "ALTERED break point for psphot operations", "PSFMODEL"); … … 223 223 } 224 224 225 psMetadataAddStr(recipe, PS_LIST_TAIL, "BREAK_POINT", PS_META_REPLACE, 226 "RESTORED break point for psphot operations", breakpoint); 225 if (breakpoint) { 226 psMetadataAddStr(recipe, PS_LIST_TAIL, "BREAK_POINT", PS_META_REPLACE, 227 "RESTORED break point for psphot operations", breakpoint); 228 } 229 230 // Blow away the sources psphot found --- they're irrelevant for the subtraction 231 pmReadout *photRO = pmFPAviewThisReadout(view, photFile->fpa); // Readout with sources 232 psMetadataRemoveKey(photRO->analysis, "PSPHOT.SOURCES"); 233 psMetadataRemoveKey(photRO->analysis, "PSPHOT.HEADER"); 234 235 pmPSF *psf = psMetadataLookupPtr(NULL, photRO->parent->parent->analysis, "PSPHOT.PSF"); // PSF 236 if (!psf) { 237 psError(PS_ERR_UNEXPECTED_NULL, true, "Unable to find PSF from psphot"); 238 return false; 239 } 240 241 pmCell *psfCell = pmFPAfileThisCell(config->files, view, "PSPHOT.PSF.LOAD"); 242 if (!psfCell) { 243 psError(PS_ERR_UNEXPECTED_NULL, true, "Unable to find file PSPHOT.PSF.LOAD"); 244 return false; 245 } 246 pmReadout *psfRO = pmReadoutAlloc(psfCell); 247 psMetadataAddPtr(psfRO->parent->parent->analysis, PS_LIST_TAIL, "PSPHOT.PSF", PS_DATA_UNKNOWN, 248 "PSF from matched addition", psf); 249 psFree(psfRO); // Drop reference 227 250 } 228 251 … … 309 332 310 333 pmFPAfileActivate(config->files, false, "PSPHOT.INPUT"); 334 pmFPAfileActivate(config->files, false, "PSPHOT.LOAD.PSF"); 311 335 312 336 if (stats) {
Note:
See TracChangeset
for help on using the changeset viewer.
