IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 20349


Ignore:
Timestamp:
Oct 24, 2008, 4:18:51 AM (18 years ago)
Author:
Sebastian Jester
Message:

Add NOISE.ADD ppSim recipe option to turn addition of noise to output image on or off

Location:
branches/sj_ippTests_branch_20080929
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/sj_ippTests_branch_20080929/ippconfig/recipes/ppSim.config

    r19378 r20349  
    7171BADPIX.SEED     U64     123456789       # Seed for RNG in creating deterministic bad pixels
    7272BADPIX.FRAC     F32     0.0001          # Fraction of bad pixels
     73
     74NOISE.ADD       BOOL    TRUE            # Add noise to image?
    7375
    7476### The following options are used if not defined by the concepts (e.g., usually read from headers)
  • branches/sj_ippTests_branch_20080929/ppSim/src/ppSimAddNoise.c

    r18011 r20349  
    3232            // (generate a static array with the cumulative distribution, use the
    3333            // random number to select a bin from the histogram)
    34             signal->data.F32[y][x] += sqrtf(variance->data.F32[y][x]) * ppSimRandomGaussianNorm(rng);
     34            if (psMetadataLookupBool(NULL, recipe, "NOISE.ADD")) { // add noise?
     35              signal->data.F32[y][x] += sqrtf(variance->data.F32[y][x]) * ppSimRandomGaussianNorm(rng);
     36            }
    3537            signal->data.F32[y][x] /= gain; // Converting to ADU
    3638        }
Note: See TracChangeset for help on using the changeset viewer.