IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Dec 21, 2004, 10:41:29 AM (22 years ago)
Author:
gusciora
Message:

Added errors arguments to the VectorStats functions.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/psModules/test/tst_pmSubtractSky.c

    r2761 r2777  
    77 *  @author GLG, MHPCC
    88 *
    9  *  @version $Revision: 1.2 $ $Name: not supported by cvs2svn $
    10  *  @date $Date: 2004-12-20 21:39:14 $
     9 *  @version $Revision: 1.3 $ $Name: not supported by cvs2svn $
     10 *  @date $Date: 2004-12-21 20:41:29 $
    1111 *
    1212 *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
     
    1919#define POLY_X_ORDER 3
    2020#define POLY_Y_ORDER 3
    21 #define TOL 1.0
     21#define ERROR_TOLERANCE 1.0
    2222#define OBJECT_INTENSITY 2000.0
    2323static int test00(void);
     
    2626                              {NULL}
    2727                          };
     28//XXX: Test a few input parameter error conditions.
    2829
    2930float func(int i, int j)
     
    3738}
    3839
     40/******************************************************************************
     41 *****************************************************************************/
    3942int doSubtractSkySimple(int numCols, int numRows, int binFactor)
    4043{
     
    5760    for (i=0;i<numRows;i++) {
    5861        for (j=0;j<numCols;j++) {
    59             if (TOL < fabs(myReadout->image->data.F32[i][j])) {
     62            if (ERROR_TOLERANCE < fabs(myReadout->image->data.F32[i][j])) {
    6063                printf("ERROR: image[%d][%d] is %f, should be 0.0\n", i, j, myReadout->image->data.F32[i][j]);
    6164                testStatus = 1;
     
    6972}
    7073
     74/******************************************************************************
     75 *****************************************************************************/
    7176int doSubtractSkyWithObjects(int numCols, int numRows, int binFactor)
    7277{
     
    7984    psPolynomial2D *myPoly = psPolynomial2DAlloc(POLY_X_ORDER, POLY_Y_ORDER, PS_POLYNOMIAL_ORD);
    8085    psImage *trueImage = psImageAlloc(numCols, numRows, PS_TYPE_F32);
    81     psF32 errorTolerance = TOL * ((psF32) binFactor);
     86    psF32 errorTolerance = ERROR_TOLERANCE * ((psF32) binFactor);
    8287
    8388    for (i=0;i<numRows;i++) {
     
    123128
    124129    // Bin Factor == 1
    125     /*
    126     */
    127130    printf("doSubtractSkySimple(1, 1, 1)\n");
    128131    testStatus |= doSubtractSkySimple(1, 1, 1);
Note: See TracChangeset for help on using the changeset viewer.