IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Mar 11, 2006, 5:27:13 PM (20 years ago)
Author:
eugene
Message:

major revisions to use the new pmFPAfile,view I/O handling

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/psphot/src/psphotModelTest.c

    r6481 r6571  
    33static char DEFAULT_MODE[] = "EXT";
    44
    5 bool psphotModelTest (pmReadout *readout, psMetadata *arguments, psMetadata *recipe) {
     5bool psphotModelTest (pmReadout *readout, recipe) {
    66
    77    bool status;
     
    1515
    1616    // run model fitting tests on a single source
    17     if (!psMetadataLookupBool (&status, arguments, "TEST_FIT")) return false;
     17    if (!psMetadataLookupBool (&status, recipe, "TEST_FIT")) return false;
    1818
    1919    // what fitting mode to use?
    20     char *psfModeWord = psMetadataLookupStr (&status, arguments, "TEST_FIT_MODE");
     20    char *psfModeWord = psMetadataLookupStr (&status, recipe, "TEST_FIT_MODE");
    2121    if (!status) {
    2222        psfModeWord = DEFAULT_MODE;
     
    3333    } else {
    3434        // find the model: supplied by user or first in the PSF_MODEL list
    35         char *modelName  = psMetadataLookupStr (&status, arguments, "TEST_FIT_MODEL");
     35        char *modelName  = psMetadataLookupStr (&status, recipe, "TEST_FIT_MODEL");
    3636        if (modelName == NULL) {
    3737            // get the list pointers for the PSF_MODEL entries
     
    5757
    5858    // find the fitting parameters (try test values first)
    59     float INNER = psMetadataLookupF32 (&status, arguments, "TEST_FIT_INNER_RADIUS");
     59    float INNER = psMetadataLookupF32 (&status, recipe, "TEST_FIT_INNER_RADIUS");
    6060    if (!status) {
    6161        INNER = psMetadataLookupF32 (&status, recipe, "SKY_INNER_RADIUS");
    6262    }
    6363
    64     float OUTER = psMetadataLookupF32 (&status, arguments, "TEST_FIT_OUTER_RADIUS");
     64    float OUTER = psMetadataLookupF32 (&status, recipe, "TEST_FIT_OUTER_RADIUS");
    6565    if (!status) {
    6666        OUTER = psMetadataLookupF32 (&status, recipe, "SKY_OUTER_RADIUS");
    6767    }
    6868
    69     float RADIUS = psMetadataLookupF32 (&status, arguments, "TEST_FIT_RADIUS");
     69    float RADIUS = psMetadataLookupF32 (&status, recipe, "TEST_FIT_RADIUS");
    7070    if (!status) {
    7171        RADIUS = psMetadataLookupF32 (&status, recipe, "PSF_FIT_RADIUS");
    7272    }
    7373
    74     float mRADIUS = psMetadataLookupF32 (&status, arguments, "TEST_MOMENTS_RADIUS");
     74    float mRADIUS = psMetadataLookupF32 (&status, recipe, "TEST_MOMENTS_RADIUS");
    7575    if (!status) {
    7676        mRADIUS = psMetadataLookupF32 (&status, recipe, "PSF_MOMENTS_RADIUS");
     
    7878
    7979    // define the source of interest
    80     float xObj     = psMetadataLookupF32 (&status, arguments, "TEST_FIT_X");
    81     float yObj     = psMetadataLookupF32 (&status, arguments, "TEST_FIT_Y");
     80    float xObj     = psMetadataLookupF32 (&status, recipe, "TEST_FIT_X");
     81    float yObj     = psMetadataLookupF32 (&status, recipe, "TEST_FIT_Y");
    8282
    8383    // construct the source structures
     
    120120        }
    121121        sprintf (name, "TEST_FIT_PAR%d", i);
    122         value = psMetadataLookupF32 (&status, arguments, name);
     122        value = psMetadataLookupF32 (&status, recipe, name);
    123123        if (status) {
    124124            params[i] = value;
     
    154154    psImageKeepCircle (source->mask, xObj, yObj, RADIUS, "OR", PSPHOT_MASK_MARKED);
    155155
    156     char *fitset = psMetadataLookupStr (&status, arguments, "TEST_FIT_SET");
     156    char *fitset = psMetadataLookupStr (&status, recipe, "TEST_FIT_SET");
    157157    if (status) {
    158158        status = psphotFitSet (source, model, fitset, psfMode);
Note: See TracChangeset for help on using the changeset viewer.