- Timestamp:
- May 3, 2010, 8:50:52 AM (16 years ago)
- Location:
- branches/simtest_nebulous_branches
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/simtest_nebulous_branches
- Property svn:mergeinfo changed
-
branches/simtest_nebulous_branches/ppSub/src
- Property svn:ignore
-
old new 13 13 ppSubErrorCodes.c 14 14 ppSubVersionDefinitions.h 15 ppSubConvolve
-
- Property svn:ignore
-
branches/simtest_nebulous_branches/ppSub/src/ppSubLoop.c
r24862 r27840 27 27 28 28 pmConfigCamerasCull(config, NULL); 29 pmConfigRecipesCull(config, "PPSUB,PPSTATS,PSPHOT, MASKS,JPEG");29 pmConfigRecipesCull(config, "PPSUB,PPSTATS,PSPHOT,PSASTRO,MASKS,JPEG"); 30 30 31 31 … … 43 43 44 44 if (!ppSubSetMasks(config)) { 45 psError( PS_ERR_UNKNOWN, false, "Unable to set masks.");45 psError(psErrorCodeLast(), false, "Unable to set masks."); 46 46 return false; 47 47 } 48 48 49 49 if (!ppSubMatchPSFs(data)) { 50 psError( PS_ERR_UNKNOWN, false, "Unable to match PSFs.");50 psError(psErrorCodeLast(), false, "Unable to match PSFs."); 51 51 return false; 52 52 } … … 55 55 return true; 56 56 } 57 // generate the residual stamp grid for visualization 58 if (!ppSubResidualSampleJpeg(config)) { 59 psError(psErrorCodeLast(), false, "Unable to update."); 60 return false; 61 } 57 62 58 63 psMetadataAddF32(data->stats, PS_LIST_TAIL, "TIME_MATCH", 0, "Time to match PSFs", … … 66 71 67 72 if (!ppSubLowThreshold(data)) { 68 psError( PS_ERR_UNKNOWN, false, "Unable to threshold images.");73 psError(psErrorCodeLast(), false, "Unable to threshold images."); 69 74 return false; 70 75 } … … 77 82 78 83 if (!ppSubDefineOutput("PPSUB.OUTPUT", config)) { 79 psError( PS_ERR_UNKNOWN, false, "Unable to define output.");84 psError(psErrorCodeLast(), false, "Unable to define output."); 80 85 return false; 81 86 } 82 87 83 88 if (!data->quality && !ppSubMakePSF(data)) { 84 psError(PS_ERR_UNKNOWN, false, "Unable to generate PSF."); 85 return false; 89 psError(psErrorCodeLast(), false, "Unable to generate PSF."); 90 return false; 91 } 92 93 // Now we've got a PSF, blow away detections in case they're confused with real output detections 94 { 95 pmFPAview *view = ppSubViewReadout(); // View to readout 96 pmReadout *out = pmFPAfileThisReadout(config->files, view, "PPSUB.OUTPUT"); 97 if (psMetadataLookup(out->analysis, "PSPHOT.DETECTIONS")) { 98 psMetadataRemoveKey(out->analysis, "PSPHOT.DETECTIONS"); 99 } 100 psFree(view); 86 101 } 87 102 88 103 if (!ppSubReadoutSubtract(config)) { 89 psError( PS_ERR_UNKNOWN, false, "Unable to subtract images.");104 psError(psErrorCodeLast(), false, "Unable to subtract images."); 90 105 return false; 91 106 } … … 99 114 // Higher order background subtraction using psphot 100 115 if (!ppSubBackground(config)) { 101 psError( PS_ERR_UNKNOWN, false, "Unable to subtract background.");116 psError(psErrorCodeLast(), false, "Unable to subtract background."); 102 117 return false; 103 118 } … … 105 120 // Perform Variance correction (rescale within a modest range) 106 121 if (!ppSubVarianceRescale(config)) { 107 psError( PS_ERR_UNKNOWN, false, "Unable to rescale variance.");122 psError(psErrorCodeLast(), false, "Unable to rescale variance."); 108 123 return false; 109 124 } … … 115 130 116 131 if (!data->quality && !ppSubReadoutPhotometry("PPSUB.OUTPUT", data)) { 117 psError( PS_ERR_UNKNOWN, false, "Unable to perform photometry.");132 psError(psErrorCodeLast(), false, "Unable to perform photometry."); 118 133 return false; 119 134 } … … 126 141 // Perform statistics on the cell 127 142 if (!ppSubReadoutStats(data)) { 128 psError(PS_ERR_UNKNOWN, false, "Unable to collect statistics"); 129 return false; 130 } 131 143 psError(psErrorCodeLast(), false, "Unable to collect statistics"); 144 return false; 145 } 146 147 // generate the binned image used to write the jpeg 132 148 if (!ppSubReadoutJpeg(config)) { 133 psError( PS_ERR_UNKNOWN, false, "Unable to update.");149 psError(psErrorCodeLast(), false, "Unable to update."); 134 150 return false; 135 151 } … … 143 159 144 160 if (data->inverse && !ppSubDefineOutput("PPSUB.INVERSE", config)) { 145 psError( PS_ERR_UNKNOWN, false, "Unable to define inverse.");161 psError(psErrorCodeLast(), false, "Unable to define inverse."); 146 162 return false; 147 163 } 148 164 149 165 if (!ppSubReadoutInverse(config)) { 150 psError( PS_ERR_UNKNOWN, false, "Unable to invert images.");166 psError(psErrorCodeLast(), false, "Unable to invert images."); 151 167 return false; 152 168 } … … 164 180 165 181 if (!data->quality && !ppSubReadoutPhotometry("PPSUB.INVERSE", data)) { 166 psError( PS_ERR_UNKNOWN, false, "Unable to perform photometry.");182 psError(psErrorCodeLast(), false, "Unable to perform photometry."); 167 183 return false; 168 184 }
Note:
See TracChangeset
for help on using the changeset viewer.
