3 modified files
lcsim/src/org/lcsim/recon/pfa/structural
diff -u -r1.3 -r1.4
--- FuzzyQNeutralHadronClusterEnergyCalculator.java 12 Aug 2008 23:45:11 -0000 1.3
+++ FuzzyQNeutralHadronClusterEnergyCalculator.java 10 Sep 2008 17:31:09 -0000 1.4
@@ -14,7 +14,7 @@
* an extension of Ron's QNeutralHadronClusterEnergyCalculator
* class.
*
- * @version $Id: FuzzyQNeutralHadronClusterEnergyCalculator.java,v 1.3 2008/08/12 23:45:11 mcharles Exp $
+ * @version $Id: FuzzyQNeutralHadronClusterEnergyCalculator.java,v 1.4 2008/09/10 17:31:09 mcharles Exp $
*/
public class FuzzyQNeutralHadronClusterEnergyCalculator extends QNeutralHadronClusterEnergyCalculator
@@ -32,6 +32,25 @@
super(calFile, analog);
}
+ boolean m_sid01 = false;
+ boolean m_sid02 = false;
+ protected void init() {
+ super.init();
+ String detectorName = _mgr.getDetector();
+ if (detectorName.contains("sid01")) {
+ m_sid01 = true;
+ }
+ if (detectorName.contains("sid02")) {
+ m_sid02 = true;
+ }
+ if (!m_sid01 && !m_sid02) {
+ System.out.println("WARNING: I don't know how to handle muon endcap calibration for detector "+detectorName+" -- hits will be ignored");
+ } else if (m_sid01 && m_sid02) {
+ throw new AssertionError("Internal inconsistency when parsing detector name "+detectorName);
+ }
+ }
+
+
/** Find the energy of this cluster. */
public double getEnergy(Cluster c)
{
@@ -125,12 +144,22 @@
EmeasEst += hitWeight * ((Ehit/(1. + alpha*(1./st - 1.)))/muonSamplingFraction);
} else if (detector_index == 4) {
// Muon barrel
- double muonSamplingFraction = 2.53; // 0.396 GeV per hit => 2.53
- double Ehit = 1.0;
- double[] pos = hit.getPosition();
- double R = Math.sqrt(pos[0]*pos[0]+pos[1]*pos[1]+pos[2]*pos[2]);
- double st = Math.abs(pos[2])/R;
- EmeasEst += hitWeight * ((Ehit/(1. + alpha*(1./st - 1.)))/muonSamplingFraction);
+ boolean skipMuonHits = true;
+ double muonSamplingFraction = Double.NaN;
+ if (m_sid01) {
+ muonSamplingFraction = 2.53; // 0.396 GeV per hit => 2.53
+ skipMuonHits = false;
+ } else if (m_sid02) {
+ muonSamplingFraction = 0.82171; // Taken from properties file for sid02
+ skipMuonHits = false;
+ }
+ if (!skipMuonHits) {
+ double Ehit = 1.0;
+ double[] pos = hit.getPosition();
+ double R = Math.sqrt(pos[0]*pos[0]+pos[1]*pos[1]+pos[2]*pos[2]);
+ double st = Math.abs(pos[2])/R;
+ EmeasEst += hitWeight * ((Ehit/(1. + alpha*(1./st - 1.)))/muonSamplingFraction);
+ }
} else {
System.out.println("ERROR: Failed to recognize system id "+detector_index+" named "+hit.getSubdetector().getName());
}
lcsim/src/org/lcsim/recon/pfa/structural
diff -u -r1.13 -r1.14
--- ReclusterDTreeDriver.java 6 Sep 2008 23:47:26 -0000 1.13
+++ ReclusterDTreeDriver.java 10 Sep 2008 17:31:09 -0000 1.14
@@ -35,7 +35,7 @@
* in this package, which uses the implementation in
* org.lcsim.recon.cluster.directedtree developed by NIU).
*
- * @version $Id: ReclusterDTreeDriver.java,v 1.13 2008/09/06 23:47:26 mcharles Exp $
+ * @version $Id: ReclusterDTreeDriver.java,v 1.14 2008/09/10 17:31:09 mcharles Exp $
* @author Mat Charles <[log in to unmask]>
*/
@@ -86,7 +86,7 @@
protected boolean m_fixSingleTracksWithCone = true;
protected boolean m_fixJetsWithCone = true;
protected boolean m_useSimpleConeForReassignment = false;
- protected double m_minScoreForReassignment = 0.1;
+ protected double m_minScoreForReassignment = 0.7;
protected boolean m_debugSeedSplitting = false;
@@ -103,7 +103,7 @@
}
public ReclusterDTreeDriver(String dTreeClusterList, String trackList, String mcList) {
- System.out.println("ReclusterDTreeDriver version 0.43");
+ System.out.println("ReclusterDTreeDriver version 0.44");
initTrackMatch();
initCalibration();
initPlots();
@@ -1290,7 +1290,7 @@
if (result != null) {
for (int iLayer=0; iLayer<nLayers; iLayer++) {
Long cellID = result.extendToECALLayerAndFindCell(iLayer);
- if (allClusterHits.contains(cellID)) {
+ if (cellID != null && allClusterHits.contains(cellID)) {
countMatches++;
}
}
@@ -1308,7 +1308,7 @@
if (result != null) {
for (int iLayer=0; iLayer<nLayers; iLayer++) {
Long cellID = result.extendToECALLayerAndFindCell(iLayer);
- if (coreClusterHits.contains(cellID)) {
+ if (cellID != null && coreClusterHits.contains(cellID)) {
countMatches++;
}
}
lcsim/src/org/lcsim/recon/pfa/structural
diff -u -r1.11 -r1.12
--- ReclusterDriver.java 6 Sep 2008 23:47:26 -0000 1.11
+++ ReclusterDriver.java 10 Sep 2008 17:31:09 -0000 1.12
@@ -40,7 +40,7 @@
* This version is superseded by ReclusterDTreeDriver,
* which derives from it.
*
- * @version $Id: ReclusterDriver.java,v 1.11 2008/09/06 23:47:26 mcharles Exp $
+ * @version $Id: ReclusterDriver.java,v 1.12 2008/09/10 17:31:09 mcharles Exp $
* @author Mat Charles <[log in to unmask]>
*/
@@ -88,7 +88,12 @@
protected boolean m_checkSharedHitsForPunchThrough = true;
protected boolean m_allowLateralPunchThrough = false; // Set to FALSE for mucal enabled
+ // Various ways to do track extrapolation:
protected HelixExtrapolator m_findCluster = new org.lcsim.recon.pfa.identifier.LocalHelixExtrapolator();
+ //protected HelixExtrapolator m_findCluster = new org.lcsim.recon.pfa.identifier.TrackHelixExtrapolator();
+ //protected HelixExtrapolator m_findCluster = new org.lcsim.recon.pfa.identifier.TrackHelixPlusHitExtrapolator();
+
+ boolean m_useBackupTrackMatching = false;
protected ReclusterDriver() {
// Gah, debug only!
@@ -127,17 +132,20 @@
DualActionTrackClusterMatcher localHelixMatchers = new DualActionTrackClusterMatcher(mipMatch, genMatch);
add(mipMatch);
add(genMatch);
- // Try matching with full swimming to MIP or generic cluster:
- SimpleTrackMIPClusterMatcher mipMatchSimple = new SimpleTrackMIPClusterMatcher();
- SimpleTrackClusterMatcher genMatchSimple = new SimpleTrackClusterMatcher();
- DualActionTrackClusterMatcher simpleMatchers = new DualActionTrackClusterMatcher(mipMatchSimple, genMatchSimple);
- add(mipMatchSimple);
- add(genMatchSimple);
- // Combine:
- SequentialTrackClusterMatcher combinedTrackClusterMatcher = new SequentialTrackClusterMatcher();
- combinedTrackClusterMatcher.addMatcher(localHelixMatchers);
- combinedTrackClusterMatcher.addMatcher(simpleMatchers);
- m_trackClusterMatcher = combinedTrackClusterMatcher;
+ m_trackClusterMatcher = localHelixMatchers;
+ if (m_useBackupTrackMatching) {
+ // Try matching with full swimming to MIP or generic cluster:
+ SimpleTrackMIPClusterMatcher mipMatchSimple = new SimpleTrackMIPClusterMatcher();
+ SimpleTrackClusterMatcher genMatchSimple = new SimpleTrackClusterMatcher();
+ DualActionTrackClusterMatcher simpleMatchers = new DualActionTrackClusterMatcher(mipMatchSimple, genMatchSimple);
+ add(mipMatchSimple);
+ add(genMatchSimple);
+ // Combine:
+ SequentialTrackClusterMatcher combinedTrackClusterMatcher = new SequentialTrackClusterMatcher();
+ combinedTrackClusterMatcher.addMatcher(localHelixMatchers);
+ combinedTrackClusterMatcher.addMatcher(simpleMatchers);
+ m_trackClusterMatcher = combinedTrackClusterMatcher;
+ }
}
protected void initCalibration() {
CVSspam 0.2.8