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

Public Member Functions

 GenParticlesProducer (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...
 
- 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 Attributes

std::vector< LorentzVector > & packed_p4 = tree_packed["p4"].transient_write<std::vector<LorentzVector>>()
 
std::vector< float > & packed_y = tree_packed["y"].transient_write<std::vector<float>>()
 
std::vector< int16_t > & packed_pdg_id = tree_packed["pdg_id"].transient_write<std::vector<int16_t>>()
 
std::vector< int8_t > & packed_status = tree_packed["status"].transient_write<std::vector<int8_t>>()
 
std::vector< int16_t > & packed_status_flags = tree_packed["status_flags"].transient_write<std::vector<int16_t>>()
 
std::vector< std::vector< uint16_t > > & packed_mothers_index = tree_packed["mothers_index"].transient_write<std::vector<std::vector<uint16_t>>>()
 
std::vector< LorentzVector > & pruned_p4 = tree_pruned["p4"].transient_write<std::vector<LorentzVector>>()
 
std::vector< float > & pruned_y = tree_pruned["y"].transient_write<std::vector<float>>()
 
std::vector< int16_t > & pruned_pdg_id = tree_pruned["pdg_id"].transient_write<std::vector<int16_t>>()
 
std::vector< int8_t > & pruned_status = tree_pruned["status"].transient_write<std::vector<int8_t>>()
 
std::vector< int16_t > & pruned_status_flags = tree_pruned["status_flags"].transient_write<std::vector<int16_t>>()
 
std::vector< std::vector< uint16_t > > & pruned_mothers_index = tree_pruned["mothers_index"].transient_write<std::vector<std::vector<uint16_t>>>()
 

Additional Inherited Members

- Protected Member Functions inherited from Framework::Producer
bool doingSystematics () const
 
- 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 GenParticlesProducer::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 GenParticlesProducer::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: