IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 34150 for trunk/psModules


Ignore:
Timestamp:
Jul 13, 2012, 3:48:48 PM (14 years ago)
Author:
watersc1
Message:

Keep image average weights for pixel combination procedure, but switch
the variance combination to use a geometric mean of the input
variances. This prevents excessive variance regions from dominating
the output combined variance image.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/psModules/src/imcombine/pmStack.c

    r31721 r34150  
    357357        sumWeight += weights->data.F32[i];
    358358        if (variances) {
    359             sumVarianceWeight += variances->data.F32[i] * PS_SQR(weights->data.F32[i]);
     359          //            sumVarianceWeight += variances->data.F32[i] * PS_SQR(weights->data.F32[i]);
     360          sumVarianceWeight += 1 / variances->data.F32[i];
    360361        }
    361362        if (exps) {
     
    372373    *mean = sumValueWeight / sumWeight;
    373374    if (var) {
    374         *var = sumVarianceWeight / PS_SQR(sumWeight);
     375      //*var = sumVarianceWeight / PS_SQR(sumWeight);
     376      *var = 1 / sumVarianceWeight;
    375377    }
    376378    if (exp) {
Note: See TracChangeset for help on using the changeset viewer.