CMS 3D CMS Logo

FlavorHistoryProducer.h
Go to the documentation of this file.
1 #ifndef PhysicsTools_HepMCCandAlgos_interface_FlavorHistoryProducer_h
2 #define PhysicsTools_HepMCCandAlgos_interface_FlavorHistoryProducer_h
3 
12 // -------------------------------------------------------------
13 // Identify the ancestry of the Quark
14 //
15 //
16 // Matrix Element:
17 // Status 3 parent with precisely 2 "grandparents" that
18 // is outside of the "initial" section (0-5) that has the
19 // same ID as the status 2 parton in question.
20 //
21 // Flavor excitation:
22 // Almost the same as the matrix element classification,
23 // but has only one outgoing parton product instead of two.
24 //
25 // Gluon splitting:
26 // Parent is a quark of a different flavor than the parton
27 // in question, or a gluon. Can come from either ISR or FSR.
28 //
29 // True decay:
30 // Decays from a resonance like top, Higgs, etc.
31 // -------------------------------------------------------------
32 
34 #include <string>
35 #include <vector>
36 #include <set>
37 #include <utility>
38 #include <algorithm>
39 
53 #include <fstream>
54 
56 public:
60  ~FlavorHistoryProducer() override;
61 
62 private:
64  void produce(edm::Event &e, const edm::EventSetup &) override;
65 
66  void getAncestors(const reco::Candidate &c, std::vector<reco::Candidate const *> &moms);
67 
69 
71  reco::Candidate const &parton) const;
72 
73  edm::EDGetTokenT<reco::CandidateView> srcToken_; // GenParticles source collection name
74  edm::EDGetTokenT<reco::CandidateView> matchedSrcToken_; // matched particles source collection name
75  double matchDR_; // delta r to match matched particles
76  int pdgIdToSelect_; // pdg of hf partons to select
77  double ptMinParticle_; // minimum pt of the partons
78  double ptMinShower_; // minimum pt of the shower
79  double etaMaxParticle_; // max eta of the parton
80  double etaMaxShower_; // max eta of the shower
81  std::string flavorHistoryName_; // name to give flavor history
82  bool verbose_; // verbose flag
83 };
84 
85 #endif
FlavorHistory.h
FlavorHistoryProducer::~FlavorHistoryProducer
~FlavorHistoryProducer() override
destructor
Definition: FlavorHistoryProducer.cc:51
Handle.h
MessageLogger.h
EDProducer.h
ESHandle.h
FlavorHistoryProducer::etaMaxShower_
double etaMaxShower_
Definition: FlavorHistoryProducer.h:80
edm::EDGetTokenT
Definition: EDGetToken.h:33
edm::Handle
Definition: AssociativeIterator.h:50
GenParticle.h
CandidateFwd.h
EDMException.h
FlavorHistoryProducer::getSister
const reco::Candidate * getSister(const reco::Candidate &c)
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
FlavorHistoryProducer::produce
void produce(edm::Event &e, const edm::EventSetup &) override
process one event
Definition: FlavorHistoryProducer.cc:53
edm::ParameterSet
Definition: ParameterSet.h:47
FlavorHistoryProducer::pdgIdToSelect_
int pdgIdToSelect_
Definition: FlavorHistoryProducer.h:76
Event.h
Ptr.h
ShallowClonePtrCandidate.h
FlavorHistoryProducer::getAncestors
void getAncestors(const reco::Candidate &c, std::vector< reco::Candidate const * > &moms)
Definition: FlavorHistoryProducer.cc:341
edm::EventSetup
Definition: EventSetup.h:58
FlavorHistoryProducer::matchDR_
double matchDR_
Definition: FlavorHistoryProducer.h:75
FlavorHistoryProducer::etaMaxParticle_
double etaMaxParticle_
Definition: FlavorHistoryProducer.h:79
reco::Candidate
Definition: Candidate.h:27
FlavorHistoryProducer::ptMinParticle_
double ptMinParticle_
Definition: FlavorHistoryProducer.h:77
FlavorHistoryProducer::matchedSrcToken_
edm::EDGetTokenT< reco::CandidateView > matchedSrcToken_
Definition: FlavorHistoryProducer.h:74
FlavorHistoryProducer
Definition: FlavorHistoryProducer.h:55
FlavorHistoryProducer::FlavorHistoryProducer
FlavorHistoryProducer(const edm::ParameterSet &)
constructor
Definition: FlavorHistoryProducer.cc:37
EventSetup.h
edm::EDProducer
Definition: EDProducer.h:35
FlavorHistoryProducer::ptMinShower_
double ptMinShower_
Definition: FlavorHistoryProducer.h:78
edm::View::const_iterator
boost::indirect_iterator< typename seq_t::const_iterator > const_iterator
Definition: View.h:86
ParameterSet.h
c
auto & c
Definition: CAHitNtupletGeneratorKernelsImpl.h:46
FlavorHistoryProducer::flavorHistoryName_
std::string flavorHistoryName_
Definition: FlavorHistoryProducer.h:81
edm::Event
Definition: Event.h:73
FlavorHistoryProducer::verbose_
bool verbose_
Definition: FlavorHistoryProducer.h:82
MillePedeFileConverter_cfg.e
e
Definition: MillePedeFileConverter_cfg.py:37
FlavorHistoryProducer::getClosestJet
reco::CandidateView::const_iterator getClosestJet(edm::Handle< reco::CandidateView > const &pJets, reco::Candidate const &parton) const
Definition: FlavorHistoryProducer.cc:353
FlavorHistoryEvent.h
FlavorHistoryProducer::srcToken_
edm::EDGetTokenT< reco::CandidateView > srcToken_
Definition: FlavorHistoryProducer.h:73