IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 19599


Ignore:
Timestamp:
Sep 18, 2008, 9:38:38 AM (18 years ago)
Author:
Paul Price
Message:

For the update system, can't change the type of what's on the recipe.

Location:
trunk/ppStack/src
Files:
2 edited

Legend:

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

    r19399 r19599  
    8181    psMaskType value = pmConfigMaskGet(name, config); \
    8282    psMetadataAddU8(recipe, PS_LIST_TAIL, RECIPENAME, PS_META_REPLACE, NULL, value); \
    83 }
    84 
    85 // Get a statistic name from the command-line or recipe, and add the enum to the arguments
    86 #define VALUE_ARG_RECIPE_STAT(ARGNAME, RECIPENAME) { \
    87     const char *stat = psMetadataLookupStr(NULL, config->arguments, ARGNAME); \
    88     if (!stat) { \
    89         stat = psMetadataLookupStr(NULL, recipe, RECIPENAME); \
    90         if (!stat) { \
    91             psError(PS_ERR_BAD_PARAMETER_VALUE, false, "Unable to find %s in recipe %s", \
    92                     RECIPENAME, PPSTACK_RECIPE); \
    93             goto ERROR; \
    94         } \
    95     } \
    96     psMetadataAddS32(recipe, PS_LIST_TAIL, RECIPENAME, PS_META_REPLACE, \
    97                      NULL, psStatsOptionFromString(stat)); \
    9883}
    9984
     
    281266    }
    282267    VALUE_ARG_RECIPE_INT("-renorm-width", "RENORM.WIDTH", S32, 0);
    283     VALUE_ARG_RECIPE_STAT("-renorm-mean", "RENORM.MEAN");
    284     VALUE_ARG_RECIPE_STAT("-renorm-stdev", "RENORM.STDEV");
     268    valueArgRecipeStr(arguments, recipe, "-renorm-mean", "RENORM.MEAN", recipe);
     269    valueArgRecipeStr(arguments, recipe, "-renorm-stdev", "RENORM.STDEV", recipe);
    285270
    286271    valueArgRecipeStr(arguments, recipe, "-temp-image",  "TEMP.IMAGE",  recipe);
  • trunk/ppStack/src/ppStackMatch.c

    r19548 r19599  
    7272    bool mdok;                          // Status of MD lookup
    7373    bool renorm = psMetadataLookupBool(&mdok, recipe, "RENORM"); // Renormalise variances?
    74     psStatsOptions renormMean = psMetadataLookupS32(&mdok, recipe, "RENORM.MEAN"); // Statistic for mean
    75     psStatsOptions renormStdev = psMetadataLookupS32(&mdok, recipe, "RENORM.STDEV"); // Statistic for stdev
    76     int renormWidth = psMetadataLookupS32(&mdok, recipe, "RENORM.WIDTH"); // Width for renormalisation box
    7774    float penalty = psMetadataLookupF32(NULL, ppsub, "PENALTY"); // Penalty for wideness
    7875    int threads = psMetadataLookupS32(NULL, config->arguments, "-threads"); // Number of threads
     
    364361    // Renormalise the variances if desired
    365362    if (renorm) {
     363        // Statistics for renormalisation
     364        psStatsOptions renormMean = psStatsOptionFromString(psMetadataLookupStr(&mdok, recipe,
     365                                                                                "RENORM.MEAN"));
     366        psStatsOptions renormStdev = psStatsOptionFromString(psMetadataLookupS32(&mdok, recipe,
     367                                                                                 "RENORM.STDEV"));
     368        int renormWidth = psMetadataLookupS32(&mdok, recipe, "RENORM.WIDTH"); // Width for renormalisation box
     369
    366370        psLogMsg("ppStack", PS_LOG_INFO, "Renormalising variance map.");
    367371        if (!pmReadoutWeightRenorm(readout, maskBad, renormMean, renormStdev, renormWidth, rng)) {
Note: See TracChangeset for help on using the changeset viewer.