CP3-llbb Framework
Public Member Functions | Public Attributes | List of all members
FatJetsProducer Class Reference
Inheritance diagram for FatJetsProducer:
Inheritance graph
[legend]
Collaboration diagram for FatJetsProducer:
Collaboration graph
[legend]

Public Member Functions

 FatJetsProducer (const std::string &name, const ROOT::TreeGroup &tree, const edm::ParameterSet &config)
 
virtual void doConsumes (const edm::ParameterSet &config, edm::ConsumesCollector &&collector) override
 Hook for the CMSSW consumes interface. More...
 
virtual void produce (edm::Event &event, const edm::EventSetup &eventSetup) override
 Main method of the producer, called for each event. More...
 
float getBTagDiscriminant (size_t index, const std::string &name) const
 
float getSoftDropBTagDiscriminant (size_t index, size_t sj_index, const std::string &btag_name) const
 
float getSoftDropPuppiBTagDiscriminant (size_t index, size_t sj_index, const std::string &btag_name) const
 
float get_scale_factor (Algorithm algo, const std::string &wp, size_t index, Variation variation=Variation::Nominal)
 
 BRANCH (passLooseID, std::vector< bool >)
 
 BRANCH (passTightID, std::vector< bool >)
 
 BRANCH (passTightLeptonVetoID, std::vector< bool >)
 
 BRANCH (tau1, std::vector< float >)
 
 BRANCH (tau2, std::vector< float >)
 
 BRANCH (tau3, std::vector< float >)
 
 BRANCH (puppi_p4, std::vector< LorentzVector >)
 
 BRANCH (puppi_tau1, std::vector< float >)
 
 BRANCH (puppi_tau2, std::vector< float >)
 
 BRANCH (puppi_tau3, std::vector< float >)
 
 BRANCH (softdrop_mass, std::vector< float >)
 
 BRANCH (pruned_mass, std::vector< float >)
 
 BRANCH (softdrop_subjets_p4, std::vector< std::vector< LorentzVector >>)
 
 BRANCH (softdrop_puppi_subjets_p4, std::vector< std::vector< LorentzVector >>)
 
- Public Member Functions inherited from CandidatesProducer< pat::Jet >
 CandidatesProducer (const std::string &name, const ROOT::TreeGroup &tree, const edm::ParameterSet &config)
 
- Public Member Functions inherited from Framework::Producer
 Producer (const std::string &name, const ROOT::TreeGroup &tree_, const edm::ParameterSet &config)
 Base constructor. More...
 
virtual void beginJob (MetadataManager &manager)
 Called once at the beginning of the job. More...
 
virtual void endJob (MetadataManager &manager)
 Called once at the end of the job. More...
 
virtual void beginRun (const edm::Run &run, const edm::EventSetup &setup)
 Called at the beginning of a new run. More...
 
virtual void endRun (const edm::Run &run, const edm::EventSetup &setup)
 Called at the end of a run. More...
 
virtual void beginLuminosityBlock (const edm::LuminosityBlock &lumi, const edm::EventSetup &setup)
 Called at the beginning of a new luminosity section. More...
 
virtual void endLuminosityBlock (const edm::LuminosityBlock &lumi, const edm::EventSetup &setup)
 Called at the end of a luminosity section. More...
 
 Producer (const Producer &)=delete
 
Produceroperator= (const Producer &)=delete
 
- Public Member Functions inherited from BTaggingScaleFactors
 BTaggingScaleFactors (ROOT::TreeGroup &tree)
 
virtual void create_branches (const edm::ParameterSet &) final
 
virtual void store_scale_factors (Algorithm algo, Flavor flavor, const Parameters &, bool isData) final
 
virtual bool has_scale_factors (Algorithm algo) final
 

Public Attributes

std::vector< float > & area = tree["area"].write<std::vector<float>>()
 
std::vector< int8_t > & partonFlavor = tree["partonFlavor"].write<std::vector<int8_t>>()
 
std::vector< int8_t > & hadronFlavor = tree["hadronFlavor"].write<std::vector<int8_t>>()
 
std::vector< int8_t > & systFlavor = tree["systFlavor"].write<std::vector<int8_t>>()
 
std::vector< float > & jecFactor = tree["jecFactor"].write<std::vector<float>>()
 
- Public Attributes inherited from CandidatesProducer< pat::Jet >
std::vector< LorentzVector > & p4
 
std::vector< float > & y
 
std::vector< int8_t > & charge
 
std::vector< bool > & matched
 
std::vector< LorentzVector > & gen_p4
 
std::vector< float > & gen_y
 
std::vector< int8_t > & gen_charge
 

Additional Inherited Members

- Public Types inherited from BTaggingScaleFactors
typedef std::tuple< Algorithm, SystFlavor, std::string > branch_key_type
 
typedef std::tuple< Algorithm, Flavor, std::string > sf_key_type
 
- Static Public Member Functions inherited from BTaggingScaleFactors
static std::string algorithm_to_string (Algorithm algo)
 
static Algorithm string_to_algorithm (const std::string &algo)
 
static std::string flavor_to_string (Flavor flavor)
 
static SystFlavor flavor_to_syst_flavor (Flavor flavor)
 
static std::string syst_flavor_to_string (SystFlavor flavor)
 
static Flavor string_to_flavor (const std::string &flavor)
 
static Flavor get_flavor (int hadron_flavor)
 
- Static Public Attributes inherited from BTaggingScaleFactors
static std::array< SystFlavor, 2 > SystFlavors = {{SystFlavor::HEAVY, SystFlavor::LIGHT}}
 
- Protected Member Functions inherited from CandidatesProducer< pat::Jet >
void fill_candidate (const T &p, const U *gen)
 
bool pass_cut (const pat::Jet &p)
 
- Protected Member Functions inherited from Framework::Producer
bool doingSystematics () const
 
- Protected Member Functions inherited from BTaggingScaleFactors
virtual float get_scale_factor (Algorithm algo, Flavor flavor, const std::string &wp, size_t index, Variation variation=Variation::Nominal) final
 
- Protected Attributes inherited from Framework::Producer
std::string m_name
 
ROOT::TreeGroup tree
 Access point to output tree. More...
 

Member Function Documentation

◆ doConsumes()

virtual void FatJetsProducer::doConsumes ( const edm::ParameterSet &  pset,
edm::ConsumesCollector &&  collector 
)
inlineoverridevirtual

Hook for the CMSSW consumes interface.

Override this method to register your tokens into the CMSSW framework via the collector interface

Parameters
psetA link to the python configuration
collectorThe consumes collector. Use it to register your tokens.
See also
https://twiki.cern.ch/twiki/bin/view/CMSPublic/SWGuideEDMGetDataFromEvent

Reimplemented from Framework::Producer.

◆ produce()

void FatJetsProducer::produce ( edm::Event &  event,
const edm::EventSetup &  setup 
)
overridevirtual

Main method of the producer, called for each event.

You have direct access to the event via the CMSSW interface with the event and setup parameters.

Parameters
eventThe CMSSW event
setupThe CMSSW event setup
See also
https://twiki.cern.ch/twiki/bin/view/CMSPublic/WorkBookCMSSWFramework#EdM
CMSSW reference manual: https://cmssdt.cern.ch/SDT/doxygen/

Implements Framework::Producer.


The documentation for this class was generated from the following files: