IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Sep 22, 2005, 3:56:54 PM (21 years ago)
Author:
gusciora
Message:

....

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/psModules/src/pmSubtractBias.c

    r4997 r5102  
    66 *  @author GLG, MHPCC
    77 *
    8  *  @version $Revision: 1.37 $ $Name: not supported by cvs2svn $
    9  *  @date $Date: 2005-09-12 20:38:25 $
     8 *  @version $Revision: 1.38 $ $Name: not supported by cvs2svn $
     9 *  @date $Date: 2005-09-23 01:55:30 $
    1010 *
    1111 *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
     
    2222#define PM_SUBTRACT_BIAS_SPLINE_ORDER 3
    2323
     24// XXX: put these in psConstants.h
     25void PS_POLY1D_PRINT(psPolynomial1D *poly)
     26{
     27    printf("-------------- PS_POLY1D_PRINT() --------------\n");
     28    printf("poly->COOL_1D_n is %d\n", poly->COOL_1D_n);
     29    for (psS32 i = 0 ; i < (1 + poly->COOL_1D_n) ; i++) {
     30        printf("poly->coeff[%d] is %f\n", i, poly->coeff[i]);
     31    }
     32}
     33
     34void PS_PRINT_SPLINE(psSpline1D *mySpline)
     35{
     36    printf("-------------- PS_PRINT_SPLINE() --------------\n");
     37    printf("mySpline->n is %d\n", mySpline->n);
     38    for (psS32 i = 0 ; i < mySpline->n ; i++) {
     39        PS_POLY1D_PRINT(mySpline->spline[i]);
     40    }
     41    PS_VECTOR_PRINT_F32(mySpline->knots);
     42}
     43
     44#define PS_IMAGE_PRINT_F32_HIDEF(NAME) \
     45printf("======== printing %s ========\n", #NAME); \
     46for (int i = 0 ; i < (NAME)->numRows ; i++) { \
     47    for (int j = 0 ; j < (NAME)->numCols ; j++) { \
     48        printf("%.5f ", (NAME)->data.F32[i][j]); \
     49    } \
     50    printf("\n"); \
     51}\
     52
    2453/******************************************************************************
    2554psSubtractFrame(): this routine will take as input a readout for the input
    2655image and a readout for the bias image.  The bias image is subtracted in
    2756place from the input image.
    28  *****************************************************************************/
     57*****************************************************************************/
    2958static pmReadout *SubtractFrame(pmReadout *in,
    3059                                const pmReadout *bias)
     
    143172    return(opt);
    144173}
     174
     175
    145176
    146177/******************************************************************************
     
    161192    psTrace(".psModule.pmSubtracBias.ScaleOverscanVector", 4,
    162193            "---- ScaleOverscanVector() begin (%d -> %d) ----\n", overscanVector->n, n);
     194    //    PS_VECTOR_PRINT_F32(overscanVector);
    163195
    164196    if (NULL == overscanVector) {
     
    218250            return(NULL);
    219251        }
     252        //        PS_PRINT_SPLINE(mySpline);
    220253
    221254        // For each element of the new vector, convert the x-ordinate to that
     
    230263            psFree(mySpline);
    231264        }
     265        //        PS_VECTOR_PRINT_F32(newVec);
     266
    232267
    233268    } else {
     
    376411    tmpOverscan = (psListElem *) overscans->head;
    377412    while (NULL != tmpOverscan) {
     413        //        PS_IMAGE_PRINT_F32_HIDEF(in->image);
    378414        myOverscanImage = (psImage *) tmpOverscan->data;
    379415
Note: See TracChangeset for help on using the changeset viewer.