Changeset 13379 for trunk/psModules/src/imcombine/pmSubtraction.c
- Timestamp:
- May 14, 2007, 3:23:19 PM (19 years ago)
- File:
-
- 1 edited
-
trunk/psModules/src/imcombine/pmSubtraction.c (modified) (6 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/psModules/src/imcombine/pmSubtraction.c
r13366 r13379 4 4 * @author GLG, MHPCC 5 5 * 6 * @version $Revision: 1. 2$ $Name: not supported by cvs2svn $7 * @date $Date: 2007-05-1 2 02:00:39 $6 * @version $Revision: 1.3 $ $Name: not supported by cvs2svn $ 7 * @date $Date: 2007-05-15 01:23:19 $ 8 8 * 9 9 * Copyright 2004-2007 Institute for Astronomy, University of Hawaii … … 79 79 for (int v = -size; v <= size; v++) { 80 80 for (int u = -size; u <= size; u++) { 81 sum += weightFunc(kernel->kernel[v][u]) * image->data.F 64[y + v][x + u];81 sum += weightFunc(kernel->kernel[v][u]) * image->data.F32[y + v][x + u]; 82 82 } 83 83 } … … 163 163 for (int i = 0; i < stamps->n; i++) { 164 164 pmSubtractionStamp *stamp = stamps->data[i]; // Stamp of interest 165 psTrace("psModules.imcombine", 6, "Inspecting stamp %d\n", i);166 167 165 if (stamp->status == PM_SUBTRACTION_STAMP_CALCULATE) { 168 psTrace("psModules.imcombine", 6, "Calculating for stamp %d\n", i);169 166 psImage *stampMatrix = stamp->matrix; // Least-squares matrix for this stamp 170 167 psVector *stampVector = stamp->vector; // Least-squares vector for this stamp … … 240 237 241 238 stamp->status = PM_SUBTRACTION_STAMP_USED; 239 240 if (psTraceGetLevel("psModules.imcombine.equation") >= 10) { 241 psString matrixName = NULL; 242 psStringAppend(&matrixName, "matrix%d.fits", i); 243 psFits *matrixFile = psFitsOpen(matrixName, "w"); 244 psFree(matrixName); 245 psFitsWriteImage(matrixFile, NULL, stampMatrix, 0, NULL); 246 psFitsClose(matrixFile); 247 } 248 242 249 } 243 250 } … … 311 318 psError(PS_ERR_UNKNOWN, true, "Failed to solve the least-squares system.\n"); 312 319 return NULL; 320 } 321 322 if (psTraceGetLevel("psModules.imcombine") >= 7) { 323 for (int i = 0; i < solution->n; i++) { 324 printf(" Solution %d: %f\n", i, solution->data.F64[i]); 325 } 313 326 } 314 327 … … 413 426 if (stamp->status == PM_SUBTRACTION_STAMP_USED && deviations->data.F32[i] > limit) { 414 427 // Mask out the stamp in the image so you it's not found again 428 psTrace("psModules.imcombine", 3, "Rejecting stamp %d\n", i); 415 429 numRejected++; 416 430 for (int y = stamp->y - footprint; y <= stamp->y + footprint; y++) {
Note:
See TracChangeset
for help on using the changeset viewer.
