IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 43095


Ignore:
Timestamp:
Sep 21, 2026, 4:31:49 PM (3 days ago)
Author:
cclin33
Message:

fix 0 good chip issue for ipp-2536

File:
1 edited

Legend:

Unmodified
Added
Removed
  • tags/ipp-ops-20220906/psastro/src/psastroMosaicChipAstrom.c

    r41895 r43095  
    7979
    8080    // if basically the entire exposure is bad, return false (calling function sets bad quality)
    81     float fGood = nChipGood / ((float) nChipTotal);
     81    float fGood = (nChipTotal > 0) ? nChipGood / ((float) nChipTotal) : 0.0;
    8282    psLogMsg ("psastro", PS_LOG_INFO, "%d good chips of %d = %.2f\n", nChipGood, nChipTotal, fGood);
    8383    if (fGood < minGoodChipFraction) {
    … …  
    8989    }
    9090
     91    // IPP-2536: with no good chips at all, the boresite fit, the zero point and
     92    // the FPA WCS have nothing to work from.  Running the downstream stages on
     93    // that state produces "zero point NaN" and then dies on a signal, which
     94    // camera_exp.pl reports as the generic "Unable to perform psastro: 4".
     95    // Report the condition instead; psastroAnalysis() turns it into a clean
     96    // bad-quality exit.
     97
     98    if (nChipGood == 0) {
     99        psWarning ("No good chips for this exposure; stopping mosaic astrometry\n");
     100        return false;
     101    }
     102
    91103    return true;
    92104}
Note: See TracChangeset for help on using the changeset viewer.