Changeset 33851 for trunk/psastro/src/psastroMaskUpdates.c
- Timestamp:
- May 8, 2012, 5:30:49 PM (14 years ago)
- File:
-
- 1 edited
-
trunk/psastro/src/psastroMaskUpdates.c (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/psastro/src/psastroMaskUpdates.c
r30873 r33851 406 406 // XXX for now, assume cell binning is 1x1 relative to chip 407 407 psastroMaskCircle (readoutMask->mask, crosstalkMaskValue, ref->chip->x, ref->chip->y, radius, radius); 408 } 409 } 410 // Crosstalk Bleeds 411 psArray *bleedcrosstalks = psMetadataLookupPtr (&status, readout->analysis, "PSASTRO.CROSSTALKS.SPIKES"); 412 if (bleedcrosstalks) { 413 for (int i = 0; i < bleedcrosstalks->n; i++) { 414 pmAstromObj *ref = bleedcrosstalks->data[i]; 415 float width = REFSTAR_MASK_BLEED_MAG_SLOPE * (REFSTAR_MASK_BLEED_MAG_MAX - ref->Mag); 416 psTrace("psastro.crosstalk",2,"Masking spike on Chip %s @ (%f,%f) Magnitude: %f Radius %f\n", 417 psMetadataLookupStr(&status,readout->parent->parent->concepts,"CHIP.NAME"), 418 ref->chip->x,ref->chip->y,ref->Mag,width); 419 // XXX for now, assume cell binning is 1x1 relative to chip 420 pmCell *refCell = pmCellInChip(refChip,ref->chip->x,ref->chip->y); 421 if (refCell) { 422 float xCell = 0.0; 423 float yCell = 0.0; 424 pmCellCoordsForChip (&xCell, &yCell, refCell, ref->chip->x, ref->chip->y); 425 int ySize = psMetadataLookupS32(NULL,refCell->concepts,"CELL.YSIZE"); 426 /* psWarning("Masking CTspike on Chip %s @ (%f,%f) Magnitude: %f (%f %f) Radius %f Z: %d %d %d %d\n", */ 427 /* psMetadataLookupStr(&status,readout->parent->parent->concepts,"CHIP.NAME"), */ 428 /* ref->chip->x,ref->chip->y,ref->Mag,REFSTAR_MASK_BLEED_MAG_SLOPE,REFSTAR_MASK_BLEED_MAG_MAX,width, */ 429 /* (int) (ref->chip->x - 0.5 * width), (int) (ref->chip->y - yCell), */ 430 /* (int) (ref->chip->x+0.5 * width + 1), (int) (ref->chip->y + (ySize - yCell))); */ 431 psastroMaskRectangle (readoutMask->mask, crosstalkMaskValue, 432 (int) (ref->chip->x - 0.5 * width), (int) (ref->chip->y - yCell), 433 (int) (ref->chip->x+0.5 * width + 1), (int) (ref->chip->y + (ySize - yCell))); 434 } 408 435 } 409 436 }
Note:
See TracChangeset
for help on using the changeset viewer.
