IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Oct 23, 2009, 2:45:37 PM (17 years ago)
Author:
Paul Price
Message:

When TESTING, make output mask = number of valid inputs, variance =
fraction of valid inputs unrejected.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/pap/psModules/src/imcombine/pmStack.c

    r25380 r25938  
    3333#define NUM_DIRECT_STDEV 5              // For less than this number of values, measure stdev directly
    3434
    35 //#define TESTING                         // Enable test output
    36 //#define TEST_X 1085                     // x coordinate to examine
    37 //#define TEST_Y 3371                     // y coordinate to examine
     35#define TESTING                         // Enable test output
     36#define TEST_X -1                     // x coordinate to examine
     37#define TEST_Y -1                     // y coordinate to examine
    3838
    3939
     
    390390        }
    391391    }
     392    int numRejected = 0;                // Number of rejected inputs
    392393#endif
    393394
     
    423424              fprintf(stderr, "Single input to combine, safety on, pixel is bad.\n");
    424425          }
     426          numRejected = 1;
    425427#endif
    426428          break;
     
    468470                              diff, rej, sqrtf(sigma2));
    469471                  }
     472                  numRejected = 2;
    470473#endif
    471474              }
     
    579582                                      j, diff, sqrtf(pixelLimits->data.F32[j]));
    580583                          }
     584                          numRejected++;
    581585#endif
    582586                      }
     
    588592                                  j, diff, limit);
    589593                      }
     594                      numRejected++;
    590595#endif
    591596                  }
     
    632637        variance->data.F32[y][x] = varianceValue;
    633638    }
     639
     640#ifdef TESTING
     641    mask->data.PS_TYPE_IMAGE_MASK_DATA[y][x] = num;
     642    if (variance) {
     643        variance->data.F32[y][x] = 1.0 - (float)numRejected / (float)num;
     644    }
     645#endif
    634646
    635647    return;
Note: See TracChangeset for help on using the changeset viewer.