Changeset 16986 for trunk/ppStack/src/ppStackLoop.c
- Timestamp:
- Mar 13, 2008, 12:21:21 PM (18 years ago)
- File:
-
- 1 edited
-
trunk/ppStack/src/ppStackLoop.c (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ppStack/src/ppStackLoop.c
r16865 r16986 188 188 return false; 189 189 } 190 191 float threshold = psMetadataLookupF32(NULL, config->arguments, "THRESHOLD.MASK"); // Threshold for mask deconvolution 190 192 191 193 const char *statsName = psMetadataLookupStr(&mdok, config->arguments, "STATS"); // Filename for statistics … … 449 451 // Reset for the second read 450 452 // Extract the rejection lists 451 psFree(subKernels); 452 psFree(subRegions); 453 psArray *rejected = psArrayAlloc(num); // Rejected pixels 453 psArray *rejected = psArrayAlloc(num); // Pixels to inspect 454 454 for (int i = 0; i < num; i++) { 455 455 pmReadout *ro = readouts->data[i]; // Readout of interest 456 pmReadoutFreeData(ro); 457 458 psPixels *rejects = NULL; // Rejection list for this readout 456 psPixels *inspect = NULL; // Inspection list for this readout 459 457 psMetadataIterator *iter = psMetadataIteratorAlloc(ro->analysis, PS_LIST_HEAD, 460 "^" PPSTACK_ REJECTED_PIXELS "$"); // Iterator458 "^" PPSTACK_INSPECT_PIXELS "$"); // Iterator 461 459 psMetadataItem *item; 462 460 while ((item = psMetadataGetAndIncrement(iter))) { 463 461 psPixels *pixels = item->data.V; // Rejected pixels 464 psTrace("ppStack", 5, "Adding %ld rejected pixelsto image %d", pixels->n, i);465 rejects = psPixelsConcatenate(rejects, pixels);462 psTrace("ppStack", 5, "Adding %ld pixels to inspect to image %d", pixels->n, i); 463 inspect = psPixelsConcatenate(inspect, pixels); 466 464 } 467 465 psFree(iter); 468 psTrace("ppStack", 5, "%ld rejected pixels rejected from image %d", rejects->n, i); 469 psMetadataRemoveKey(ro->analysis, PPSTACK_REJECTED_PIXELS); 470 rejected->data[i] = rejects; 471 } 472 466 psMetadataRemoveKey(ro->analysis, PPSTACK_INSPECT_PIXELS); 467 pmReadoutFreeData(ro); 468 469 psTrace("ppStack", 5, "%ld total pixels to inspect from image %d", inspect->n, i); 470 471 psPixels *reject = pmStackReject(inspect, NULL, threshold, subRegions->data[i], 472 subKernels->data[i]); // Pixels to reject 473 psTrace("ppStack", 5, "%ld pixels rejected from image %d", reject->n, i); 474 rejected->data[i] = reject; 475 } 476 psFree(subKernels); 477 psFree(subRegions); 473 478 474 479 // Read convolutions by chunks
Note:
See TracChangeset
for help on using the changeset viewer.
