IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Apr 13, 2022, 10:53:25 AM (4 years ago)
Author:
eugene
Message:

add PATTERN.DEAD.CELLS option; split ppImageDetrendPattern into separate functions for the 4 different options; functions like ppImageDetrendFringeApply and ppImageDetrendPatternApply now test the relevant option and return true if not selected (no need to check the option in the calling function)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/eam_branches/ipp-20220316/ppImage/src/ppImageDetrendReadout.c

    r42158 r42167  
    126126
    127127    // measure the overscan-subtracted readoutBackground here (or subtract the overscan value?)
    128     if (1) {
    129         psStats *stats = psStatsAlloc (PS_STAT_ROBUST_MEDIAN);
     128    // XXX this is the measurements and should be independent of the pattern masking
     129    if (options->doPatternDeadCells) {
     130        psStats *stats = psStatsAlloc (PS_STAT_ROBUST_MEDIAN | PS_STAT_ROBUST_STDEV);
    130131        psRandom *rng = psRandomAlloc(PS_RANDOM_TAUS);
    131132        psImageBackground (stats, NULL, input->image, NULL, 0xffff, rng);
     
    134135        pmHDU *hdu = pmHDUFromReadout(input);  // HDU of interest
    135136        psMetadataAddF32(hdu->header, PS_LIST_TAIL, "BACK_VAL", PS_META_REPLACE, "Median cell background", stats->robustMedian);
     137        psMetadataAddF32(hdu->header, PS_LIST_TAIL, "BACK_ERR", PS_META_REPLACE, "Stdev of cell background", stats->robustStdev);
    136138        psFree (stats);
    137139        psFree (rng);
Note: See TracChangeset for help on using the changeset viewer.