Commit in hps-java/src/main/java/org/lcsim/hps/recon/ecal on MAIN | |||
HPSEcalRawConverterDriver.java | +16 | -2 | 1.9 -> 1.10 |
HPSEcalConditions.java | +3 | -1 | 1.10 -> 1.11 |
Commit in hps-detectors/detectors/HPS-TestRun-v2/daqmap on MAIN | |||
ecal.badchannels | +7 | -1 | 1.1 -> 1.2 |
+26 | -4 |
Adding bad cluster map. Determined using EcalCrystalFilter with 5 "sigma" threshold. This is active by default but can be switched off in HPSEcalRawConverterDriver.
diff -u -r1.9 -r1.10 --- HPSEcalRawConverterDriver.java 13 May 2012 21:39:24 -0000 1.9 +++ HPSEcalRawConverterDriver.java 6 Jun 2012 18:29:01 -0000 1.10 @@ -2,6 +2,8 @@
import java.util.ArrayList; import java.util.List;
+import org.lcsim.detector.identifier.IExpandedIdentifier; +import org.lcsim.detector.identifier.IIdentifierHelper;
import org.lcsim.event.CalorimeterHit; import org.lcsim.event.EventHeader; import org.lcsim.event.RawTrackerHit;
@@ -23,7 +25,9 @@
int integralWindow = 30; boolean debug = false; double threshold = Double.NEGATIVE_INFINITY;
-
+ boolean applyBadCrystalMap = true; + +
public HPSEcalRawConverterDriver() { converter = new HPSEcalRawConverter(); }
@@ -48,6 +52,10 @@
this.rawCollectionName = rawCollectionName; }
+ public void setApplyBadCrystalMap(boolean apply) { + this.applyBadCrystalMap = apply; + } +
@Override public void startOfData() { if (ecalCollectionName == null) {
@@ -58,7 +66,11 @@
@Override public void detectorChanged(Detector detector) { }
-
+ + public boolean isBadCrystal(CalorimeterHit hit) { + return HPSEcalConditions.badChannelsLoaded() ? HPSEcalConditions.isBadChannel(hit.getCellID()) : false; + } +
@Override public void process(EventHeader event) { ArrayList<CalorimeterHit> newHits = new ArrayList<CalorimeterHit>();
@@ -69,6 +81,7 @@
for (RawTrackerHit hit : hits) { CalorimeterHit newHit = converter.HitDtoA(hit);
+ if(applyBadCrystalMap && isBadCrystal(newHit)) continue;
if (newHit.getRawEnergy() > threshold) { newHits.add(newHit); }
@@ -80,6 +93,7 @@
for (BaseRawCalorimeterHit hit : hits) { CalorimeterHit newHit = converter.HitDtoA(hit, integralWindow); if (newHit.getRawEnergy() > threshold) {
+ if(applyBadCrystalMap && isBadCrystal(newHit)) continue;
newHits.add(newHit); } }
diff -u -r1.10 -r1.11 --- HPSEcalConditions.java 31 May 2012 00:28:19 -0000 1.10 +++ HPSEcalConditions.java 6 Jun 2012 18:29:01 -0000 1.11 @@ -17,7 +17,7 @@
/** * * @author meeg
- * @version $Id: HPSEcalConditions.java,v 1.10 2012/05/31 00:28:19 meeg Exp $
+ * @version $Id: HPSEcalConditions.java,v 1.11 2012/06/06 18:29:01 phansson Exp $
*/ public class HPSEcalConditions extends Driver {
@@ -52,6 +52,7 @@
} helper = subdetector.getDetectorElement().getIdentifierHelper(); fillDaqCellMap(subdetector);
+ loadBadChannels(subdetector);
} public void setSubdetectorName(String subdetectorName) {
@@ -164,6 +165,7 @@
expId.setValue(helper.getFieldIndex("ix"), x); expId.setValue(helper.getFieldIndex("iy"), y); badChannelsSet.add(helper.pack(expId).getValue());
+ System.out.println("Adding bad crystal " + x + "," + y);
} } }
diff -u -r1.1 -r1.2 --- ecal.badchannels 5 May 2012 11:46:26 -0000 1.1 +++ ecal.badchannels 6 Jun 2012 18:29:01 -0000 1.2 @@ -1 +1,7 @@
-#x y
\ No newline at end of file
+#2012-06-06 5*RMS(time) thresholds for runs 1351,1353,1354,1358,1359,1360,1362 +#x y +-22 -5 +2 2 +8 -5 +2 5 +8 -2
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