Changeset 24399
- Timestamp:
- Jun 14, 2009, 10:30:29 AM (17 years ago)
- Location:
- trunk
- Files:
-
- 3 added
- 5 edited
-
Ohana/src/libautocode/def/autocode.c (modified) (2 diffs)
-
Ohana/src/libautocode/def/cmf-ps1-v1.d (modified) (2 diffs)
-
Ohana/src/libdvo/Makefile (modified) (1 diff)
-
ppImage/notes.txt (modified) (1 diff)
-
psModules/src/camera/pmFPAMaskWeight.c (modified) (2 diffs)
-
psconfig/tagsets/ipp-2.9.dist (added)
-
psconfig/tagsets/ipp-2.9.libs (added)
-
psconfig/tagsets/ipp-2.9.perl (added)
Legend:
- Unmodified
- Added
- Removed
-
trunk/Ohana/src/libautocode/def/autocode.c
r15038 r24399 7 7 8 8 if (size != $SIZE) { 9 fprintf (stderr, "ERROR: mismatch in data types $STRUCT: %d vs %d\n", 10 size, $SIZE); 11 exit (1); 9 fprintf (stderr, "WARNING: mismatch in data types $STRUCT: %d vs %d\n", size, $SIZE); 10 return (FALSE); 12 11 } 13 12 … … 26 25 } 27 26 27 $STRUCT *gfits_downsize_and_convert_$STRUCT ($STRUCT *data, int size, int nitems) { 28 29 int i; 30 unsigned char *byte, tmp; 31 $STRUCT *output; 32 33 if ($SIZE > size) { 34 fprintf (stderr, "ERROR: uncorrectable mismatch in data types $STRUCT: %d vs %d\n", size, $SIZE); 35 exit (1); 36 } 37 38 // allocate a new array 39 ALLOCATE (output, $STRUCT, nitems); 40 for (i = 0; i < nitems; i++) { 41 memcpy (&output[i], &data[i], $SIZE); 42 } 43 44 /* provide initial values to avoid compiler warnings for non-BYTE_SWAP arch */ 45 i = tmp = 0; 46 byte = NULL; 47 48 # ifdef BYTE_SWAP 49 byte = (unsigned char *) output; 50 for (i = 0; i < nitems; i++, byte += size) { 51 /** BYTE SWAP **/ 52 } 53 # endif 54 55 return (output); 56 } 57 28 58 /*** add test of EXTNAME and header-defined columns? ***/ 29 59 /* return internal structure representation */ 30 60 $STRUCT *gfits_table_get_$STRUCT (FTable *ftable, int *Ndata, int *swapped) { 31 61 32 $STRUCT *data ;62 $STRUCT *data, *output; 33 63 34 64 *Ndata = ftable[0].header[0].Naxis[1]; 35 65 data = ($STRUCT *) ftable[0].buffer; 36 66 if ((swapped == NULL) || (*swapped == FALSE)) { 37 gfits_convert_$STRUCT (data, sizeof ($STRUCT), *Ndata); 67 if (!gfits_convert_$STRUCT (data, sizeof ($STRUCT), *Ndata)) { 68 output = gfits_downsize_and_convert_$STRUCT (data, sizeof ($STRUCT), *Ndata); 69 free (ftable[0].buffer); 70 ftable[0].buffer = output; 71 // XXX do I need to change NX? 72 } 38 73 gfits_table_scale_data (ftable); 39 74 if (swapped != NULL) *swapped = TRUE; -
trunk/Ohana/src/libautocode/def/cmf-ps1-v1.d
r21508 r24399 3 3 EXTNAME CMF_PS1_V1 4 4 TYPE BINTABLE 5 SIZE 1 285 SIZE 136 6 6 7 7 # elements of data structure / FITS table … … 11 11 FIELD dX, X_PSF_SIG, float, x coord error, pixels 12 12 FIELD dY, Y_PSF_SIG, float, y coord error, pixels 13 FIELD RA, RA_PSF, float,PSF RA coord, degrees14 FIELD DEC, DEC_PSF, float,PSF DEC coord, degrees13 FIELD RA, RA_PSF, double, PSF RA coord, degrees 14 FIELD DEC, DEC_PSF, double, PSF DEC coord, degrees 15 15 FIELD posangle, POSANGLE, float, Posangle at source, degrees 16 16 FIELD pltscale, PLTSCALE, float, Plate Scale at source, arcsec/pixel -
trunk/Ohana/src/libdvo/Makefile
r21508 r24399 118 118 cleandef: 119 119 cd $(AUTO) && make clean 120 121 .PRECIOUS: $(ASRC)/%.c -
trunk/ppImage/notes.txt
r14620 r24399 1 1 2 ppImage pmFPAfiles: 2 20090611 : adjusting things to allow the readnoise to be an image map for each cell 3 3 4 pmFPAfile *input = pmFPAfileDefineFromArgs (&status, config, "PPIMAGE.INPUT", "INPUT"); 5 pmFPAfile *inputMask = pmFPAfileBindFromArgs(&status, input, config, "PPIMAGE.INPUT.MASK", "INPUT.MASK"); 6 pmFPAfile *inputWeight = pmFPAfileBindFromArgs(&status, input, config, "PPIMAGE.INPUT.WEIGHT", "INPUT.WEIGHT"); 7 pmFPAfile *output = pmFPAfileDefineOutput(config, input->fpa, "PPIMAGE.OUTPUT"); 8 pmFPAfile *outMask = pmFPAfileDefineOutput(config, input->fpa, "PPIMAGE.OUTPUT.MASK"); 9 pmFPAfile *outWeight = pmFPAfileDefineOutput(config, input->fpa, "PPIMAGE.OUTPUT.WEIGHT"); 10 pmFPAfile *chipImage = pmFPAfileDefineChipMosaic(config, input->fpa, "PPIMAGE.CHIP"); 11 pmFPAfile *chipMask = pmFPAfileDefineOutput(config, chipImage->fpa, "PPIMAGE.CHIP.MASK"); 12 pmFPAfile *chipWeight = pmFPAfileDefineOutput(config, chipImage->fpa, "PPIMAGE.CHIP.WEIGHT"); 13 pmFPAfile *byFPA1 = pmFPAfileDefineFPAMosaic(config, input->fpa, "PPIMAGE.OUTPUT.FPA1"); 14 pmFPAfile *byFPA2 = pmFPAfileDefineFPAMosaic(config, input->fpa, "PPIMAGE.OUTPUT.FPA2"); 4 * pmReadoutSetVaraince : when variance is created, we are suppling a single CELL.READNOISE value -- change this to an optional image (carried through concepts?) 15 5 16 pmFPAfile *psphotInput = pmFPAfileDefineFromFPA (config, chipImage->fpa, 1, 1, "PSPHOT.INPUT"); 17 pmFPAfile *psphotOutput = psMetadataLookupPtr (&status, config->files, "PSPHOT.OUTPUT"); 18 pmFPAfile *psastroInput = pmFPAfileDefineInput (config, psphotOutput->fpa, "PSASTRO.INPUT"); 6 I need to: 19 7 20 pmFPAfile *bin1 = pmFPAfileDefineFromFPA (config, chipImage->fpa, options->xBin1, options->yBin1, "PPIMAGE.BIN1"); 21 pmFPAfile *bin2 = pmFPAfileDefineFromFPA (config, chipImage->fpa, options->xBin2, options->yBin2, "PPIMAGE.BIN2"); 22 pmFPAfile *jpg1 = pmFPAfileDefineOutput (config, byFPA1->fpa, "PPIMAGE.JPEG1"); 23 pmFPAfile *jpg2 = pmFPAfileDefineOutput (config, byFPA2->fpa, "PPIMAGE.JPEG2"); 8 * define a format for the readnoise map (image map in SPLIT/MEF format?) 9 * load the readnoise map 10 11 * supply the map for each cell to the pmReadoutSetVariance (pointer to ppImageMap?) 12 pmReadoutSetVariance -> add psImageMap to API (also pmReadoutGenerateVariance) 13 14 * add recipe information to define the source of the READNOISE info. 15 -
trunk/psModules/src/camera/pmFPAMaskWeight.c
r23989 r24399 228 228 229 229 // a negative variance is non-sensical. if the image value drops below 1, the variance must be 1. 230 // XXX this calculation is wrong: limit is 1 e-, but this is in DN 230 231 readout->variance = (psImage*)psUnaryOp(readout->variance, readout->variance, "abs"); 231 232 readout->variance = (psImage*)psBinaryOp(readout->variance, readout->variance, "max", … … 239 240 } 240 241 242 // XXX if readnoise is based on an image map, we need to apply it here 241 243 readout->variance = (psImage*)psBinaryOp(readout->variance, readout->variance, "+", 242 244 psScalarAlloc(readnoise*readnoise/gain/gain, PS_TYPE_F32));
Note:
See TracChangeset
for help on using the changeset viewer.
