IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Feb 5, 2009, 4:31:25 PM (17 years ago)
Author:
Paul Price
Message:

Merging pap_branch_20090128. Resolved a small number of conflicts. Compiles, but not tested in detail.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/psModules/src/camera/pmFPA.h

    r19013 r21363  
    66 * @author Eugene Magnier, IfA
    77 *
    8  * @version $Revision: 1.25 $ $Name: not supported by cvs2svn $
    9  * @date $Date: 2008-08-12 02:51:20 $
     8 * @version $Revision: 1.26 $ $Name: not supported by cvs2svn $
     9 * @date $Date: 2009-02-06 02:31:24 $
    1010 * Copyright 2005-2006 Institute for Astronomy, University of Hawaii
    1111 */
     
    113113///
    114114/// A readout corresponds to an individual read of a cell (e.g., a single image as part of a video sequence,
    115 /// or one of multiple coadds).  It contains the actual pixels used in analysis (along with mask and weight
     115/// or one of multiple coadds).  It contains the actual pixels used in analysis (along with mask and variance
    116116/// maps).  When reading from a FITS file, the images are subimages (from CELL.TRIMSEC) of the pixels read
    117117/// from the appropriate HDU (at the FPA, chip or cell level).  The readout also contains a list of bias
     
    123123    psImage *image;                     ///< Imaging area of readout (corresponds to CELL.TRIMSEC region)
    124124    psImage *mask;                      ///< Mask of input image (corresponds to CELL.TRIMSEC region)
    125     psImage *weight;                    ///< Weight of input image (corresponds to CELL.TRIMSEC region)
     125    psImage *variance;                  ///< Variance of input image (corresponds to CELL.TRIMSEC region)
     126    psKernel *covariance;               ///< Covariance pseudo-matrix (covariance factors for single pixel)
    126127    psList *bias;                       ///< List of bias (prescan/overscan) images
    127128    psMetadata *analysis;               ///< Readout-level analysis metadata
     
    130131    bool file_exists;                   ///< Does the file for this readout exist (read case only)?
    131132    bool data_exists;                   ///< Does the data for this readout exist (read case only)?
    132     int thisImageScan;                  ///< start scan for next/current read
    133     int lastImageScan;                  ///< start scan of the last read
    134     int thisMaskScan;                   ///< start scan for next/current read
    135     int lastMaskScan;                   ///< start scan of the last read
    136     int thisWeightScan;                 ///< start scan for next/current read
    137     int lastWeightScan;                 ///< start scan of the last read
     133    int thisImageScan;                  ///< start scan for next/current read of image
     134    int lastImageScan;                  ///< start scan of the last read of image
     135    int thisMaskScan;                   ///< start scan for next/current read of mask
     136    int lastMaskScan;                   ///< start scan of the last read of mask
     137    int thisVarianceScan;               ///< start scan for next/current read of variance
     138    int lastVarianceScan;               ///< start scan of the last read of variance
    138139    bool forceScan;                     ///< Force pmFPARead to obey the above commanded this and last scans.
    139140} pmReadout;
     
    217218        } \
    218219    } \
    219     psImage *weight = (READOUT)->weight; /* Weight map pixels */ \
    220     if (weight) { \
    221         PS_ASSERT_IMAGE_NON_NULL((READOUT)->weight, RETVAL); \
    222         if ((numCols != 0 || numRows != 0) && (weight->numCols != numCols || weight->numRows != numRows)) { \
    223             psError(PS_ERR_BAD_PARAMETER_SIZE, true, "Weight in readout %s has wrong size (%dx%d vs %dx%d)", \
    224                     #READOUT, weight->numCols, weight->numRows, numCols, numRows); \
     220    psImage *variance = (READOUT)->variance; /* Variance map pixels */ \
     221    if (variance) { \
     222        PS_ASSERT_IMAGE_NON_NULL((READOUT)->variance, RETVAL); \
     223        if ((numCols != 0 || numRows != 0) && \
     224            (variance->numCols != numCols || variance->numRows != numRows)) { \
     225            psError(PS_ERR_BAD_PARAMETER_SIZE, true, \
     226                    "Variance in readout %s has wrong size (%dx%d vs %dx%d)", \
     227                    #READOUT, variance->numCols, variance->numRows, numCols, numRows); \
    225228            return RETVAL; \
    226229        } \
     
    236239    PS_ASSERT_IMAGE_NON_NULL((READOUT)->mask, RETVAL);
    237240
    238 /// Assert that a readout contains a weight map
    239 #define PM_ASSERT_READOUT_WEIGHT(READOUT, RETVAL) \
    240     PS_ASSERT_IMAGE_NON_NULL((READOUT)->weight, RETVAL);
     241/// Assert that a readout contains a variance map
     242#define PM_ASSERT_READOUT_VARIANCE(READOUT, RETVAL) \
     243    PS_ASSERT_IMAGE_NON_NULL((READOUT)->variance, RETVAL);
     244
     245/// Assert that a readout contains a covariance matrix
     246#define PM_ASSERT_READOUT_COVARIANCE(READOUT, RETVAL) \
     247    PS_ASSERT_KERNEL_NON_NULL((READOUT)->covariance, RETVAL);
    241248
    242249/// @}
Note: See TracChangeset for help on using the changeset viewer.