lcsim/src/org/lcsim/contrib/uiowa
diff -u -r1.20 -r1.21
--- NonTrivialPFA.java 21 Sep 2007 02:29:05 -0000 1.20
+++ NonTrivialPFA.java 4 Oct 2007 22:17:02 -0000 1.21
@@ -208,8 +208,13 @@
}
// Choose which track list to use
- trackList = cheatingTrackList;
- //trackList = nonCheatingTrackList;
+ boolean useRonTrackList = false;
+ if (useRonTrackList) {
+ trackList = cheatingTrackList;
+ mcListName = "PerfectRecoMCParticles";
+ } else {
+ trackList = nonCheatingTrackList;
+ }
}
// Find simple clusters
@@ -349,7 +354,7 @@
{
LocalHelixExtrapolationTrackClusterMatcher extrapolate = new LocalHelixExtrapolationTrackClusterMatcher();
extrapolate.setCutSeparation(14.0); // about two cells
- CheatTrackClusterMatcher cheater = new CheatTrackClusterMatcher("PerfectRecoMCParticles");
+ CheatTrackClusterMatcher cheater = new CheatTrackClusterMatcher(mcListName);
CheckSkeletonsForMultipleTracks separate = new CheckSkeletonsForMultipleTracks(evalWrapper, trackList, eventSkeletonClusters, eventSplitSkeletonClusters, eventMips, eventClumps, extrapolate);
//CheckSkeletonsForMultipleTracks separate = new CheckSkeletonsForMultipleTracks(evalWrapper, trackList, eventSkeletonClusters, eventSplitSkeletonClusters, eventMips, eventClumps, cheater);
add(cheater);
@@ -391,9 +396,9 @@
String eventOutputParticles = "UnflushedPFAReconstructedParticles";
String prefixHadronsMain = "merge_ron_ron__";
if (cheatOnFragments) {
- addHadronFinders(prefixHadronsMain, eventOutputParticles, fragIDCheat, fragMerge, eventMips, eventHaloMinusPhotonClusters, eventSmallClustersNotPhotons, trackList, eventSmallPhotonParticles, largePhotonParticleList, ronNeutralHadronCalib, ronNeutralHadronCalib, false);
+ addHadronFinders(prefixHadronsMain, eventOutputParticles, fragIDCheat, fragMerge, eventMips, eventHaloMinusPhotonClusters, eventSmallClustersNotPhotons, trackList, eventSmallPhotonParticles, largePhotonParticleList, ronNeutralHadronCalib, ronNeutralHadronCalib, false, mcListName);
} else {
- addHadronFinders(prefixHadronsMain, eventOutputParticles, fragID, fragMerge, eventMips, eventHaloMinusPhotonClusters, eventSmallClustersNotPhotons, trackList, eventSmallPhotonParticles, largePhotonParticleList, ronNeutralHadronCalib, ronChargedHadronCalib, false);
+ addHadronFinders(prefixHadronsMain, eventOutputParticles, fragID, fragMerge, eventMips, eventHaloMinusPhotonClusters, eventSmallClustersNotPhotons, trackList, eventSmallPhotonParticles, largePhotonParticleList, ronNeutralHadronCalib, ronChargedHadronCalib, false, mcListName);
}
// Flush the output list to make sure it's LCIO-compatible
@@ -729,7 +734,7 @@
add(new HaloAssigner(skeletonClusterList, inputHitMap, haloClusterList, outputHitMap));
}
- protected void addCheatingTrackMatcher(String prefix, String trackList, String inputMIPList, String inputHaloClusterList, String inputSmallClusterList, String outputParticleList, boolean checkEoverP, ClusterEnergyCalculator calibration, boolean debug)
+ protected void addCheatingTrackMatcher(String prefix, String trackList, String inputMIPList, String inputHaloClusterList, String inputSmallClusterList, String outputParticleList, boolean checkEoverP, ClusterEnergyCalculator calibration, boolean debug, String mcListName)
{
System.out.println("WARNING: Cheating on track matching");
// Merge input cluster lists
@@ -743,10 +748,7 @@
// Try the clusters generically:
SimpleChargedParticleMaker hadID = new SimpleChargedParticleMaker();
- //List<String> hitCollections = new Vector<String>();
- //hitCollections.add("EcalBarrDigiHits");
- //hitCollections.add("EcalEndcapDigiHits");
- CheatTrackClusterMatcher clusMatch = new CheatTrackClusterMatcher("PerfectRecoMCParticles");
+ CheatTrackClusterMatcher clusMatch = new CheatTrackClusterMatcher(mcListName);
clusMatch.setDebug(false);
add(clusMatch);
hadID.setTrackMatcher(clusMatch);
@@ -920,7 +922,8 @@
String largePhotonParticleList,
ClusterEnergyCalculator calibration,
ClusterEnergyCalculator calibrationForEoverP,
- boolean trackDebug)
+ boolean trackDebug,
+ String mcListName)
{
// Fragment handling
String clusterList = prefix+"clustersAfterFragmentHandling";
@@ -931,7 +934,7 @@
String tempChargedParticleList = prefix+"chargedHadronParticlesAfterFragmentHandling";
boolean applyEoverPcut = true;
addTrackMatcher(prefix+"FindCharged__", trackList, inputMIPList, clusterList, null, tempChargedParticleList, applyEoverPcut, calibrationForEoverP, trackDebug);
- //addCheatingTrackMatcher(prefix+"FindCharged__", trackList, inputMIPList, clusterList, null, tempChargedParticleList, applyEoverPcut, calibrationForEoverP, trackDebug);
+ //addCheatingTrackMatcher(prefix+"FindCharged__", trackList, inputMIPList, clusterList, null, tempChargedParticleList, applyEoverPcut, calibrationForEoverP, trackDebug, mcListName);
if (trackDebug) {
System.out.println(prefix+": Will write out charged particles as '"+tempChargedParticleList+"'");
}