IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Mar 1, 2011, 6:21:28 PM (15 years ago)
Author:
eugene
Message:

fix threading for psphotStack; use standard PS_ARGUMENTS_ macros for ppSub, ppStack, pswarp, ppImage, psphotStack; fix FPA.EXPOSURE in ppImageAddNoise; fix accounting for psf bad and poor weights; added flags for substantial poor masks due to each poor mask bit type; fix the measurement of the fwhm in pmPSFtoFWHM

Location:
branches/eam_branches/ipp-20110213/ppSub/src
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • branches/eam_branches/ipp-20110213/ppSub/src/ppSub.h

    r29937 r30772  
    128128void ppSubVersionPrint(void);
    129129
     130/// write the version info to a string
     131psString ppSubVersionLong(void);
     132
    130133/// Mark the data quality as bad and prepare to suspend processing
    131134void ppSubDataQuality(ppSubData *data,  ///< Processing data
     
    185188bool ppSubSetSourceImageIDs (psArray *sources, int imageID);
    186189
     190void ppSubSetThreads (void);
     191
    187192///@}
    188193#endif
  • branches/eam_branches/ipp-20110213/ppSub/src/ppSubArguments.c

    r29937 r30772  
    5757}
    5858
     59void ppSubSetThreads (void) {
     60    // ppSub does not have any of its own thread handlers
     61    return;
     62}
     63
    5964bool ppSubArguments(int argc, char *argv[], ppSubData *data)
    6065{
     
    6267    pmConfig *config = data->config;
    6368    assert(config);
     69
     70    // generic arguments (version, dumpconfig)
     71    PS_ARGUMENTS_GENERIC( ppSub, config, argc, argv );
     72
     73    // thread arguments
     74    PS_ARGUMENTS_THREADS( ppSub, config, argc, argv )
    6475
    6576    int argNum = psArgumentGet(argc, argv, "-debug"); // Debugging argument number
     
    8293    psMetadataAddStr(arguments, PS_LIST_TAIL, "-stats", 0, "Statistics file", NULL);
    8394    psMetadataAddStr(arguments,  PS_LIST_TAIL, "-stamps", 0, "Stamps filename; x,y on each line", NULL);
    84     psMetadataAddS32(arguments, PS_LIST_TAIL, "-threads", 0, "Number of threads", 0);
    85     psMetadataAddStr(arguments, PS_LIST_TAIL, "-dumpconfig", 0, "file to dump configuration to", NULL);
    8695    psMetadataAddS32(arguments, PS_LIST_TAIL, "-convolve", 0, "Image to convolve [1 or 2]", 0);
    8796    psMetadataAddBool(arguments, PS_LIST_TAIL, "-photometry", 0, "Perform photometry?", NULL);
     
    166175    }
    167176
    168     int threads = psMetadataLookupS32(NULL, arguments, "-threads"); // Number of threads
    169     if (threads > 0) {
    170         if (!psThreadPoolInit(threads)) {
    171             psError(psErrorCodeLast(), false, "Unable to setup %d threads", threads);
    172             return false;
    173         }
    174     }
    175 
    176177    psTrace("ppSub", 1, "Done reading command-line arguments\n");
    177178
  • branches/eam_branches/ipp-20110213/ppSub/src/ppSubConvolve.c

    r29551 r30772  
    3939}
    4040
     41void ppSubSetThreads (void) {
     42    // ppSub does not have any of its own thread handlers
     43    return;
     44}
    4145
    4246int main(int argc, char *argv[])
     
    4953        goto die;
    5054    }
     55
     56    // generic arguments (version, dumpconfig)
     57    PS_ARGUMENTS_GENERIC( ppSub, config, argc, argv );
     58
     59    // thread arguments
     60    PS_ARGUMENTS_THREADS( ppSub, config, argc, argv )
    5161
    5262    bool reference = false;             // Input is actually the reference image?
     
    5969        psMetadataAddStr(arguments, PS_LIST_TAIL, "-kernel", 0, "Convolution kernel", NULL);
    6070        psMetadataAddBool(arguments, PS_LIST_TAIL, "-reference", 0, "Input is actually reference?", false);
    61         psMetadataAddS32(arguments, PS_LIST_TAIL, "-threads", 0, "Threads to use", 0);
    6271        psMetadataAddBool(arguments, PS_LIST_TAIL, "-save-all", 0, "Save all outputs?", false);
    6372
     
    7584
    7685        reference = psMetadataLookupBool(NULL, arguments, "-reference");
    77         threads = psMetadataLookupS32(NULL, arguments, "-threads");
     86        threads = psMetadataLookupS32(NULL, arguments, "NTHREADS");
    7887        fileList("PPSUB.INPUT", inImage, "Input image", config);
    7988        fileList("PPSUB.INPUT.MASK", inMask, "Input mask", config);
     
    239248        if (threads > 0) {
    240249            pmSubtractionThreadsInit();
    241             psThreadPoolInit(threads);
    242250        }
    243251
  • branches/eam_branches/ipp-20110213/ppSub/src/ppSubMatchPSFs.c

    r30619 r30772  
    374374    }
    375375
    376     int threads = psMetadataLookupS32(NULL, config->arguments, "-threads"); // Number of threads
     376    int threads = psMetadataLookupS32(NULL, config->arguments, "NTHREADS"); // Number of threads
    377377    if (threads > 0) {
    378378        pmSubtractionThreadsInit();
Note: See TracChangeset for help on using the changeset viewer.