IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Mar 31, 2008, 3:46:38 PM (18 years ago)
Author:
Paul Price
Message:

Adding renormalisation of variance maps.

File:
1 edited

Legend:

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

    r17016 r17255  
    306306    psArray *subKernels = psArrayAlloc(num); // Subtraction kernels --- required in the stacking
    307307    psArray *subRegions = psArrayAlloc(num); // Subtraction regions --- required in the stacking
     308    psRandom *rng = psRandomAlloc(PS_RANDOM_TAUS, 0); // Random number generator
    308309    for (int i = 0; i < num; i++) {
    309310        psTrace("ppStack", 2, "Convolving input %d of %d to target PSF....\n", i, num);
     
    315316            psFree(sources);
    316317            psFree(targetPSF);
     318            psFree(rng);
    317319            return false;
    318320        }
     
    323325        // Background subtraction, scaling and normalisation is performed automatically by the image matching
    324326        psArray *regions = NULL, *kernels = NULL; // Regions and kernels used in subtraction
    325         if (!ppStackMatch(readout, &regions, &kernels, sources, targetPSF, config)) {
     327        if (!ppStackMatch(readout, &regions, &kernels, sources, targetPSF, rng, config)) {
    326328            psError(PS_ERR_UNKNOWN, false, "Unable to match image %d --- ignoring.", i);
    327329            psFree(sources);
    328330            psFree(targetPSF);
     331            psFree(rng);
    329332            return false;
    330333        }
     
    345348    psFree(sources);
    346349    psFree(targetPSF);
     350    psFree(rng);
    347351
    348352
Note: See TracChangeset for help on using the changeset viewer.