CMS 3D CMS Logo

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

#include <TriggerSummaryProducerRAW.h>

Inheritance diagram for TriggerSummaryProducerRAW:
edm::global::EDProducer<> edm::global::EDProducerBase edm::ProducerBase edm::EDConsumerBase edm::ProductRegistryHelper

Public Member Functions

void produce (edm::StreamID, edm::Event &, const edm::EventSetup &) const override
 
 TriggerSummaryProducerRAW (const edm::ParameterSet &)
 
 ~TriggerSummaryProducerRAW () override
 
- Public Member Functions inherited from edm::global::EDProducer<>
 EDProducer ()=default
 
 EDProducer (const EDProducer &)=delete
 
bool hasAbilityToProduceInBeginLumis () const final
 
bool hasAbilityToProduceInBeginProcessBlocks () const final
 
bool hasAbilityToProduceInBeginRuns () const final
 
bool hasAbilityToProduceInEndLumis () const final
 
bool hasAbilityToProduceInEndProcessBlocks () const final
 
bool hasAbilityToProduceInEndRuns () const final
 
EDProduceroperator= (const EDProducer &)=delete
 
bool wantsGlobalLuminosityBlocks () const final
 
bool wantsGlobalRuns () const final
 
bool wantsInputProcessBlocks () const final
 
bool wantsProcessBlocks () const final
 
bool wantsStreamLuminosityBlocks () const final
 
bool wantsStreamRuns () const final
 
- Public Member Functions inherited from edm::global::EDProducerBase
 EDProducerBase ()
 
ModuleDescription const & moduleDescription () const
 
 ~EDProducerBase () override
 
- Public Member Functions inherited from edm::ProducerBase
void callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func)
 
std::vector
< edm::ProductResolverIndex >
const & 
indiciesForPutProducts (BranchType iBranchType) const
 
 ProducerBase ()
 
std::vector
< edm::ProductResolverIndex >
const & 
putTokenIndexToProductResolverIndex () const
 
void registerProducts (ProducerBase *, ProductRegistry *, ModuleDescription const &)
 
std::function< void(BranchDescription
const &)> 
registrationCallback () const
 used by the fwk to register list of products More...
 
void resolvePutIndicies (BranchType iBranchType, ModuleToResolverIndicies const &iIndicies, std::string const &moduleLabel)
 
 ~ProducerBase () noexcept(false) override
 
- Public Member Functions inherited from edm::EDConsumerBase
std::vector< ConsumesInfoconsumesInfo () const
 
void convertCurrentProcessAlias (std::string const &processName)
 Convert "@currentProcess" in InputTag process names to the actual current process name. More...
 
 EDConsumerBase ()
 
 EDConsumerBase (EDConsumerBase const &)=delete
 
 EDConsumerBase (EDConsumerBase &&)=default
 
ESProxyIndex const * esGetTokenIndices (edm::Transition iTrans) const
 
std::vector< ESProxyIndex > const & esGetTokenIndicesVector (edm::Transition iTrans) const
 
std::vector< ESRecordIndex >
const & 
esGetTokenRecordIndicesVector (edm::Transition iTrans) const
 
ProductResolverIndexAndSkipBit indexFrom (EDGetToken, BranchType, TypeID const &) const
 
void itemsMayGet (BranchType, std::vector< ProductResolverIndexAndSkipBit > &) const
 
void itemsToGet (BranchType, std::vector< ProductResolverIndexAndSkipBit > &) const
 
std::vector
< ProductResolverIndexAndSkipBit >
const & 
itemsToGetFrom (BranchType iType) const
 
void labelsForToken (EDGetToken iToken, Labels &oLabels) const
 
void modulesWhoseProductsAreConsumed (std::array< std::vector< ModuleDescription const * > *, NumBranchTypes > &modulesAll, std::vector< ModuleProcessName > &modulesInPreviousProcesses, ProductRegistry const &preg, std::map< std::string, ModuleDescription const * > const &labelsToDesc, std::string const &processName) const
 
EDConsumerBase const & operator= (EDConsumerBase const &)=delete
 
EDConsumerBaseoperator= (EDConsumerBase &&)=default
 
bool registeredToConsume (ProductResolverIndex, bool, BranchType) const
 
bool registeredToConsumeMany (TypeID const &, BranchType) const
 
void selectInputProcessBlocks (ProductRegistry const &productRegistry, ProcessBlockHelperBase const &processBlockHelperBase)
 
ProductResolverIndexAndSkipBit uncheckedIndexFrom (EDGetToken) const
 
void updateLookup (BranchType iBranchType, ProductResolverIndexHelper const &, bool iPrefetchMayGet)
 
void updateLookup (eventsetup::ESRecordsToProxyIndices const &)
 
virtual ~EDConsumerBase () noexcept(false)
 

Static Public Member Functions

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

Private Attributes

edm::GetterOfProducts
< trigger::TriggerFilterObjectWithRefs
getterOfProducts_
 
std::string pn_
 process name More...
 
const edm::EDPutTokenT
< trigger::TriggerEventWithRefs
putToken_
 

Additional Inherited Members

- Public Types inherited from edm::global::EDProducerBase
typedef EDProducerBase ModuleType
 
- Public Types inherited from edm::ProducerBase
using ModuleToResolverIndicies = std::unordered_multimap< std::string, std::tuple< edm::TypeID const *, const char *, edm::ProductResolverIndex >>
 
typedef
ProductRegistryHelper::TypeLabelList 
TypeLabelList
 
- Public Types inherited from edm::EDConsumerBase
typedef ProductLabels Labels
 
- Protected Member Functions inherited from edm::ProducerBase
ProducesCollector producesCollector ()
 
- Protected Member Functions inherited from edm::EDConsumerBase
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > consumes (edm::InputTag const &tag)
 
template<BranchType B = InEvent>
EDConsumerBaseAdaptor< B > consumes (edm::InputTag tag) noexcept
 
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 ESProduct , typename ESRecord , Transition Tr = Transition::Event>
auto esConsumes ()
 
template<typename ESProduct , typename ESRecord , Transition Tr = Transition::Event>
auto esConsumes (ESInputTag const &tag)
 
template<Transition Tr = Transition::Event>
constexpr auto esConsumes () noexcept
 
template<Transition Tr = Transition::Event>
auto esConsumes (ESInputTag tag) noexcept
 
template<Transition Tr = Transition::Event>
ESGetTokenGeneric esConsumes (eventsetup::EventSetupRecordKey const &iRecord, eventsetup::DataKey const &iKey)
 Used with EventSetupRecord::doGet. More...
 
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)
 
void resetItemsToGetFrom (BranchType iType)
 

Detailed Description

This class is an EDProducer making the HLT summary object for RAW

Author
Martin Grunewald

See header file for documentation

Author
Martin Grunewald

Definition at line 34 of file TriggerSummaryProducerRAW.h.

Constructor & Destructor Documentation

TriggerSummaryProducerRAW::TriggerSummaryProducerRAW ( const edm::ParameterSet ps)
explicit

Definition at line 28 of file TriggerSummaryProducerRAW.cc.

References edm::ProducerBase::callWhenNewProductsRegistered(), edm::service::TriggerNamesService::getProcessName(), getterOfProducts_, edm::Service< T >::isAvailable(), LogDebug, pn_, edm::tns(), and ~TriggerSummaryProducerRAW().

29  : pn_(ps.getParameter<std::string>("processName")), putToken_{produces<trigger::TriggerEventWithRefs>()} {
30  if (pn_ == "@") {
32  if (tns.isAvailable()) {
33  pn_ = tns->getProcessName();
34  } else {
35  edm::LogError("TriggerSummaryProducerRaw") << "HLT Error: TriggerNamesService not available!";
36  pn_ = "*";
37  }
38  }
39 
40  LogDebug("TriggerSummaryProducerRaw") << "Using process name: '" << pn_ << "'";
41 
42  // Tell the getter what type of products to get and
43  // also the process to get them from
46 }
void callWhenNewProductsRegistered(std::function< void(BranchDescription const &)> const &func)
Definition: ProducerBase.h:85
pathNames_ & tns()), endPathNames_(&tns.getEndPaths()), wantSummary_(tns.wantSummary()
Definition: Schedule.cc:691
std::string const & getProcessName() const
const edm::EDPutTokenT< trigger::TriggerEventWithRefs > putToken_
edm::GetterOfProducts< trigger::TriggerFilterObjectWithRefs > getterOfProducts_
Log< level::Error, false > LogError
bool isAvailable() const
Definition: Service.h:40
std::string pn_
process name
T getParameter(std::string const &) const
Definition: ParameterSet.h:303
#define LogDebug(id)
TriggerSummaryProducerRAW::~TriggerSummaryProducerRAW ( )
overridedefault

Member Function Documentation

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

Definition at line 54 of file TriggerSummaryProducerRAW.cc.

References edm::ConfigurationDescriptions::add(), edm::ParameterSetDescription::add(), submitPVResolutionJobs::desc, and AlCaHLTBitMon_QueryRunRegistry::string.

54  {
56  desc.add<std::string>("processName", "@");
57  descriptions.add("triggerSummaryProducerRAW", desc);
58 }
ParameterDescriptionBase * add(U const &iLabel, T const &value)
void add(std::string const &label, ParameterSetDescription const &psetDescription)
void TriggerSummaryProducerRAW::produce ( edm::StreamID  ,
edm::Event iEvent,
const edm::EventSetup  
) const
overridevirtual

Implements edm::global::EDProducerBase.

Definition at line 61 of file TriggerSummaryProducerRAW.cc.

References trigger::TriggerEventWithRefs::addFilterObject(), edm::Event::emplace(), edm::GetterOfProducts< T >::fillHandles(), getterOfProducts_, instance, label, LogDebug, LogTrace, eostools::move(), pn_, LaserDQM_cfg::process, FSQHLTOfflineSource_cfi::processName, putToken_, dt_dqm_sourceclient_common_cff::reco, and GlobalPosition_Frontier_DevDB_cff::tag.

61  {
62  using namespace std;
63  using namespace edm;
64  using namespace reco;
65  using namespace trigger;
66 
67  std::vector<edm::Handle<trigger::TriggerFilterObjectWithRefs> > fobs;
68  getterOfProducts_.fillHandles(iEvent, fobs);
69 
70  const unsigned int nfob(fobs.size());
71  LogDebug("TriggerSummaryProducerRaw") << "Number of filter objects found: " << nfob;
72 
73  // construct single RAW product
74  TriggerEventWithRefs product(pn_, nfob);
75  for (unsigned int ifob = 0; ifob != nfob; ++ifob) {
76  const string& label(fobs[ifob].provenance()->moduleLabel());
77  const string& instance(fobs[ifob].provenance()->productInstanceName());
78  const string& process(fobs[ifob].provenance()->processName());
80  LogTrace("TriggerSummaryProducerRaw")
81  << ifob << " " << tag << endl
82  << " Sizes: "
83  << " 1/" << fobs[ifob]->photonSize() << " 2/" << fobs[ifob]->electronSize() << " 3/" << fobs[ifob]->muonSize()
84  << " 4/" << fobs[ifob]->jetSize() << " 5/" << fobs[ifob]->compositeSize() << " 6/" << fobs[ifob]->basemetSize()
85  << " 7/" << fobs[ifob]->calometSize()
86 
87  << " 8/" << fobs[ifob]->pixtrackSize() << " 9/" << fobs[ifob]->l1emSize() << " A/" << fobs[ifob]->l1muonSize()
88  << " B/" << fobs[ifob]->l1jetSize() << " C/" << fobs[ifob]->l1etmissSize() << " D/"
89  << fobs[ifob]->l1hfringsSize() << " E/" << fobs[ifob]->pfjetSize() << " F/" << fobs[ifob]->pftauSize() << " G/"
90  << fobs[ifob]->pfmetSize() << " I/" << fobs[ifob]->l1tmuonSize() << " J/" << fobs[ifob]->l1tegammaSize()
91  << " K/" << fobs[ifob]->l1tjetSize() << " L/" << fobs[ifob]->l1ttauSize() << " M/" << fobs[ifob]->l1tetsumSize()
92  << " N/" << fobs[ifob]->l1ttkmuonSize() << " O/" << fobs[ifob]->l1ttkeleSize() << " P/"
93  << fobs[ifob]->l1ttkemSize() << " Q/" << fobs[ifob]->l1tpfjetSize() << " R/" << fobs[ifob]->l1tpftauSize()
94  << " S/" << fobs[ifob]->l1thpspftauSize() << " T/" << fobs[ifob]->l1tpftrackSize() << endl;
95  LogTrace("TriggerSummaryProducerRaw")
96  << "TriggerSummaryProducerRaw::addFilterObjects( )"
97  << "\n fobs[ifob]->l1tmuonIds().size() = " << fobs[ifob]->l1tmuonIds().size()
98  << "\n fobs[ifob]->l1tmuonRefs().size() = " << fobs[ifob]->l1tmuonRefs().size() << endl;
99  LogTrace("TriggerSummaryProducerRaw")
100  << "TriggerSummaryProducerRaw::addFilterObjects( )"
101  << "\n fobs[ifob]->l1tegammaIds().size() = " << fobs[ifob]->l1tegammaIds().size()
102  << "\n fobs[ifob]->l1tegammaRefs().size() = " << fobs[ifob]->l1tegammaRefs().size() << endl;
103  LogTrace("TriggerSummaryProducerRaw")
104  << "TriggerSummaryProducerRaw::addFilterObjects( )"
105  << "\n fobs[ifob]->l1tjetIds().size() = " << fobs[ifob]->l1tjetIds().size()
106  << "\n fobs[ifob]->l1tjetRefs().size() = " << fobs[ifob]->l1tjetRefs().size() << endl;
107  LogTrace("TriggerSummaryProducerRaw")
108  << "TriggerSummaryProducerRaw::addFilterObjects( )"
109  << "\n fobs[ifob]->l1ttauIds().size() = " << fobs[ifob]->l1ttauIds().size()
110  << "\n fobs[ifob]->l1ttauRefs().size() = " << fobs[ifob]->l1ttauRefs().size() << endl;
111  LogTrace("TriggerSummaryProducerRaw")
112  << "TriggerSummaryProducerRaw::addFilterObjects( )"
113  << "\n fobs[ifob]->l1tetsumIds().size() = " << fobs[ifob]->l1tetsumIds().size()
114  << "\n fobs[ifob]->l1tetsumRefs().size() = " << fobs[ifob]->l1tetsumRefs().size() << endl;
115  product.addFilterObject(tag, *fobs[ifob]);
116  }
117 
118  // place product in Event
120  LogTrace("TriggerSummaryProducerRaw") << "Number of filter objects packed: " << ref->size();
121 
122  return;
123 }
static PFTauRenderPlugin instance
const edm::EDPutTokenT< trigger::TriggerEventWithRefs > putToken_
edm::GetterOfProducts< trigger::TriggerFilterObjectWithRefs > getterOfProducts_
void fillHandles(edm::Event const &event, std::vector< edm::Handle< T >> &handles) const
#define LogTrace(id)
char const * label
def move
Definition: eostools.py:511
std::string pn_
process name
OrphanHandle< PROD > emplace(EDPutTokenT< PROD > token, Args &&...args)
puts a new product
Definition: Event.h:433
tuple process
Definition: LaserDQM_cfg.py:3
#define LogDebug(id)

Member Data Documentation

edm::GetterOfProducts<trigger::TriggerFilterObjectWithRefs> TriggerSummaryProducerRAW::getterOfProducts_
private

Definition at line 45 of file TriggerSummaryProducerRAW.h.

Referenced by produce(), and TriggerSummaryProducerRAW().

std::string TriggerSummaryProducerRAW::pn_
private

process name

Definition at line 43 of file TriggerSummaryProducerRAW.h.

Referenced by produce(), and TriggerSummaryProducerRAW().

const edm::EDPutTokenT<trigger::TriggerEventWithRefs> TriggerSummaryProducerRAW::putToken_
private

Definition at line 46 of file TriggerSummaryProducerRAW.h.

Referenced by produce().