Changeset 28623 for trunk/ppTranslate/src/ppMops.h
- Timestamp:
- Jul 7, 2010, 10:44:29 AM (16 years ago)
- File:
-
- 1 edited
-
trunk/ppTranslate/src/ppMops.h (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ppTranslate/src/ppMops.h
r28243 r28623 7 7 #define IN_EXTNAME "SkyChip.psf" // Extension name for data in input 8 8 #define OBSERVATORY_CODE "F51" // IAU Observatory Code 9 #define OUT_EXTNAME "MOPS_TRANSIENT_DETECTIONS" // Extension name for data in output 10 #define SOURCE_MASK (PM_SOURCE_MODE_FAIL | PM_SOURCE_MODE_BADPSF | PM_SOURCE_MODE_SATURATED | \ 11 PM_SOURCE_MODE_CR_LIMIT | PM_SOURCE_MODE_SKY_FAILURE) // Flags to exclude 9 12 10 13 // Configuration data … … 24 27 } ppMopsArguments; 25 28 29 #if 0 30 TTYPE19 = 'PSF_CHISQ' / label for field 19 31 TFORM19 = '1E ' / data format of field: 4-byte REAL 32 TTYPE20 = 'CR_NSIGMA' / label for field 20 33 TFORM20 = '1E ' / data format of field: 4-byte REAL 34 TTYPE21 = 'EXT_NSIGMA' / label for field 21 35 TFORM21 = '1E ' / data format of field: 4-byte REAL 36 TTYPE22 = 'PSF_MAJOR' / label for field 22 37 TFORM22 = '1E ' / data format of field: 4-byte REAL 38 TTYPE23 = 'PSF_MINOR' / label for field 23 39 TFORM23 = '1E ' / data format of field: 4-byte REAL 40 TTYPE24 = 'PSF_THETA' / label for field 24 41 TFORM24 = '1E ' / data format of field: 4-byte REAL 42 TTYPE25 = 'PSF_QF ' / label for field 25 43 TFORM25 = '1E ' / data format of field: 4-byte REAL 44 TTYPE26 = 'PSF_NDOF' / label for field 26 45 TFORM26 = '1J ' / data format of field: 4-byte INTEGER 46 TTYPE27 = 'PSF_NPIX' / label for field 27 47 TFORM27 = '1J ' / data format of field: 4-byte INTEGER 48 TTYPE28 = 'MOMENTS_XX' / label for field 28 49 TFORM28 = '1E ' / data format of field: 4-byte REAL 50 TTYPE29 = 'MOMENTS_XY' / label for field 29 51 TFORM29 = '1E ' / data format of field: 4-byte REAL 52 TTYPE30 = 'MOMENTS_YY' / label for field 30 53 TFORM30 = '1E ' / data format of field: 4-byte REAL 54 #endif 55 26 56 /// Parse arguments 27 57 ppMopsArguments *ppMopsArgumentsParse(int argc, char *argv[]); 28 58 29 59 typedef struct { 30 psString component; // Component name31 psMetadata *header; // FITS header (extension names *.hdr)32 60 psString raBoresight, decBoresight; // RA,Dec of telescope boresight 33 61 psString filter; // Filter for exposure … … 36 64 double posangle; // Position angle 37 65 double alt, az; // Telescope altitude and azimuth 38 double mjd; // Modified Julian Date of exposure mid-point66 double mjd; // Modified Julian Date 39 67 float seeing; // Seeing of exposure 40 int naxis1, naxis2; // Size of image41 68 long num; // Number of detections 42 psMetadata *psfHeader; // FITS header (extension names *.psf)43 psMetadata *table; // Columns of data44 69 psVector *x, *y; // Image coordinates 45 70 psVector *ra, *dec; // Sky coordinates 46 psMetadata *deteffHeader; // Detection efficiency header (extension names *.deteff) 47 psMetadata *deteffTable; // Detection efficiency table 71 psVector *raErr, *decErr; // Error in sky coordinates 72 psVector *mag, *magErr; // Magnitude and associated error 73 psVector *chi2, *dof; // Chi^2 from fitting, with associated degrees of freedom 74 psVector *cr, *extended; // Measures of CR-ness and extendedness 75 psVector *psfMajor, *psfMinor, *psfTheta; // PSF major and minor axes, and position angle 76 psVector *quality, *numPix; // PSF quality factor and number of pixels 77 psVector *xxMoment, *xyMoment, *yyMoment; // Moments 78 psVector *flags; // psphot flags 79 psVector *diffSkyfileId; // Identifier for source image 80 psVector *naxis1, *naxis2; // Size of image 81 psVector *mask; // Mask for detections 82 psVector *nPos; // Number of positive pixels 83 psVector *fPos; // Fraction of positive flux 84 psVector *nRatioBad; // Fraction of positive pixels to negative 85 psVector *nRatioMask; // Fraction of positive pixels to masked 86 psVector *nRatioAll; // Fraction of positive pixels to all 48 87 } ppMopsDetections; 49 88 50 // Allocator 51 ppMopsDetections *ppMopsDetectionsAlloc(void); 89 90 ppMopsDetections *ppMopsDetectionsAlloc(long num); 91 92 /// Copy a detection 93 bool ppMopsDetectionsCopySingle(ppMopsDetections *target, const ppMopsDetections *source, long index); 94 95 /// Purge the detections list of masked detections 96 bool ppMopsDetectionsPurge(ppMopsDetections *detections); 97 52 98 53 99 /// Read detections 54 100 psArray *ppMopsRead(const ppMopsArguments *args); 55 101 56 /// Purge duplicate detections57 bool ppMopsPurgeDuplicates(const psArray *detections);102 /// Merge detections 103 ppMopsDetections *ppMopsMerge(const psArray *detections); 58 104 59 105 /// Write detections 60 bool ppMopsWrite(const p sArray*detections, const ppMopsArguments *args);106 bool ppMopsWrite(const ppMopsDetections *detections, const ppMopsArguments *args); 61 107 62 108 #endif
Note:
See TracChangeset
for help on using the changeset viewer.
