15 std::vector<int>&
match,
16 const unsigned int iComb) {
27 for (
unsigned idx = 0;
idx < match.size(); ++
idx) {
59 match.push_back(iLepton);
83 for (
unsigned i = 0;
i <
leps->size(); ++
i) {
86 if (minDR < 0 || dR < minDR) {
int pdgId() const final
PDG identifier.
bool isSemiLeptonic(bool excludeTauLeptons=false) const
check if the event can be classified as semi-laptonic
double eta() const final
momentum pseudorapidity
WDecay::LeptonType leptonType(const reco::RecoCandidate *cand)
determine lepton type of reco candidate and return a corresponding WDecay::LeptonType; the type is kN...
bool isValid(const int &idx, const edm::Handle< std::vector< pat::Jet > > &jets)
check if index is in valid range of selected jets
bool getByToken(EDGetToken token, Handle< PROD > &result) const
reco::ShallowClonePtrCandidate * lepton_
const reco::GenParticle * hadronicDecayQuarkBar() const
get light anti-quark of hadronic decay branch
reco::ShallowClonePtrCandidate * lightQBar_
Class derived from the TopGenEvent for ttbar events.
reco::ShallowClonePtrCandidate * neutrino_
void buildHypo(edm::Event &, const edm::Handle< edm::View< reco::RecoCandidate > > &, const edm::Handle< std::vector< pat::MET > > &, const edm::Handle< std::vector< pat::Jet > > &, std::vector< int > &, const unsigned int iComb) override
build event hypothesis from the reco objects of a semi-leptonic event
~TtSemiLepHypGenMatch() override
Abs< T >::type abs(const T &t)
const reco::GenParticle * hadronicDecayQuark(bool invertFlavor=false) const
get light quark of hadronic decay branch
int findMatchingLepton(const edm::Handle< TtGenEvent > &genEvt, const edm::Handle< edm::View< reco::RecoCandidate > > &)
find index of the candidate nearest to the singleLepton of the generator event in the collection; ret...
reco::ShallowClonePtrCandidate * hadronicB_
TtSemiLepHypGenMatch(const edm::ParameterSet &)
void setNeutrino(const edm::Handle< std::vector< pat::MET > > &met, const edm::Handle< edm::View< reco::RecoCandidate > > &leps, const int &idx, const int &type)
set neutrino, using mW = 80.4 to calculate the neutrino pz
void setCandidate(const edm::Handle< C > &handle, const int &idx, reco::ShallowClonePtrCandidate *&clone)
use one object in a collection to set a ShallowClonePtrCandidate
std::pair< typename Association::data_type::first_type, double > match(Reference key, Association association, bool bestMatchByMaxValue)
Generic matching function.
int neutrinoSolutionType_
algorithm used to calculate neutrino solutions (see cfi for further details)
edm::EDGetTokenT< TtGenEvent > genEvtToken_
double phi() const final
momentum azimuthal angle
reco::ShallowClonePtrCandidate * lightQ_
bool isTtBar() const
check if the event can be classified as ttbar
reco::ShallowClonePtrCandidate * leptonicB_
std::string jetCorrectionLevel(const std::string &quarkType)
helper function to construct the proper correction level string for corresponding quarkType ...
const reco::GenParticle * singleLepton(bool excludeTauLeptons=false) const
return single lepton if available; 0 else