Changeset 20249
- Timestamp:
- Oct 17, 2008, 2:48:24 PM (18 years ago)
- File:
-
- 1 edited
-
trunk/psModules/src/objects/pmSource.c (modified) (6 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/psModules/src/objects/pmSource.c
r20010 r20249 6 6 * @author EAM, IfA: significant modifications. 7 7 * 8 * @version $Revision: 1.6 2$ $Name: not supported by cvs2svn $9 * @date $Date: 2008-10- 09 00:58:39$8 * @version $Revision: 1.63 $ $Name: not supported by cvs2svn $ 9 * @date $Date: 2008-10-18 00:48:24 $ 10 10 * 11 11 * Copyright 2004 Maui High Performance Computing Center, University of Hawaii … … 279 279 psTrace("psModules.objects", 5, "---- begin ----\n"); 280 280 281 // XXX This should be in the recipe282 #define SCALE 0.1 // Scale of splane283 284 281 psArray *peaks = NULL; 285 282 pmPSFClump errorClump = {-1.0, -1.0, 0.0, 0.0}; … … 294 291 if (!status) { 295 292 PSF_CLUMP_SN_LIM = 0; 293 } 294 float PSF_CLUMP_GRID_SCALE = psMetadataLookupF32(&status, recipe, "PSF_CLUMP_GRID_SCALE"); 295 if (!status) { 296 PSF_CLUMP_GRID_SCALE = 0.1; 296 297 } 297 298 … … 316 317 317 318 // construct a sigma-plane image 318 int numCols = SX_MAX / SCALE, numRows = SY_MAX /SCALE; // Size of sigma-plane image319 int numCols = SX_MAX / PSF_CLUMP_GRID_SCALE, numRows = SY_MAX / PSF_CLUMP_GRID_SCALE; // Size of sigma-plane image 319 320 psTrace("psModules.objects", 10, "sigma-plane dimensions: %dx%d\n", numCols, numRows); 320 321 psImage *splane = psImageAlloc(numCols, numRows, PS_TYPE_F32); // sigma-plane image … … 373 374 374 375 // for the moment, force splane dimensions to be 10x10 image pix 375 int binX = Mxx / SCALE, binY = Myy /SCALE; // Position on splane376 int binX = Mxx / PSF_CLUMP_GRID_SCALE, binY = Myy / PSF_CLUMP_GRID_SCALE; // Position on splane 376 377 psAssert(binX >= 0 && binX < numCols && binY >= 0 && binY < numRows, "We checked it already"); 377 378 … … 428 429 429 430 // define section window for clump 430 minSx = clump->x * SCALE - 0.2;431 maxSx = clump->x * SCALE + 0.2;432 minSy = clump->y * SCALE - 0.2;433 maxSy = clump->y * SCALE + 0.2;431 minSx = clump->x * PSF_CLUMP_GRID_SCALE - 2.0*PSF_CLUMP_GRID_SCALE; 432 maxSx = clump->x * PSF_CLUMP_GRID_SCALE + 2.0*PSF_CLUMP_GRID_SCALE; 433 minSy = clump->y * PSF_CLUMP_GRID_SCALE - 2.0*PSF_CLUMP_GRID_SCALE; 434 maxSy = clump->y * PSF_CLUMP_GRID_SCALE + 2.0*PSF_CLUMP_GRID_SCALE; 434 435 435 436 tmpSx = psVectorAllocEmpty (sources->n, PS_TYPE_F32);
Note:
See TracChangeset
for help on using the changeset viewer.
