CMS 3D CMS Logo

L1HPSPFTauBuilder.h
Go to the documentation of this file.
1 #ifndef L1Trigger_Phase2L1Taus_L1HPSPFTauBuilder_h
2 #define L1Trigger_Phase2L1Taus_L1HPSPFTauBuilder_h
3 
4 #include "FWCore/ParameterSet/interface/ParameterSet.h" // edm::ParameterSet
5 #include "DataFormats/Provenance/interface/ProductID.h" // edm::ProductID
6 #include "L1Trigger/Phase2L1Taus/interface/L1HPSPFTauQualityCut.h" // L1HPSPFTauQualityCut
7 #include "DataFormats/L1TParticleFlow/interface/HPSPFTau.h" // l1t::HPSPFTau
8 #include "DataFormats/L1TParticleFlow/interface/PFCandidate.h" // l1t::PFCandidate, l1t::PFCandidateCollection, l1t::PFCandidateRef
12 #include <vector>
13 
15 public:
17  ~L1HPSPFTauBuilder() = default;
18 
19  void reset();
20  void setL1PFCandProductID(const edm::ProductID& l1PFCandProductID);
22  void setL1PFTauSeed(const l1t::PFCandidateRef& l1PFCandSeed);
23  //void setL1PFTauSeed(const reco::CaloJetRef& l1Jet_seed);
24  void setL1PFTauSeed(const reco::CaloJetRef& l1JetSeed, const std::vector<l1t::PFCandidateRef>& l1PFCands);
25  void addL1PFCandidates(const std::vector<l1t::PFCandidateRef>& l1PFCands);
26  void buildL1PFTau();
27 
28  l1t::HPSPFTau getL1PFTau() const { return l1PFTau_; }
29 
30 private:
31  l1t::PFCandidateRefVector convertToRefVector(const std::vector<l1t::PFCandidateRef>& l1PFCands);
32 
33  bool isWithinSignalCone(const l1t::PFCandidate& l1PFCand);
34  bool isWithinStrip(const l1t::PFCandidate& l1PFCand);
35  bool isWithinIsolationCone(const l1t::PFCandidate& l1PFCand);
36 
38 
43 
44  bool useStrips_;
45  double stripSizeEta_;
46  double stripSizePhi_;
47 
50 
51  std::vector<L1HPSPFTauQualityCut> signalQualityCutsDzCutDisabled_;
52  std::vector<L1HPSPFTauQualityCut> signalQualityCutsDzCutEnabledPrimary_;
53  std::vector<L1HPSPFTauQualityCut> isolationQualityCutsDzCutDisabled_;
54  std::vector<L1HPSPFTauQualityCut> isolationQualityCutsDzCutEnabledPrimary_;
55  std::vector<L1HPSPFTauQualityCut> isolationQualityCutsDzCutEnabledPileup_;
67 
69 
70  std::vector<l1t::PFCandidateRef> signalAllL1PFCandidates_;
71  std::vector<l1t::PFCandidateRef> signalChargedHadrons_;
72  std::vector<l1t::PFCandidateRef> signalElectrons_;
73  std::vector<l1t::PFCandidateRef> signalNeutralHadrons_;
74  std::vector<l1t::PFCandidateRef> signalPhotons_;
75  std::vector<l1t::PFCandidateRef> signalMuons_;
76 
77  std::vector<l1t::PFCandidateRef> stripAllL1PFCandidates_;
78  std::vector<l1t::PFCandidateRef> stripElectrons_;
79  std::vector<l1t::PFCandidateRef> stripPhotons_;
80 
81  std::vector<l1t::PFCandidateRef> isoAllL1PFCandidates_;
82  std::vector<l1t::PFCandidateRef> isoChargedHadrons_;
83  std::vector<l1t::PFCandidateRef> isoElectrons_;
84  std::vector<l1t::PFCandidateRef> isoNeutralHadrons_;
85  std::vector<l1t::PFCandidateRef> isoPhotons_;
86  std::vector<l1t::PFCandidateRef> isoMuons_;
87 
88  std::vector<l1t::PFCandidateRef> sumAllL1PFCandidates_;
89  std::vector<l1t::PFCandidateRef> sumChargedHadrons_;
90  std::vector<l1t::PFCandidateRef> sumElectrons_;
91  std::vector<l1t::PFCandidateRef> sumNeutralHadrons_;
92  std::vector<l1t::PFCandidateRef> sumPhotons_;
93  std::vector<l1t::PFCandidateRef> sumMuons_;
94 
96 
97  bool debug_;
98 };
99 
100 #endif
L1HPSPFTauBuilder::~L1HPSPFTauBuilder
~L1HPSPFTauBuilder()=default
L1HPSPFTauBuilder::setVertex
void setVertex(const l1t::TkPrimaryVertexRef &primaryVertex)
Definition: L1HPSPFTauBuilder.cc:90
PFCandidate.h
L1HPSPFTauBuilder::sumChargedIsoPileup_
double sumChargedIsoPileup_
Definition: L1HPSPFTauBuilder.h:95
CaloJet.h
L1HPSPFTauBuilder::signalQualityCutsDzCutEnabledPrimary_
std::vector< L1HPSPFTauQualityCut > signalQualityCutsDzCutEnabledPrimary_
Definition: L1HPSPFTauBuilder.h:52
TkPrimaryVertex.h
L1HPSPFTauBuilder::l1PFCandSeed_
l1t::PFCandidateRef l1PFCandSeed_
Definition: L1HPSPFTauBuilder.h:58
L1HPSPFTauBuilder::stripP4_
reco::Particle::LorentzVector stripP4_
Definition: L1HPSPFTauBuilder.h:68
L1HPSPFTauBuilder::isolationQualityCutsDzCutDisabled_
std::vector< L1HPSPFTauQualityCut > isolationQualityCutsDzCutDisabled_
Definition: L1HPSPFTauBuilder.h:53
L1HPSPFTauBuilder::l1PFTauSeedEta_
double l1PFTauSeedEta_
Definition: L1HPSPFTauBuilder.h:61
L1HPSPFTauBuilder::sumChargedHadrons_
std::vector< l1t::PFCandidateRef > sumChargedHadrons_
Definition: L1HPSPFTauBuilder.h:89
L1HPSPFTauBuilder::stripSizePhi_
double stripSizePhi_
Definition: L1HPSPFTauBuilder.h:46
L1HPSPFTauBuilder::isoMuons_
std::vector< l1t::PFCandidateRef > isoMuons_
Definition: L1HPSPFTauBuilder.h:86
L1HPSPFTauBuilder::l1PFTauSeedZVtx_
double l1PFTauSeedZVtx_
Definition: L1HPSPFTauBuilder.h:63
L1HPSPFTauBuilder::isolationQualityCutsDzCutEnabledPrimary_
std::vector< L1HPSPFTauQualityCut > isolationQualityCutsDzCutEnabledPrimary_
Definition: L1HPSPFTauBuilder.h:54
L1HPSPFTauBuilder::isWithinSignalCone
bool isWithinSignalCone(const l1t::PFCandidate &l1PFCand)
Definition: L1HPSPFTauBuilder.cc:310
edm::RefVector< l1t::PFCandidateCollection >
L1HPSPFTauBuilder::addL1PFCandidates
void addL1PFCandidates(const std::vector< l1t::PFCandidateRef > &l1PFCands)
Definition: L1HPSPFTauBuilder.cc:183
L1HPSPFTauBuilder::l1PFCandProductID_
edm::ProductID l1PFCandProductID_
Definition: L1HPSPFTauBuilder.h:56
L1HPSPFTauBuilder::signalConeSizeFormula_
reco::FormulaEvaluator signalConeSizeFormula_
Definition: L1HPSPFTauBuilder.h:37
L1HPSPFTauBuilder::L1HPSPFTauBuilder
L1HPSPFTauBuilder(const edm::ParameterSet &cfg)
Definition: L1HPSPFTauBuilder.cc:10
L1HPSPFTauBuilder::stripPhotons_
std::vector< l1t::PFCandidateRef > stripPhotons_
Definition: L1HPSPFTauBuilder.h:79
reco::Particle::LorentzVector
math::XYZTLorentzVector LorentzVector
Lorentz vector.
Definition: Particle.h:21
L1HPSPFTauBuilder::stripAllL1PFCandidates_
std::vector< l1t::PFCandidateRef > stripAllL1PFCandidates_
Definition: L1HPSPFTauBuilder.h:77
L1HPSPFTauBuilder::l1PFTauSeedPhi_
double l1PFTauSeedPhi_
Definition: L1HPSPFTauBuilder.h:62
edm::Ref< TkPrimaryVertexCollection >
L1HPSPFTauBuilder::signalChargedHadrons_
std::vector< l1t::PFCandidateRef > signalChargedHadrons_
Definition: L1HPSPFTauBuilder.h:71
L1HPSPFTauBuilder::signalConeSize_
double signalConeSize_
Definition: L1HPSPFTauBuilder.h:39
BeamMonitor_cff.primaryVertex
primaryVertex
hltOfflineBeamSpot for HLTMON
Definition: BeamMonitor_cff.py:7
L1HPSPFTauBuilder::isoNeutralHadrons_
std::vector< l1t::PFCandidateRef > isoNeutralHadrons_
Definition: L1HPSPFTauBuilder.h:84
reco::FormulaEvaluator
Definition: FormulaEvaluator.h:67
L1HPSPFTauBuilder::setL1PFTauSeed
void setL1PFTauSeed(const l1t::PFCandidateRef &l1PFCandSeed)
Definition: L1HPSPFTauBuilder.cc:92
L1HPSPFTauBuilder::signalNeutralHadrons_
std::vector< l1t::PFCandidateRef > signalNeutralHadrons_
Definition: L1HPSPFTauBuilder.h:73
ProductID.h
L1HPSPFTauBuilder::stripSizeEta_
double stripSizeEta_
Definition: L1HPSPFTauBuilder.h:45
L1HPSPFTauBuilder::isJetSeeded_
bool isJetSeeded_
Definition: L1HPSPFTauBuilder.h:59
L1HPSPFTauBuilder::convertToRefVector
l1t::PFCandidateRefVector convertToRefVector(const std::vector< l1t::PFCandidateRef > &l1PFCands)
Definition: L1HPSPFTauBuilder.cc:431
L1HPSPFTauBuilder::l1PFTau_
l1t::HPSPFTau l1PFTau_
Definition: L1HPSPFTauBuilder.h:66
L1HPSPFTauBuilder::sumAllL1PFCandidates_
std::vector< l1t::PFCandidateRef > sumAllL1PFCandidates_
Definition: L1HPSPFTauBuilder.h:88
L1HPSPFTauBuilder::isoChargedHadrons_
std::vector< l1t::PFCandidateRef > isoChargedHadrons_
Definition: L1HPSPFTauBuilder.h:82
L1HPSPFTauBuilder::isWithinStrip
bool isWithinStrip(const l1t::PFCandidate &l1PFCand)
Definition: L1HPSPFTauBuilder.cc:320
L1HPSPFTauBuilder::debug_
bool debug_
Definition: L1HPSPFTauBuilder.h:97
L1HPSPFTauBuilder::reset
void reset()
Definition: L1HPSPFTauBuilder.cc:40
L1HPSPFTauBuilder::signalQualityCutsDzCutDisabled_
std::vector< L1HPSPFTauQualityCut > signalQualityCutsDzCutDisabled_
Definition: L1HPSPFTauBuilder.h:51
edm::ParameterSet
Definition: ParameterSet.h:47
L1HPSPFTauBuilder::sumElectrons_
std::vector< l1t::PFCandidateRef > sumElectrons_
Definition: L1HPSPFTauBuilder.h:90
L1HPSPFTauBuilder::stripElectrons_
std::vector< l1t::PFCandidateRef > stripElectrons_
Definition: L1HPSPFTauBuilder.h:78
L1HPSPFTauBuilder::sumPhotons_
std::vector< l1t::PFCandidateRef > sumPhotons_
Definition: L1HPSPFTauBuilder.h:92
FormulaEvaluator.h
L1HPSPFTauBuilder::isoAllL1PFCandidates_
std::vector< l1t::PFCandidateRef > isoAllL1PFCandidates_
Definition: L1HPSPFTauBuilder.h:81
l1t::HPSPFTau
Definition: HPSPFTau.h:14
L1HPSPFTauBuilder::isolationQualityCutsDzCutEnabledPileup_
std::vector< L1HPSPFTauQualityCut > isolationQualityCutsDzCutEnabledPileup_
Definition: L1HPSPFTauBuilder.h:55
L1HPSPFTauBuilder::useStrips_
bool useStrips_
Definition: L1HPSPFTauBuilder.h:44
L1HPSPFTauBuilder::isoPhotons_
std::vector< l1t::PFCandidateRef > isoPhotons_
Definition: L1HPSPFTauBuilder.h:85
L1HPSPFTauBuilder::isWithinIsolationCone
bool isWithinIsolationCone(const l1t::PFCandidate &l1PFCand)
Definition: L1HPSPFTauBuilder.cc:330
L1HPSPFTauQualityCut.h
looper.cfg
cfg
Definition: looper.py:296
L1HPSPFTauBuilder::signalElectrons_
std::vector< l1t::PFCandidateRef > signalElectrons_
Definition: L1HPSPFTauBuilder.h:72
HPSPFTau.h
L1HPSPFTauBuilder::l1JetSeed_
reco::CaloJetRef l1JetSeed_
Definition: L1HPSPFTauBuilder.h:60
L1HPSPFTauBuilder::isoElectrons_
std::vector< l1t::PFCandidateRef > isoElectrons_
Definition: L1HPSPFTauBuilder.h:83
L1HPSPFTauBuilder::signalConeSize2_
double signalConeSize2_
Definition: L1HPSPFTauBuilder.h:40
L1HPSPFTauBuilder::primaryVertex_
l1t::TkPrimaryVertexRef primaryVertex_
Definition: L1HPSPFTauBuilder.h:65
L1HPSPFTauBuilder::signalPhotons_
std::vector< l1t::PFCandidateRef > signalPhotons_
Definition: L1HPSPFTauBuilder.h:74
L1HPSPFTauBuilder
Definition: L1HPSPFTauBuilder.h:14
L1HPSPFTauBuilder::minSignalConeSize_
double minSignalConeSize_
Definition: L1HPSPFTauBuilder.h:41
L1HPSPFTauBuilder::isolationConeSize_
double isolationConeSize_
Definition: L1HPSPFTauBuilder.h:48
l1t::PFCandidate
Definition: PFCandidate.h:12
L1HPSPFTauBuilder::buildL1PFTau
void buildL1PFTau()
Definition: L1HPSPFTauBuilder.cc:339
ParameterSet.h
L1HPSPFTauBuilder::isPFCandSeeded_
bool isPFCandSeeded_
Definition: L1HPSPFTauBuilder.h:57
L1HPSPFTauBuilder::sumNeutralHadrons_
std::vector< l1t::PFCandidateRef > sumNeutralHadrons_
Definition: L1HPSPFTauBuilder.h:91
L1HPSPFTauBuilder::sumMuons_
std::vector< l1t::PFCandidateRef > sumMuons_
Definition: L1HPSPFTauBuilder.h:93
L1HPSPFTauBuilder::sumAllL1PFCandidatesPt_
double sumAllL1PFCandidatesPt_
Definition: L1HPSPFTauBuilder.h:64
L1HPSPFTauBuilder::getL1PFTau
l1t::HPSPFTau getL1PFTau() const
Definition: L1HPSPFTauBuilder.h:28
L1HPSPFTauBuilder::maxSignalConeSize_
double maxSignalConeSize_
Definition: L1HPSPFTauBuilder.h:42
L1HPSPFTauBuilder::signalMuons_
std::vector< l1t::PFCandidateRef > signalMuons_
Definition: L1HPSPFTauBuilder.h:75
edm::ProductID
Definition: ProductID.h:27
L1HPSPFTauBuilder::setL1PFCandProductID
void setL1PFCandProductID(const edm::ProductID &l1PFCandProductID)
Definition: L1HPSPFTauBuilder.cc:86
L1HPSPFTauBuilder::signalAllL1PFCandidates_
std::vector< l1t::PFCandidateRef > signalAllL1PFCandidates_
Definition: L1HPSPFTauBuilder.h:70
L1HPSPFTauBuilder::isolationConeSize2_
double isolationConeSize2_
Definition: L1HPSPFTauBuilder.h:49