Changeset 14275 for trunk/ppStack/src/ppStackReadout.c
- Timestamp:
- Jul 17, 2007, 1:53:35 PM (19 years ago)
- File:
-
- 1 edited
-
trunk/ppStack/src/ppStackReadout.c (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ppStack/src/ppStackReadout.c
r13613 r14275 45 45 46 46 float seeing = psMetadataLookupF32(NULL, inputFile->fpa->analysis, "PPSTACK.SEEING"); // Seeing FWHM 47 float weight = psMetadataLookupF32(NULL, inputFile->fpa->analysis, "PPSTACK.WEIGHT"); // Rel. weight 47 float weighting = psMetadataLookupF32(NULL, inputFile->fpa->analysis, 48 "PPSTACK.WEIGHTING"); // Relative weighting 48 49 float scale = psMetadataLookupF32(NULL, inputFile->fpa->analysis, "PPSTACK.SCALE"); // Rel. scale 49 50 … … 77 78 totExposure += exposure; // Total exposure time 78 79 (void)psBinaryOp(ro->image, ro->image, "/", psScalarAlloc(exposure, PS_TYPE_F32)); 79 pmStackData *data = pmStackDataAlloc(ro, seeing, weight); // Data to stack 80 if (ro->weight) { 81 (void)psBinaryOp(ro->weight, ro->weight, "/", psScalarAlloc(exposure, PS_TYPE_F32)); 82 } 83 pmStackData *data = pmStackDataAlloc(ro, seeing, weighting); // Data to stack 80 84 psArrayAdd(stack, ARRAY_BUFFER, data); 81 85 psFree(data); // Drop reference … … 100 104 } 101 105 102 #if 1106 #ifdef INSPECTION_FILES 103 107 { 104 108 psFits *fits = psFitsOpen("combined.fits", "w"); … … 131 135 } 132 136 133 #if 1137 #ifdef REJECTION_FILES 134 138 for (int i = 0; i < num; i++) { 135 139 pmStackData *data = stack->data[i]; // Data for this image … … 157 161 // Restore image to counts using the total exposure time 158 162 (void)psBinaryOp(outRO->image, outRO->image, "*", psScalarAlloc(totExposure, PS_TYPE_F32)); 163 if (outRO->weight) { 164 (void)psBinaryOp(outRO->weight, outRO->weight, "*", psScalarAlloc(totExposure, PS_TYPE_F32)); 165 } 159 166 psMetadataAddF32(outRO->parent->concepts, PS_LIST_TAIL, "CELL.EXPOSURE", PS_META_REPLACE, 160 167 "Summed exposure time (sec)", totExposure);
Note:
See TracChangeset
for help on using the changeset viewer.
