CMS 3D CMS Logo

PFAnalyzer.h
Go to the documentation of this file.
1 #ifndef PFAnalyzer_H
2 #define PFAnalyzer_H
3 
12 #include <memory>
13 #include <fstream>
14 #include <utility>
15 #include <string>
16 #include <cmath>
17 #include <map>
18 
28 
33 
37 
41 
44 
47 
49 class PFAnalyzer;
50 
51 class PFAnalyzer : public DQMEDAnalyzer {
52 public:
55 
57  ~PFAnalyzer() override;
58 
60  void bookHistograms(DQMStore::IBooker&, edm::Run const&, edm::EventSetup const&) override;
61 
63  void analyze(const edm::Event&, const edm::EventSetup&) override;
64 
66  void dqmBeginRun(const edm::Run&, const edm::EventSetup&) override;
67 
68 private:
69  struct binInfo;
70  // A map between an observable name and a function that obtains that observable from a PFCandidate.
71  // This allows us to construct more complicated observables easily, and have it more configurable
72  // in the config file.
73  std::map<std::string, std::function<double(const reco::PFCandidate)>> m_funcMap;
74  std::map<std::string, std::function<double(const reco::PFCandidateCollection, reco::PFCandidate::ParticleType pfType)>>
77  std::function<double(const std::vector<reco::PFCandidatePtr> pfCands, reco::PFCandidate::ParticleType pfType)>>
79  std::map<std::string, std::function<double(const reco::PFCandidate, const reco::PFJet)>> m_pfInJetFuncMap;
80  std::map<std::string, std::function<double(const reco::PFJet)>> m_jetFuncMap;
81 
83 
84  // Book MonitorElements
86 
88 
89  int getPFBin(const reco::PFCandidate pfCand, int i);
90  int getJetBin(const reco::PFJet jetCand, int i);
91 
92  int getBinNumber(double binVal, std::vector<double> bins);
93  int getBinNumbers(std::vector<double> binVal, std::vector<std::vector<double>> bins);
94  std::vector<double> getBinList(std::string binString);
95 
96  std::vector<std::string> getAllSuffixes(std::vector<std::string> observables,
97  std::vector<std::vector<double>> binnings);
98  std::string stringWithDecimals(int bin, std::vector<double> bins);
99 
100  std::string getSuffix(std::vector<int> binList,
101  std::vector<std::string> observables,
102  std::vector<std::vector<double>> binnings);
103 
104  static double getEnergySpectrum(const reco::PFCandidate pfCand, const reco::PFJet jet) {
105  if (!jet.pt())
106  return -1;
107  return pfCand.pt() / jet.pt();
108  }
109 
111  int nPF = 0;
112  for (auto pfCand : pfCands) {
113  // We use X to indicate all
114  if (pfCand.particleId() == pfType || pfType == reco::PFCandidate::ParticleType::X) {
115  nPF++;
116  }
117  }
118  return nPF;
119  }
120 
121  static double getNPFCinJet(const std::vector<reco::PFCandidatePtr> pfCands, reco::PFCandidate::ParticleType pfType) {
122  int nPF = 0;
123  for (auto pfCand : pfCands) {
124  if (!pfCand)
125  continue;
126  // We use X to indicate all
127  if (pfCand->particleId() == pfType || pfType == reco::PFCandidate::ParticleType::X)
128  nPF++;
129  }
130  return nPF;
131  }
132 
133  // Various functions designed to get information from a PF canddidate
134  static double getPt(const reco::PFCandidate pfCand) { return pfCand.pt(); }
135  static double getEnergy(const reco::PFCandidate pfCand) { return pfCand.energy(); }
136  static double getEta(const reco::PFCandidate pfCand) { return pfCand.eta(); }
137  static double getAbsEta(const reco::PFCandidate pfCand) { return std::abs(pfCand.eta()); }
138  static double getPhi(const reco::PFCandidate pfCand) { return pfCand.phi(); }
139 
140  static double getHadCalibration(const reco::PFCandidate pfCand) {
141  if (pfCand.rawHcalEnergy() == 0)
142  return -1;
143  return pfCand.hcalEnergy() / pfCand.rawHcalEnergy();
144  }
145 
146  static double getTime(const reco::PFCandidate pfCand) { return pfCand.time(); }
147 
148  static double getHcalEnergy_depth1(const reco::PFCandidate pfCand) { return pfCand.hcalDepthEnergyFraction(1); }
149  static double getHcalEnergy_depth2(const reco::PFCandidate pfCand) { return pfCand.hcalDepthEnergyFraction(2); }
150  static double getHcalEnergy_depth3(const reco::PFCandidate pfCand) { return pfCand.hcalDepthEnergyFraction(3); }
151  static double getHcalEnergy_depth4(const reco::PFCandidate pfCand) { return pfCand.hcalDepthEnergyFraction(4); }
152  static double getHcalEnergy_depth5(const reco::PFCandidate pfCand) { return pfCand.hcalDepthEnergyFraction(5); }
153  static double getHcalEnergy_depth6(const reco::PFCandidate pfCand) { return pfCand.hcalDepthEnergyFraction(6); }
154  static double getHcalEnergy_depth7(const reco::PFCandidate pfCand) { return pfCand.hcalDepthEnergyFraction(7); }
155 
156  static double getEcalEnergy(const reco::PFCandidate pfCand) { return pfCand.ecalEnergy(); }
157  static double getRawEcalEnergy(const reco::PFCandidate pfCand) { return pfCand.rawEcalEnergy(); }
158  static double getHcalEnergy(const reco::PFCandidate pfCand) { return pfCand.hcalEnergy(); }
159  static double getRawHcalEnergy(const reco::PFCandidate pfCand) { return pfCand.rawHcalEnergy(); }
160  static double getHOEnergy(const reco::PFCandidate pfCand) { return pfCand.hoEnergy(); }
161  static double getRawHOEnergy(const reco::PFCandidate pfCand) { return pfCand.rawHoEnergy(); }
162 
163  static double getMVAIsolated(const reco::PFCandidate pfCand) { return pfCand.mva_Isolated(); }
164  static double getMVAEPi(const reco::PFCandidate pfCand) { return pfCand.mva_e_pi(); }
165  static double getMVAEMu(const reco::PFCandidate pfCand) { return pfCand.mva_e_mu(); }
166  static double getMVAPiMu(const reco::PFCandidate pfCand) { return pfCand.mva_pi_mu(); }
167  static double getMVANothingGamma(const reco::PFCandidate pfCand) { return pfCand.mva_nothing_gamma(); }
168  static double getMVANothingNH(const reco::PFCandidate pfCand) { return pfCand.mva_nothing_nh(); }
169  static double getMVAGammaNH(const reco::PFCandidate pfCand) { return pfCand.mva_gamma_nh(); }
170 
171  static double getDNNESigIsolated(const reco::PFCandidate pfCand) { return pfCand.dnn_e_sigIsolated(); }
172  static double getDNNESigNonIsolated(const reco::PFCandidate pfCand) { return pfCand.dnn_e_sigNonIsolated(); }
173  static double getDNNEBkgNonIsolated(const reco::PFCandidate pfCand) { return pfCand.dnn_e_bkgNonIsolated(); }
174  static double getDNNEBkgTauIsolated(const reco::PFCandidate pfCand) { return pfCand.dnn_e_bkgTau(); }
175  static double getDNNEBkgPhotonIsolated(const reco::PFCandidate pfCand) { return pfCand.dnn_e_bkgPhoton(); }
176 
177  static double getECalEFrac(const reco::PFCandidate pfCand) { return pfCand.ecalEnergy() / pfCand.energy(); }
178  static double getHCalEFrac(const reco::PFCandidate pfCand) { return pfCand.hcalEnergy() / pfCand.energy(); }
179  static double getTrackPt(const reco::PFCandidate pfCand) {
180  if (pfCand.trackRef().isNonnull())
181  return (pfCand.trackRef())->pt();
182  return 0;
183  }
184 
185  static double getEoverP(const reco::PFCandidate pfCand) {
186  double energy = 0;
187  int maxElement = pfCand.elementsInBlocks().size();
188  for (int e = 0; e < maxElement; ++e) {
189  // Get elements from block
190  reco::PFBlockRef blockRef = pfCand.elementsInBlocks()[e].first;
191  const edm::OwnVector<reco::PFBlockElement>& elements = blockRef->elements();
192  for (unsigned iEle = 0; iEle < elements.size(); iEle++) {
193  if (elements[iEle].index() == pfCand.elementsInBlocks()[e].second) {
194  if (elements[iEle].type() == reco::PFBlockElement::HCAL ||
195  elements[iEle].type() == reco::PFBlockElement::ECAL) { // Element is HB or HE
196  reco::PFClusterRef clusterref = elements[iEle].clusterRef();
197  reco::PFCluster cluster = *clusterref;
198  energy += cluster.energy();
199  }
200  }
201  }
202  }
203  return energy / pfCand.p();
204  }
205 
206  static double getHCalEnergy(const reco::PFCandidate pfCand) {
207  double energy = 0;
208  int maxElement = pfCand.elementsInBlocks().size();
209  for (int e = 0; e < maxElement; ++e) {
210  // Get elements from block
211  reco::PFBlockRef blockRef = pfCand.elementsInBlocks()[e].first;
212  const edm::OwnVector<reco::PFBlockElement>& elements = blockRef->elements();
213  for (unsigned iEle = 0; iEle < elements.size(); iEle++) {
214  if (elements[iEle].index() == pfCand.elementsInBlocks()[e].second) {
215  if (elements[iEle].type() == reco::PFBlockElement::HCAL) { // Element is HB or HE
216  // Get cluster and hits
217  reco::PFClusterRef clusterref = elements[iEle].clusterRef();
218  reco::PFCluster cluster = *clusterref;
219  //std::vector<std::pair<DetId, float>> hitsAndFracs = cluster.hitsAndFractions();
220  energy += cluster.energy();
221  }
222  }
223  }
224  }
225  return energy;
226  }
227 
228  static double getECalEnergy(const reco::PFCandidate pfCand) {
229  double energy = 0;
230  int maxElement = pfCand.elementsInBlocks().size();
231  for (int e = 0; e < maxElement; ++e) {
232  // Get elements from block
233  reco::PFBlockRef blockRef = pfCand.elementsInBlocks()[e].first;
234  const edm::OwnVector<reco::PFBlockElement>& elements = blockRef->elements();
235  for (unsigned iEle = 0; iEle < elements.size(); iEle++) {
236  if (elements[iEle].index() == pfCand.elementsInBlocks()[e].second) {
237  if (elements[iEle].type() == reco::PFBlockElement::ECAL) { // Element is HB or HE
238  // Get cluster and hits
239  reco::PFClusterRef clusterref = elements[iEle].clusterRef();
240  // When we don't have isolated tracks, this will be a bit useless, since the energy is shared across multiple tracks
241  reco::PFCluster cluster = *clusterref;
242  energy += cluster.energy();
243  }
244  }
245  }
246  }
247  return energy;
248  }
249 
250  static double getNTracksInBlock(const reco::PFCandidate pfCand) {
251  // We need this function to return a double, even though this is an integer value
252  double nTrack = 0;
253  int maxElement = pfCand.elementsInBlocks().size();
254  for (int e = 0; e < maxElement; ++e) {
255  // Get elements from block
256  reco::PFBlockRef blockRef = pfCand.elementsInBlocks()[e].first;
257  const edm::OwnVector<reco::PFBlockElement>& elements = blockRef->elements();
258  for (unsigned iEle = 0; iEle < elements.size(); iEle++) {
259  if (elements[iEle].index() == pfCand.elementsInBlocks()[e].second) {
260  if (elements[iEle].type() == reco::PFBlockElement::TRACK) { // Element is HB or HE
261  nTrack += 1;
262  }
263  }
264  }
265  }
266  return nTrack;
267  }
268 
269  static double getJetPt(const reco::PFJet jet) { return jet.pt(); }
270 
275 
278 
280 
285 
286  std::vector<std::vector<std::string>> m_allSuffixes;
287  std::vector<std::vector<std::string>> m_allJetSuffixes;
288 
289  // The directory where the output is stored
291 
292  // All of the histograms, stored as a map between the histogram name and the histogram
293  std::map<std::string, MonitorElement*> map_of_MEs;
294 
295  //check later if we need only one set of parameters
297 
298  typedef std::vector<std::string> vstring;
299  typedef std::vector<double> vDouble;
300  // Information on which observables to make histograms for.
301  // In the config file, this should come as a comma-separated list of
302  // the observable name, the number of bins for the histogram, and
303  // the lowest and highest values for the histogram.
304  // The observable name should have an entry in m_funcMap to define how
305  // it can be retrieved from a PFCandidate.
309 
313 
314  // Information on what cuts should be applied to PFCandidates that are
315  // being monitored. In the config file, this should come as a comma-separated list of
316  // the observable name, and the lowest and highest values for the histogram.
317  // The observable name should have an entry in m_funcMap to define how
318  // it can be retrieved from a PFCandidate.
320  std::vector<std::vector<std::string>> m_fullCutList;
321  std::vector<std::vector<std::vector<double>>> m_binList;
322 
323  // Information on what cuts should be applied to PFJets, in the case that we
324  // match PFCs to jets.In the config file, this should come as a comma-separated list of
325  // the observable name, and the lowest and highest values for the histogram.
326  // The observable name should have an entry in m_jetFuncMap to define how
327  // it can be retrieved from a PFJet.
329  std::vector<std::vector<std::string>> m_fullJetCutList;
330  std::vector<std::vector<std::vector<double>>> m_jetBinList;
331 
333 
334  // The dR radius used to match PFCs to jets.
335  // Making this configurable is useful in case you want to look at the core of a jet.
337 
338  std::vector<std::string> m_pfNames;
339 };
340 
344  int nBins;
345  double binMin;
346  double binMax;
347 };
348 
350 #endif
float mva_e_mu() const
mva for electron-muon discrimination
Definition: PFCandidate.h:323
edm::EDGetTokenT< edm::ValueMap< float > > weightsToken_
Definition: PFAnalyzer.h:276
void bookHistograms(DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &) override
Inizialize parameters for histo binning.
Definition: PFAnalyzer.cc:152
std::vector< std::vector< std::vector< double > > > m_jetBinList
Definition: PFAnalyzer.h:330
ParticleType
particle types
Definition: PFCandidate.h:44
static double getDNNESigIsolated(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:171
std::vector< std::vector< std::vector< double > > > m_binList
Definition: PFAnalyzer.h:321
int getBinNumber(double binVal, std::vector< double > bins)
Definition: PFAnalyzer.cc:477
edm::EDGetTokenT< edm::TriggerResults > triggerResultsToken_
Definition: PFAnalyzer.h:284
double pt() const final
transverse momentum
float mva_nothing_gamma() const
mva for gamma detection
Definition: PFCandidate.h:335
void dqmBeginRun(const edm::Run &, const edm::EventSetup &) override
Initialize run-based parameters.
Definition: PFAnalyzer.cc:363
Particle flow cluster, see clustering algorithm in PFClusterAlgo.
Definition: PFCluster.h:42
static double getRawHOEnergy(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:161
static double getDNNEBkgPhotonIsolated(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:175
static double getHcalEnergy_depth5(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:152
float time() const
Definition: PFCandidate.h:423
binInfo getBinInfo(std::string)
Definition: PFAnalyzer.cc:333
double rawHcalEnergy() const
return raw Hcal energy
Definition: PFCandidate.h:236
float mva_gamma_nh() const
mva for neutral hadron - gamma discrimination
Definition: PFCandidate.h:372
float mva_nothing_nh() const
mva for neutral hadron detection
Definition: PFCandidate.h:341
float hcalDepthEnergyFraction(unsigned int depth) const
fraction of hcal energy at a given depth (depth = 1 .. 7)
Definition: PFCandidate.h:433
static double getHCalEnergy(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:206
edm::InputTag highPtJetExpr_
Definition: PFAnalyzer.h:283
#define X(str)
Definition: MuonsGrabber.cc:38
std::map< std::string, std::function< double(const reco::PFJet)> > m_jetFuncMap
Definition: PFAnalyzer.h:80
void analyze(const edm::Event &, const edm::EventSetup &) override
Get the analysis.
Definition: PFAnalyzer.cc:528
bool isNonnull() const
Checks for non-null.
Definition: Ref.h:232
static double getJetPt(const reco::PFJet jet)
Definition: PFAnalyzer.h:269
edm::ParameterSet parameters_
Definition: PFAnalyzer.h:296
std::vector< std::vector< std::string > > m_allJetSuffixes
Definition: PFAnalyzer.h:287
double rawHoEnergy() const
return raw Hcal energy
Definition: PFCandidate.h:248
static double getHOEnergy(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:160
std::vector< std::vector< std::string > > m_fullCutList
Definition: PFAnalyzer.h:320
int getPFBin(const reco::PFCandidate pfCand, int i)
Definition: PFAnalyzer.cc:509
float mva_pi_mu() const
mva for pi-muon discrimination
Definition: PFCandidate.h:329
std::vector< double > vDouble
Definition: PFAnalyzer.h:299
Jets made from PFObjects.
Definition: PFJet.h:20
vstring m_eventObservableNames
Definition: PFAnalyzer.h:311
float dnn_e_bkgTau() const
Definition: PFCandidate.h:360
static double getMVAEMu(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:165
static double getHCalEFrac(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:178
std::vector< std::string > m_pfNames
Definition: PFAnalyzer.h:338
vstring m_jetCutList
Definition: PFAnalyzer.h:328
float dnn_e_sigNonIsolated() const
Definition: PFCandidate.h:352
vDouble m_npvBins
Definition: PFAnalyzer.h:332
int iEvent
Definition: GenABIO.cc:224
std::map< std::string, MonitorElement * > map_of_MEs
Definition: PFAnalyzer.h:293
static double getTime(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:146
static double getNTracksInBlock(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:250
std::string getSuffix(std::vector< int > binList, std::vector< std::string > observables, std::vector< std::vector< double >> binnings)
Definition: PFAnalyzer.cc:462
double p() const final
magnitude of momentum vector
static double getEta(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:136
const ElementsInBlocks & elementsInBlocks() const
Definition: PFCandidate.cc:665
static double getECalEFrac(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:177
vstring m_eventObservables
Definition: PFAnalyzer.h:307
static double getEnergy(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:135
double hcalEnergy() const
return corrected Hcal energy
Definition: PFCandidate.h:233
int getJetBin(const reco::PFJet jetCand, int i)
Definition: PFAnalyzer.cc:518
static double getDNNEBkgNonIsolated(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:173
std::vector< std::string > vstring
Definition: PFAnalyzer.h:298
edm::InputTag vertexTag_
Definition: PFAnalyzer.h:282
static double getHadCalibration(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:140
edm::InputTag theTriggerResultsLabel_
Definition: PFAnalyzer.h:281
vstring m_pfInJetObservables
Definition: PFAnalyzer.h:308
double energy() const
cluster energy
Definition: PFCluster.h:74
std::map< std::string, std::function< double(const reco::PFCandidate, const reco::PFJet)> > m_pfInJetFuncMap
Definition: PFAnalyzer.h:79
Abs< T >::type abs(const T &t)
Definition: Abs.h:22
double m_matchingRadius
Definition: PFAnalyzer.h:336
static double getHcalEnergy_depth3(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:150
#define DEFINE_FWK_MODULE(type)
Definition: MakerMacros.h:16
float dnn_e_sigIsolated() const
Definition: PFCandidate.h:348
std::map< std::string, std::function< double(const std::vector< reco::PFCandidatePtr > pfCands, reco::PFCandidate::ParticleType pfType)> > m_jetWideFuncMap
Definition: PFAnalyzer.h:78
static double getEcalEnergy(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:156
std::vector< std::string > getAllSuffixes(std::vector< std::string > observables, std::vector< std::vector< double >> binnings)
Definition: PFAnalyzer.cc:423
double ecalEnergy() const
return corrected Ecal energy
Definition: PFCandidate.h:221
static double getRawHcalEnergy(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:159
edm::EDGetTokenT< reco::PFJetCollection > pfJetsToken_
Definition: PFAnalyzer.h:273
edm::InputTag srcWeights
Definition: PFAnalyzer.h:274
float dnn_e_bkgPhoton() const
Definition: PFCandidate.h:364
PFAnalyzer(const edm::ParameterSet &)
Constructor.
Definition: PFAnalyzer.cc:12
static double getRawEcalEnergy(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:157
double hoEnergy() const
return corrected Hcal energy
Definition: PFCandidate.h:245
std::vector< std::vector< std::string > > m_fullJetCutList
Definition: PFAnalyzer.h:329
std::vector< reco::PFCandidate > PFCandidateCollection
collection of PFCandidates
int getBinNumbers(std::vector< double > binVal, std::vector< std::vector< double >> bins)
Definition: PFAnalyzer.cc:488
static double getEoverP(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:185
float mva_Isolated() const
Definition: PFCandidate.h:313
std::string m_directory
Definition: PFAnalyzer.h:290
static double getMVAPiMu(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:166
static double getPhi(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:138
float dnn_e_bkgNonIsolated() const
Definition: PFCandidate.h:356
std::map< std::string, std::function< double(const reco::PFCandidateCollection, reco::PFCandidate::ParticleType pfType)> > m_eventFuncMap
Definition: PFAnalyzer.h:75
std::string observable
Definition: PFAnalyzer.h:342
bool passesEventSelection(const edm::Event &iEvent)
Definition: PFAnalyzer.cc:365
edm::ValueMap< float > const * weights_
Definition: PFAnalyzer.h:277
std::string stringWithDecimals(int bin, std::vector< double > bins)
Definition: PFAnalyzer.cc:368
static double getMVAEPi(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:164
static double getMVAGammaNH(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:169
static double getHcalEnergy_depth4(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:151
edm::EDGetTokenT< reco::PFCandidateCollection > thePfCandidateCollection_
Definition: PFAnalyzer.h:271
void bookMESetSelection(std::string, DQMStore::IBooker &)
Definition: PFAnalyzer.cc:358
static double getECalEnergy(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:228
Particle reconstructed by the particle flow algorithm.
Definition: PFCandidate.h:41
static double getHcalEnergy(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:158
std::vector< double > getBinList(std::string binString)
Definition: PFAnalyzer.cc:399
edm::EDGetTokenT< GenEventInfoProduct > tok_ew_
Definition: PFAnalyzer.h:279
static double getNPFC(const reco::PFCandidateCollection pfCands, reco::PFCandidate::ParticleType pfType)
Definition: PFAnalyzer.h:110
static double getDNNESigNonIsolated(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:172
static double getHcalEnergy_depth1(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:148
static double getDNNEBkgTauIsolated(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:174
reco::TrackRef trackRef() const
Definition: PFCandidate.cc:437
static double getMVANothingGamma(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:167
static double getNPFCinJet(const std::vector< reco::PFCandidatePtr > pfCands, reco::PFCandidate::ParticleType pfType)
Definition: PFAnalyzer.h:121
std::vector< std::vector< std::string > > m_allSuffixes
Definition: PFAnalyzer.h:286
static double getMVANothingNH(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:168
double rawEcalEnergy() const
return corrected Ecal energy
Definition: PFCandidate.h:224
std::string axisName
Definition: PFAnalyzer.h:343
static double getAbsEta(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:137
edm::EDGetTokenT< std::vector< reco::Vertex > > vertexToken_
Definition: PFAnalyzer.h:272
vstring m_observableNames
Definition: PFAnalyzer.h:310
static double getTrackPt(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:179
static double getEnergySpectrum(const reco::PFCandidate pfCand, const reco::PFJet jet)
Definition: PFAnalyzer.h:104
static double getHcalEnergy_depth6(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:153
double phi() const final
momentum azimuthal angle
std::map< std::string, std::function< double(const reco::PFCandidate)> > m_funcMap
Definition: PFAnalyzer.h:69
vstring m_cutList
Definition: PFAnalyzer.h:319
static double getMVAIsolated(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:163
~PFAnalyzer() override
Destructor.
Definition: PFAnalyzer.cc:149
static double getHcalEnergy_depth2(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:149
vstring m_pfInJetObservableNames
Definition: PFAnalyzer.h:312
vstring m_observables
Definition: PFAnalyzer.h:306
float mva_e_pi() const
mva for electron-pion discrimination
Definition: PFCandidate.h:317
Definition: Run.h:45
static double getHcalEnergy_depth7(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:154
static double getPt(const reco::PFCandidate pfCand)
Definition: PFAnalyzer.h:134
double energy() const final
energy
double eta() const final
momentum pseudorapidity