IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 16084


Ignore:
Timestamp:
Jan 15, 2008, 2:45:18 PM (18 years ago)
Author:
Paul Price
Message:

Adding old code to track memory usage in ppImage.

Location:
trunk/ppImage/src
Files:
1 added
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/ppImage/src/Makefile.am

    r15933 r16084  
    3030        ppImageDefineFile.c \
    3131        ppImageFileCheck.c \
    32         ppImageVersion.c
     32        ppImageVersion.c \
     33        ppImageMemory.c
    3334
    3435ppFocus_CPPFLAGS = $(PSLIB_CFLAGS) $(PSMODULE_CFLAGS) $(PSPHOT_CFLAGS) $(PSASTRO_CFLAGS) $(PPSTATS_CFLAGS) $(ppImage_CFLAGS)
     
    5859        ppImageDefineFile.c \
    5960        ppImageFileCheck.c \
    60         ppImageVersion.c
     61        ppImageVersion.c \
     62        ppImageMemory.c
    6163
    6264ppTest_CPPFLAGS = $(PSLIB_CFLAGS) $(PSMODULE_CFLAGS) $(ppImage_CFLAGS)
  • trunk/ppImage/src/ppImage.h

    r15933 r16084  
    3535    bool doAstromChip;                  // per-chip Astrometry
    3636    bool doAstromMosaic;                // full-mosaic Astrometry
    37     bool doStats;                       // call ppStats on the image
    38     bool replaceMasked;                 // fill in masked values with background model
     37    bool doStats;                       // call ppStats on the image
     38    bool replaceMasked;                 // fill in masked values with background model
    3939
    4040    // output files requested
     
    7070
    7171    // binning parameters
    72     int xBin1;                          // x-binning, scale 1
    73     int yBin1;                          // y-binning, scale 1
    74     int xBin2;                          // x-binning, scale 2
    75     int yBin2;                          // y-binning, scale 2
     72    int xBin1;                          // x-binning, scale 1
     73    int yBin1;                          // y-binning, scale 1
     74    int xBin2;                          // x-binning, scale 2
     75    int yBin2;                          // y-binning, scale 2
    7676
    7777    // parameters used by the fringe analysis
     
    150150bool ppImageStats (pmConfig *config, pmChip *chip, const pmFPAview *inputView, const ppImageOptions *options);
    151151
    152 // write stats to output file 
     152// write stats to output file
    153153bool ppImageStatsOutput (pmConfig *config, const ppImageOptions *options);
    154154
     
    157157bool ppImageDetrendFringeMeasure(pmReadout *readout, // Readout to measure
    158158                                 pmCell *fringe, // Fringe cell (each readout is a different component)
    159                                 const bool isResidual,
     159                                const bool isResidual,
    160160                                 const ppImageOptions *options // Options
    161161    );
     
    164164bool ppImageDetrendFringeSolve(pmChip *scienceChip, // Chip with science
    165165                               const pmChip *refChip, // Chip with reference fringes
    166                                const bool isResidual,
     166                               const bool isResidual,
    167167                               const ppImageOptions *options // Options
    168168    );
     
    171171bool ppImageDetrendFringeGenerate(pmCell *science, // Science cell
    172172                                  pmCell *fringes, // Fringe cell, one readout per fringe component
    173                                   const ppImageOptions *options // Options
     173                                  const ppImageOptions *options // Options
    174174    );
    175175
    176176
    177177bool ppImageDetrendFringeApply (pmConfig *config, // config
    178                                 pmChip *chip, // science chip
    179                                 const pmFPAview *inputView, // current view
    180                                 const ppImageOptions *options // options
     178                                pmChip *chip, // science chip
     179                                const pmFPAview *inputView, // current view
     180                                const ppImageOptions *options // options
    181181    );
    182182
     
    200200void ppImageFileCheck (pmConfig *config);
    201201
     202/// Dump memory summary to text file
     203void ppImageMemoryDump(const char *description);
     204
    202205#endif
  • trunk/ppImage/src/ppImageAstrom.c

    r15142 r16084  
    1919    PS_ASSERT (input, false);
    2020
     21    ppImageMemoryDump("astrom");
     22
    2123    // convert the output sources created by psphot into astrometry objects
    2224    if (!psastroConvertFPA (input->fpa, recipe)) {
    23         psError (PSASTRO_ERR_UNKNOWN, false, "error reading input data\n");
    24         return false;
     25        psError (PSASTRO_ERR_UNKNOWN, false, "error reading input data\n");
     26        return false;
    2527    }
    2628
    2729    if (!psastroAnalysis (config)) {
    28         psError (PSASTRO_ERR_UNKNOWN, false, "failure in psastro analysis\n");
    29         return false;
     30        psError (PSASTRO_ERR_UNKNOWN, false, "failure in psastro analysis\n");
     31        return false;
    3032    }
    3133
     
    3941    while ((chip = pmFPAviewNextChip(view, input->fpa, 1)) != NULL) {
    4042        psLogMsg ("ppImageLoop", 4, "Chip %d: %x %x\n", view->chip, chip->file_exists, chip->process);
     43
     44        ppImageMemoryDump("astrom");
    4145
    4246        // Output and Close at Chip level
     
    5357    }
    5458
    55     // deactivate the PSASTRO files, re-active all else 
     59    // deactivate the PSASTRO files, re-active all else
    5660    // XXX do we need a way to activate / deactivate other groups?
    5761    pmFPAfileActivate (config->files, true, NULL);
  • trunk/ppImage/src/ppImageDetrendReadout.c

    r14223 r16084  
    9292    }
    9393
     94    ppImageMemoryDump("detrend");
     95
    9496    psFree(detview);
    9597    return true;
  • trunk/ppImage/src/ppImagePhotom.c

    r15944 r16084  
    4343    }
    4444
     45    ppImageMemoryDump("photom");
     46
    4547    // the PSPHOT.INPUT file is a temporary file used to carry PPIMAGE.CHIP to psphotReadout
    4648    // XXX not sure that this is needed...
    47     pmFPAfileActivate (config->files, false, "PSPHOT.INPUT");
     49//    pmFPAfileActivate (config->files, false, "PSPHOT.INPUT");
    4850
    4951    return true;
Note: See TracChangeset for help on using the changeset viewer.