CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes
GenTtbarCategorizer Class Reference

#include <TopQuarkAnalysis/TopTools/plugins/GenTtbarCategorizer.cc>

Inheritance diagram for GenTtbarCategorizer:
edm::EDProducer edm::ProducerBase edm::EDConsumerBase edm::ProductRegistryHelper

Public Member Functions

 GenTtbarCategorizer (const edm::ParameterSet &)
 
 ~GenTtbarCategorizer ()
 
- Public Member Functions inherited from edm::EDProducer
 EDProducer ()
 
ModuleDescription const & moduleDescription () const
 
virtual ~EDProducer ()
 
- Public Member Functions inherited from edm::ProducerBase
void callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func)
 
 ProducerBase ()
 
void registerProducts (ProducerBase *, ProductRegistry *, ModuleDescription const &)
 
std::function< void(BranchDescription
const &)> 
registrationCallback () const
 used by the fwk to register list of products More...
 
virtual ~ProducerBase ()
 
- Public Member Functions inherited from edm::EDConsumerBase
std::vector< ConsumesInfoconsumesInfo () const
 
 EDConsumerBase ()
 
ProductHolderIndexAndSkipBit indexFrom (EDGetToken, BranchType, TypeID const &) const
 
void itemsMayGet (BranchType, std::vector< ProductHolderIndexAndSkipBit > &) const
 
void itemsToGet (BranchType, std::vector< ProductHolderIndexAndSkipBit > &) const
 
std::vector
< ProductHolderIndexAndSkipBit >
const & 
itemsToGetFromEvent () const
 
void labelsForToken (EDGetToken iToken, Labels &oLabels) const
 
void modulesDependentUpon (std::string const &iProcessName, std::string const &iModuleLabel, bool iPrint, std::vector< char const * > &oModuleLabels) const
 
void modulesWhoseProductsAreConsumed (std::vector< ModuleDescription const * > &modules, ProductRegistry const &preg, std::map< std::string, ModuleDescription const * > const &labelsToDesc, std::string const &processName) const
 
bool registeredToConsume (ProductHolderIndex, bool, BranchType) const
 
bool registeredToConsumeMany (TypeID const &, BranchType) const
 
void updateLookup (BranchType iBranchType, ProductHolderIndexHelper const &)
 
virtual ~EDConsumerBase ()
 

Static Public Member Functions

static void fillDescriptions (edm::ConfigurationDescriptions &descriptions)
 
- Static Public Member Functions inherited from edm::EDProducer
static const std::string & baseType ()
 
static void fillDescriptions (ConfigurationDescriptions &descriptions)
 
static void prevalidate (ConfigurationDescriptions &descriptions)
 

Private Member Functions

virtual void beginJob () override
 
virtual void endJob () override
 
std::vector< int > nHadronsOrderedJetIndices (const std::map< int, int > &m_jetIndex)
 
virtual void produce (edm::Event &, const edm::EventSetup &) override
 

Private Attributes

const edm::EDGetTokenT
< std::vector< int > > 
genBHadFlavourToken_
 
const edm::EDGetTokenT
< std::vector< int > > 
genBHadFromTopWeakDecayToken_
 
const edm::EDGetTokenT
< std::vector< int > > 
genBHadIndexToken_
 
const edm::EDGetTokenT
< std::vector< int > > 
genBHadJetIndexToken_
 
const edm::EDGetTokenT
< std::vector< int > > 
genBHadLeptonHadronIndexToken_
 
const edm::EDGetTokenT
< std::vector< int > > 
genBHadLeptonViaTauToken_
 
const edm::EDGetTokenT
< std::vector< std::vector
< int > > > 
genBHadPlusMothersIndicesToken_
 
const edm::EDGetTokenT
< std::vector
< reco::GenParticle > > 
genBHadPlusMothersToken_
 
const edm::EDGetTokenT
< std::vector< int > > 
genCHadBHadronIdToken_
 
const edm::EDGetTokenT
< std::vector< int > > 
genCHadFlavourToken_
 
const edm::EDGetTokenT
< std::vector< int > > 
genCHadFromTopWeakDecayToken_
 
const edm::EDGetTokenT
< std::vector< int > > 
genCHadJetIndexToken_
 
const double genJetAbsEtaMax_
 
const double genJetPtMin_
 
const edm::EDGetTokenT
< reco::GenJetCollection
genJetsToken_
 

Additional Inherited Members

- Public Types inherited from edm::EDProducer
typedef EDProducer ModuleType
 
- Public Types inherited from edm::ProducerBase
typedef
ProductRegistryHelper::TypeLabelList 
TypeLabelList
 
- Public Types inherited from edm::EDConsumerBase
typedef ProductLabels Labels
 
- Protected Member Functions inherited from edm::EDConsumerBase
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > consumes (edm::InputTag const &tag)
 
EDGetToken consumes (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken consumes (TypeToGet const &id, edm::InputTag const &tag)
 
ConsumesCollector consumesCollector ()
 Use a ConsumesCollector to gather consumes information from helper functions. More...
 
template<typename ProductType , BranchType B = InEvent>
void consumesMany ()
 
void consumesMany (const TypeToGet &id)
 
template<BranchType B>
void consumesMany (const TypeToGet &id)
 
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > mayConsume (edm::InputTag const &tag)
 
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 

Detailed Description

Description: Categorization of different tt+xx processes, returning unique ID for each process as e.g. tt+bb, tt+b, tt+2b, tt+cc, ...

Implementation:

The classification scheme returns an ID per event, and works as follows:

All jets in the following need to be in the acceptance as given by the config parameters |eta|, pt.
A c jet must contain at least one c hadron and should contain no b hadrons

First, b jets from top are identified, i.e. jets containing a b hadron from t->b decay
They are encoded in the ID as numberOfBjetsFromTop*100, i.e.
0xx: no b jets from top in acceptance
1xx: 1 b jet from top in acceptance
2xx: both b jets from top in acceptance

Then, b jets from W are identified, i.e. jets containing a b hadron from W->b decay
They are encoded in the ID as numberOfBjetsFromW*1000, i.e.
0xxx: no b jets from W in acceptance
1xxx: 1 b jet from W in acceptance
2xxx: 2 b jets from W in acceptance

Then, c jets from W are identified, i.e. jets containing a c hadron from W->c decay, but no b hadrons
They are encoded in the ID as numberOfCjetsFromW*10000, i.e.
0xxxx: no c jets from W in acceptance
1xxxx: 1 c jet from W in acceptance
2xxxx: 2 c jets from W in acceptance

From the remaining jets, the ID is formed based on the additional b jets (IDs x5x) and c jets (IDs x4x) in the following order:
x55: at least 2 additional b jets with at least two of them having >= 2 b hadrons in each
x54: at least 2 additional b jets with one of them having >= 2 b hadrons, the others having =1 b hadron
x53: at least 2 additional b jets with all having =1 b hadron
x52: exactly 1 additional b jet having >=2 b hadrons
x51: exactly 1 additional b jet having =1 b hadron
x45: at least 2 additional c jets with at least two of them having >= 2 c hadrons in each
x44: at least 2 additional c jets with one of them having >= 2 c hadrons, the others having =1 c hadron
x43: at least 2 additional c jets with all having =1 c hadron
x42: exactly 1 additional c jet having >=2 c hadrons
x41: exactly 1 additional c jet having =1 c hadron
x00: No additional b or c jet, i.e. only light flavour jets or no additional jets

Definition at line 75 of file GenTtbarCategorizer.cc.

Constructor & Destructor Documentation

GenTtbarCategorizer::GenTtbarCategorizer ( const edm::ParameterSet iConfig)
explicit

Definition at line 132 of file GenTtbarCategorizer.cc.

GenTtbarCategorizer::~GenTtbarCategorizer ( )

Definition at line 153 of file GenTtbarCategorizer.cc.

Member Function Documentation

void GenTtbarCategorizer::beginJob ( void  )
overrideprivatevirtual

Reimplemented from edm::EDProducer.

Definition at line 363 of file GenTtbarCategorizer.cc.

void GenTtbarCategorizer::endJob ( void  )
overrideprivatevirtual

Reimplemented from edm::EDProducer.

Definition at line 368 of file GenTtbarCategorizer.cc.

void GenTtbarCategorizer::fillDescriptions ( edm::ConfigurationDescriptions descriptions)
static

Definition at line 428 of file GenTtbarCategorizer.cc.

std::vector< int > GenTtbarCategorizer::nHadronsOrderedJetIndices ( const std::map< int, int > &  m_jetIndex)
private

Definition at line 404 of file GenTtbarCategorizer.cc.

void GenTtbarCategorizer::produce ( edm::Event iEvent,
const edm::EventSetup iSetup 
)
overrideprivatevirtual

Implements edm::EDProducer.

Definition at line 163 of file GenTtbarCategorizer.cc.

Member Data Documentation

const edm::EDGetTokenT<std::vector<int> > GenTtbarCategorizer::genBHadFlavourToken_
private

Definition at line 104 of file GenTtbarCategorizer.cc.

const edm::EDGetTokenT<std::vector<int> > GenTtbarCategorizer::genBHadFromTopWeakDecayToken_
private

Definition at line 105 of file GenTtbarCategorizer.cc.

const edm::EDGetTokenT<std::vector<int> > GenTtbarCategorizer::genBHadIndexToken_
private

Definition at line 108 of file GenTtbarCategorizer.cc.

const edm::EDGetTokenT<std::vector<int> > GenTtbarCategorizer::genBHadJetIndexToken_
private

Definition at line 103 of file GenTtbarCategorizer.cc.

const edm::EDGetTokenT<std::vector<int> > GenTtbarCategorizer::genBHadLeptonHadronIndexToken_
private

Definition at line 109 of file GenTtbarCategorizer.cc.

const edm::EDGetTokenT<std::vector<int> > GenTtbarCategorizer::genBHadLeptonViaTauToken_
private

Definition at line 110 of file GenTtbarCategorizer.cc.

const edm::EDGetTokenT<std::vector<std::vector<int> > > GenTtbarCategorizer::genBHadPlusMothersIndicesToken_
private

Definition at line 107 of file GenTtbarCategorizer.cc.

const edm::EDGetTokenT<std::vector<reco::GenParticle> > GenTtbarCategorizer::genBHadPlusMothersToken_
private

Definition at line 106 of file GenTtbarCategorizer.cc.

const edm::EDGetTokenT<std::vector<int> > GenTtbarCategorizer::genCHadBHadronIdToken_
private

Definition at line 115 of file GenTtbarCategorizer.cc.

const edm::EDGetTokenT<std::vector<int> > GenTtbarCategorizer::genCHadFlavourToken_
private

Definition at line 113 of file GenTtbarCategorizer.cc.

const edm::EDGetTokenT<std::vector<int> > GenTtbarCategorizer::genCHadFromTopWeakDecayToken_
private

Definition at line 114 of file GenTtbarCategorizer.cc.

const edm::EDGetTokenT<std::vector<int> > GenTtbarCategorizer::genCHadJetIndexToken_
private

Definition at line 112 of file GenTtbarCategorizer.cc.

const double GenTtbarCategorizer::genJetAbsEtaMax_
private

Definition at line 98 of file GenTtbarCategorizer.cc.

const double GenTtbarCategorizer::genJetPtMin_
private

Definition at line 97 of file GenTtbarCategorizer.cc.

const edm::EDGetTokenT<reco::GenJetCollection> GenTtbarCategorizer::genJetsToken_
private

Definition at line 101 of file GenTtbarCategorizer.cc.