Commit in hps-java/src/main/java/org/lcsim/hps/monitoring/svt on MAIN | |||
SVTHitPulsePlots.java | +16 | -1 | 1.3 -> 1.4 |
Change pulse plots to only plot if two adjacent strips is on
diff -u -r1.3 -r1.4 --- SVTHitPulsePlots.java 1 May 2012 19:03:38 -0000 1.3 +++ SVTHitPulsePlots.java 2 May 2012 01:46:10 -0000 1.4 @@ -80,11 +80,26 @@
short[] adcVal = hit.getADCValues(); double ped = HPSSVTCalibrationConstants.getPedestal(sensor, strip); double noise = HPSSVTCalibrationConstants.getNoise(sensor, strip);
+ boolean hitok=true;
for (int i = 0; i < 6; i++) { double pedSub = (adcVal[i]-ped); //only plot hits above threshold...
- if(pedSub/noise>3)
+ if(pedSub/noise>3&&hasAdjacentHit(hit))
aida.profile1D(sensorName+"_pulse").fill(24.0*i, pedSub); } }
+ + private boolean hasAdjacentHit(RawTrackerHit hit){ + + List<RawTrackerHit> hitsOnSensor=((SiSensor)hit.getDetectorElement()).getReadout().getHits(RawTrackerHit.class); + int strip = hit.getIdentifierFieldValue("strip"); + + for(RawTrackerHit sensorHit : hitsOnSensor){ + int thisStrip=sensorHit.getIdentifierFieldValue("strip"); + if(Math.abs(thisStrip-strip)==1) + return true; + } + + return false; + }
}
Use REPLY-ALL to reply to list
To unsubscribe from the LCD-CVS list, click the following link:
https://listserv.slac.stanford.edu/cgi-bin/wa?SUBED1=LCD-CVS&A=1