CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
HybridClusterAlgo.h
Go to the documentation of this file.
1 #ifndef RecoEcal_EgammaClusterAlgos_HybridClusterAlgo_h
2 #define RecoEcal_EgammaClusterAlgos_HybridClusterAlgo_h
3 
18 
20 
21 #include <vector>
22 #include <set>
23 
25 
27 private:
28  //Quick typedef for position calculation.
30 
31  //Thresholds for seeds.
32  double eb_st;
33 
34  //Number of steps in phi that the Hybrid algorithm will take
35  //when clustering. Remember, uses phiSteps_ in positive direction
36  //and then phiSteps_ in negative direction.
37  int phiSteps_;
38 
39  // et in 25
41  const EcalRecHitCollection *hits,
43  // ratio Et/e
45  const EcalRecHitCollection *hits,
47 
49 
50  //Threshold for basic cluster.
51  double eThres_;
52  double eThresA_;
53  double eThresB_;
54 
55  //Threshold for becoming a sub-peak in the supercluster.
56  double Eseed;
57 
58  //Coefficient to increase Eseed as a function of 5x5
59  double Xi;
60 
61  //Increase Eseed as a function of et_5x5 (othwewise it's e_5x5)
62  bool UseEtForXi;
63 
64  //Threshold for adding the additional two 'wing' cells to domino.
65  double Ewing;
66 
67  // do dynamic phi road
69 
70  // do dynamic ethres
72 
73  //Map of DetId, RecHit relationship. EcalRecHit knows what DetId it is,
74  //but DetId doesn't know what EcalRecHit it is.
75  // std::map<DetId, EcalRecHit> rechits_m;
76 
77  // colection of all rechits
79 
80  // topology
82 
83  // SuperClusterShapeAlgo* SCShape_;
84 
85  //Set of DetIds that have already been used.
86  std::set<DetId> useddetids;
87 
88  // The vector of seeds:
89  std::vector<EcalRecHit> seeds;
90 
91  //The vector of seed clusters:
92  std::vector<reco::BasicCluster> seedClus_;
93 
94  //Map of basicclusters and what supercluster they will belong to.
95  std::map<int, std::vector<reco::BasicCluster> > clustered_;
96 
97  //algo to calulate position of clusters
99 
100  // channels not to be used for seeding
101  std::vector<int> v_chstatus_;
102 
103  // severity levels to discriminate against
104  std::vector<int> v_severitylevel_;
107 
109  std::set<DetId> excludedCrys_;
110 
111 public:
112  //The default constructor
114 
115  //The real constructor
116  HybridClusterAlgo(double eb_str,
117  int step,
118  double ethres,
119  double eseed,
120  double xi,
121  bool useEtForXi,
122  double ewing,
123  const std::vector<int> &v_chstatus,
124  const PositionCalc &posCalculator,
125  bool dynamicEThres = false,
126  double eThresA = 0,
127  double eThresB = 0.1,
128  const std::vector<int> &severityToExclude = std::vector<int>().operator=(std::vector<int>(999)),
129  //double severityRecHitThreshold=0.08,
130  //int severitySpikeId=1,
131  //double severitySpikeThreshold=0,
132  bool excludeFromCluster = false);
133  // const edm::ParameterSet &bremRecoveryPset,
134 
135  // destructor
137  if (dynamicPhiRoad_)
138  delete phiRoadAlgo_;
139  delete topo_;
140  // delete SCShape_;
141  }
142 
143  void setDynamicPhiRoad(const edm::ParameterSet &bremRecoveryPset) {
144  dynamicPhiRoad_ = true;
145  phiRoadAlgo_ = new BremRecoveryPhiRoadAlgo(bremRecoveryPset);
146  }
147 
148  //Hand over the map, the geometry, and I'll hand you back clusters.
149  void makeClusters(const EcalRecHitCollection *,
151  reco::BasicClusterCollection &basicClusters,
152  const EcalSeverityLevelAlgo *sevLv,
153  bool regional = false,
154  const std::vector<RectangularEtaPhiRegion> &regions = std::vector<RectangularEtaPhiRegion>());
155 
156  //Make superclusters from the references to the BasicClusters in the event.
158 
159  //The routine doing the real work.
160  void mainSearch(const EcalRecHitCollection *hits, const CaloSubdetectorGeometry *geometry);
161 
162  //Make dominos for the hybrid method.
163  double makeDomino(EcalBarrelNavigatorHT &navigator, std::vector<EcalRecHit> &cells);
164 };
165 
166 #endif
EcalBarrelHardcodedTopology * topo_
void mainSearch(const EcalRecHitCollection *hits, const CaloSubdetectorGeometry *geometry)
std::map< int, std::vector< reco::BasicCluster > > clustered_
double e2Et(EcalBarrelNavigatorHT &navigator, const EcalRecHitCollection *hits, const CaloSubdetectorGeometry *geometry)
PositionCalc posCalculator_
std::vector< EcalRecHit > seeds
std::vector< SuperCluster > SuperClusterCollection
collection of SuperCluser objectr
reco::SuperClusterCollection makeSuperClusters(const reco::CaloClusterPtrVector &)
BremRecoveryPhiRoadAlgo * phiRoadAlgo_
std::vector< int > v_chstatus_
std::set< DetId > useddetids
double et25(EcalBarrelNavigatorHT &navigator, const EcalRecHitCollection *hits, const CaloSubdetectorGeometry *geometry)
void setDynamicPhiRoad(const edm::ParameterSet &bremRecoveryPset)
std::set< DetId > excludedCrys_
math::XYZPoint Point
std::vector< int > v_severitylevel_
caConstants::TupleMultiplicity const CAHitNtupletGeneratorKernelsGPU::HitToTuple const cms::cuda::AtomicPairCounter GPUCACell const *__restrict__ cells
double makeDomino(EcalBarrelNavigatorHT &navigator, std::vector< EcalRecHit > &cells)
XYZPointD XYZPoint
point in space with cartesian internal representation
Definition: Point3D.h:12
std::vector< BasicCluster > BasicClusterCollection
collection of BasicCluster objects
const EcalRecHitCollection * recHits_
step
Definition: StallMonitor.cc:98
void makeClusters(const EcalRecHitCollection *, const CaloSubdetectorGeometry *geometry, reco::BasicClusterCollection &basicClusters, const EcalSeverityLevelAlgo *sevLv, bool regional=false, const std::vector< RectangularEtaPhiRegion > &regions=std::vector< RectangularEtaPhiRegion >())
std::vector< reco::BasicCluster > seedClus_