Changeset 33691
- Timestamp:
- Apr 3, 2012, 5:51:18 PM (14 years ago)
- Location:
- trunk/psphot/src
- Files:
-
- 2 edited
-
psphotImageLoop.c (modified) (2 diffs)
-
psphotSetNFrames.c (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/psphot/src/psphotImageLoop.c
r32348 r33691 75 75 pmFPAfileActivate (config->files, false, "PSPHOT.MASK"); 76 76 pmFPAfileActivate (config->files, false, "PSPHOT.VARIANCE"); 77 // do not load the exposure number file yet file until we are done with the psphot analysis 78 pmFPAfileActivate (config->files, false, "PSPHOT.EXPNUM"); 77 79 if (!pmFPAfileIOChecks (config, view, PM_FPA_BEFORE)) ESCAPE ("failed input for Chip in psphot."); 78 80 79 81 // re-activate files so they will be closed and freed below 80 pmFPAfileActivate (config->files, true, NULL); 82 // XXX: Defer this 83 // pmFPAfileActivate (config->files, true, NULL); 81 84 82 85 // there is now only a single chip (multiple readouts?). loop over it and process … … 150 153 } 151 154 } 152 // save output which is saved at the chip level 153 if (!pmFPAfileIOChecks (config, view, PM_FPA_AFTER)) ESCAPE ("failed output for Chip in psphot."); 155 // Defer output and closing of files until we've (possibly) done the NFrames analysis below 156 pmFPAfileActivate (config->files, false, NULL); 157 158 if (!pmFPAfileIOChecks (config, view, PM_FPA_AFTER)) ESCAPE ("failed pmFPAfileIOChecks for Chip in psphot."); 154 159 } 155 // save output which is saved at the fpa level 160 if (!pmFPAfileIOChecks (config, view, PM_FPA_AFTER)) ESCAPE ("failed pmFPAfileIOChecks for FPA in psphot."); 161 162 // activate the EXPNUM image, cause it to be read in (if it exists), use it to set N Frames for the sources 163 // and finally iterate up to trigger writing of the output files 164 pmFPAfileActivate (config->files, true, "PSPHOT.EXPNUM"); 165 while ((chip = pmFPAviewNextChip (view, input->fpa, 1)) != NULL) { 166 if (!pmFPAfileIOChecks (config, view, PM_FPA_BEFORE)) ESCAPE ("failed attempting to load EXPNUM input for Chip in psphot."); 167 while ((cell = pmFPAviewNextCell (view, input->fpa, 1)) != NULL) { 168 while ((readout = pmFPAviewNextReadout (view, input->fpa, 1)) != NULL) { 169 if (! readout->data_exists) { continue; } 170 if (!psphotSetNFrames (config, view, "PSPHOT.INPUT")) ESCAPE ("failed to setNFrames."); 171 } 172 } 173 // now activate all files to trigger the output 174 pmFPAfileActivate (config->files, true, NULL); 175 if (!pmFPAfileIOChecks (config, view, PM_FPA_AFTER)) ESCAPE ("failed to iterate up Chip in psphot."); 176 } 156 177 if (!pmFPAfileIOChecks (config, view, PM_FPA_AFTER)) ESCAPE ("failed ouput for FPA in psphot."); 157 178 -
trunk/psphot/src/psphotSetNFrames.c
r33690 r33691 42 42 return true; 43 43 } 44 psLogMsg ("psphot", PS_LOG_INFO, "Found EXPNUM image for input %d", index); 44 45 45 46 pmDetections *detections = psMetadataLookupPtr (&status, readout->analysis, "PSPHOT.DETECTIONS");
Note:
See TracChangeset
for help on using the changeset viewer.
