Changeset 16986 for trunk/ppStack/src/ppStackReadout.c
- Timestamp:
- Mar 13, 2008, 12:21:21 PM (18 years ago)
- File:
-
- 1 edited
-
trunk/ppStack/src/ppStackReadout.c (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ppStack/src/ppStackReadout.c
r16943 r16986 12 12 #define WCS_TOLERANCE 0.001 // Tolerance for WCS 13 13 14 //#define REJECTION_FILES // Write rejection mask?15 //#define INSPECTION_FILES // Write inspection mask?16 //#define COMBINED_FILES // Write combined images?14 #define REJECTION_FILES // Write rejection mask? 15 #define INSPECTION_FILES // Write inspection mask? 16 #define COMBINED_FILES // Write combined images? 17 17 18 18 … … 36 36 psMaskType maskBad = psMetadataLookupU8(NULL, config->arguments, "MASK.BAD"); // Value to mask 37 37 psMaskType maskBlank = psMetadataLookupU8(NULL, config->arguments, "MASK.BLANK"); // Mask for blank reg. 38 float threshold = psMetadataLookupF32(NULL, config->arguments, "THRESHOLD.MASK"); // Threshold for mask deconvolution38 // float threshold = psMetadataLookupF32(NULL, config->arguments, "THRESHOLD.MASK"); // Threshold for mask deconvolution 39 39 bool useVariance = psMetadataLookupBool(&mdok, config->arguments, "VARIANCE"); // Use variance for rejection? 40 40 bool safe = psMetadataLookupBool(&mdok, config->arguments, "SAFE"); // Play safe when combining small numbers of pixels? … … 99 99 #endif 100 100 101 // Reject pixels101 // Save list of pixels to inspect 102 102 for (int i = 0; i < num; i++) { 103 103 pmStackData *data = stack->data[i]; // Data for this image 104 104 pmReadout *readout = data->readout; // Readout of interest 105 int col0 = readout->col0, row0 = readout->row0; // Offset for readout 106 int numCols = readout->image->numCols, numRows = readout->image->numRows; // Size of image 107 108 psRegion *valid = psRegionAlloc(col0, col0 + numCols, row0, row0 + numRows); // Valid region for rej 109 psPixels *reject = pmStackReject(data->pixels, valid, threshold, regions->data[i], 110 kernels->data[i]); // Pixels to reject 111 psFree(valid); 112 113 psMetadataAddPtr(readout->analysis, PS_LIST_TAIL, PPSTACK_REJECTED_PIXELS, 114 PS_DATA_PIXELS | PS_META_DUPLICATE_OK, "Rejected pixels from initial combination", 115 reject); 116 psFree(reject); // Drop reference 105 psMetadataAddPtr(readout->analysis, PS_LIST_TAIL, PPSTACK_INSPECT_PIXELS, 106 PS_DATA_PIXELS | PS_META_DUPLICATE_OK, "Pixels to inspect from initial combination", 107 data->pixels); 117 108 } 118 109
Note:
See TracChangeset
for help on using the changeset viewer.
