IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Mar 17, 2008, 4:07:18 PM (18 years ago)
Author:
Paul Price
Message:

Normalisation wasn't set correctly for the case where we're not convolving.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/ppStack/src/ppStackMatch.c

    r16864 r17031  
    133133        kernels->solution1 = psVectorAlloc(kernels->num + 2, PS_TYPE_F64);
    134134        psVectorInit(kernels->solution1, 0.0);
    135         for (int i = 0; i < kernels->num; i++) {
    136             if (kernels->u->data.S32[i] == 0 && kernels->v->data.S32[i] == 0) {
    137                 kernels->solution1->data.F64[i] = 1.0;
    138             }
    139         }
     135        int normIndex = PM_SUBTRACTION_INDEX_NORM(kernels); // Index for normalisation
     136        kernels->solution1->data.F64[normIndex] = 1.0;
    140137        psMetadataAddPtr(output->analysis, PS_LIST_TAIL, PM_SUBTRACTION_ANALYSIS_KERNEL,
    141138                         PS_DATA_UNKNOWN | PS_META_DUPLICATE_OK, "Fake subtraction kernel", kernels);
Note: See TracChangeset for help on using the changeset viewer.