IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Oct 29, 2009, 4:11:28 PM (17 years ago)
Author:
Paul Price
Message:

Adding functions to measure relative astrometry across images.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/pap/psModules/src/objects/pmSourceMatch.h

    r23241 r25969  
    11#ifndef PM_SOURCE_MATCH_H
    22#define PM_SOURCE_MATCH_H
     3
     4#include <pslib.h>
     5
     6/// Mask values for matched sources
     7typedef enum {
     8    PM_SOURCE_MATCH_MASK_PHOT = 0x01,   // Source was rejected from photometry fit
     9    PM_SOURCE_MATCH_MASK_ASTRO = 0x02,     // Source was rejected from astrometry fit
     10} pmSourceMatchMask;
    311
    412/// Matched sources
     
    1220    psVector *mag;                      // Magnitudes
    1321    psVector *magErr;                   // Magnitude errors
     22    psVector *x, *y;                    // Positions
    1423    psVector *mask;                     // Mask for measurements
    1524} pmSourceMatch;
     
    2635    PS_ASSERT_VECTOR_NON_NULL((MATCH)->mag, RVAL); \
    2736    PS_ASSERT_VECTOR_NON_NULL((MATCH)->magErr, RVAL); \
     37    PS_ASSERT_VECTOR_NON_NULL((MATCH)->x, RVAL); \
     38    PS_ASSERT_VECTOR_NON_NULL((MATCH)->y, RVAL); \
    2839    PS_ASSERT_VECTOR_SIZE((MATCH)->image, (MATCH)->num, RVAL); \
    2940    PS_ASSERT_VECTOR_SIZE((MATCH)->index, (MATCH)->num, RVAL); \
    3041    PS_ASSERT_VECTOR_SIZE((MATCH)->mag, (MATCH)->num, RVAL); \
    3142    PS_ASSERT_VECTOR_SIZE((MATCH)->magErr, (MATCH)->num, RVAL); \
     43    PS_ASSERT_VECTOR_SIZE((MATCH)->x, (MATCH)->num, RVAL); \
     44    PS_ASSERT_VECTOR_SIZE((MATCH)->y, (MATCH)->num, RVAL); \
    3245}
    3346
     
    3851void pmSourceMatchAdd(pmSourceMatch *match, // Match data
    3952                      float mag, float magErr, // Magnitude and error
     53                      float x, float y,        // Position
    4054                      int image, // Image index
    4155                      int index // Source index
     
    7589    );
    7690
     91/// Perform relative astrometry to calibrate images
     92psArray *pmSourceMatchRelastro(const psArray *matches, // Array of matches
     93                               int numImages,          // Number of images
     94                               float tol, // Relative tolerance for convergence
     95                               int iter1, // Number of iterations for pass 1
     96                               float rej1, // Limit on rejection between iterations for pass 1
     97                               int iter2, // Number of iterations for pass 2
     98                               float rej2, // Limit on rejection between iterations for pass 2
     99                               float rejLimit // Limit on rejection between iterations
     100    );
     101
    77102#endif
Note: See TracChangeset for help on using the changeset viewer.