CMS 3D CMS Logo

List of all members | Public Member Functions
edmtest::L1TriggerScalerESAnalyzer Class Reference
Inheritance diagram for edmtest::L1TriggerScalerESAnalyzer:
edm::EDAnalyzer edm::EDConsumerBase

Public Member Functions

virtual void analyze (const edm::Event &e, const edm::EventSetup &c)
 
virtual void beginJob ()
 
virtual void beginRun (const edm::Run &, const edm::EventSetup &context)
 
 L1TriggerScalerESAnalyzer (edm::ParameterSet const &p)
 
 L1TriggerScalerESAnalyzer (int i)
 
virtual ~L1TriggerScalerESAnalyzer ()
 
- Public Member Functions inherited from edm::EDAnalyzer
void callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func)
 
 EDAnalyzer ()
 
SerialTaskQueueglobalLuminosityBlocksQueue ()
 
SerialTaskQueueglobalRunsQueue ()
 
ModuleDescription const & moduleDescription () const
 
std::string workerType () const
 
 ~EDAnalyzer () 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)
 

Additional Inherited Members

- Public Types inherited from edm::EDAnalyzer
typedef EDAnalyzer ModuleType
 
- Public Types inherited from edm::EDConsumerBase
typedef ProductLabels Labels
 
- Static Public Member Functions inherited from edm::EDAnalyzer
static const std::string & baseType ()
 
static void fillDescriptions (ConfigurationDescriptions &descriptions)
 
static void prevalidate (ConfigurationDescriptions &)
 
static bool wantsGlobalLuminosityBlocks ()
 
static bool wantsGlobalRuns ()
 
static bool wantsInputProcessBlocks ()
 
static bool wantsProcessBlocks ()
 
static bool wantsStreamLuminosityBlocks ()
 
static bool wantsStreamRuns ()
 
- 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< Bconsumes (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 ()
 
template<Transition Tr = Transition::Event>
auto esConsumes (ESInputTag tag)
 
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

Definition at line 24 of file L1TriggerScalerESAnalyzer.cc.

Constructor & Destructor Documentation

◆ L1TriggerScalerESAnalyzer() [1/2]

edmtest::L1TriggerScalerESAnalyzer::L1TriggerScalerESAnalyzer ( edm::ParameterSet const &  p)
inlineexplicit

Definition at line 27 of file L1TriggerScalerESAnalyzer.cc.

References gather_cfg::cout.

28  {
29  std::cout<<"L1TriggerScalerESAnalyzer"<<std::endl;
30  }

◆ L1TriggerScalerESAnalyzer() [2/2]

edmtest::L1TriggerScalerESAnalyzer::L1TriggerScalerESAnalyzer ( int  i)
inlineexplicit

Definition at line 31 of file L1TriggerScalerESAnalyzer.cc.

References gather_cfg::cout, and mps_fire::i.

32  { std::cout<<"L1TriggerScalerESAnalyzer "<<i<<std::endl; }

◆ ~L1TriggerScalerESAnalyzer()

virtual edmtest::L1TriggerScalerESAnalyzer::~L1TriggerScalerESAnalyzer ( )
inlinevirtual

Definition at line 33 of file L1TriggerScalerESAnalyzer.cc.

References gather_cfg::cout.

33  {
34  std::cout<<"~L1TriggerScalerESAnalyzer "<<std::endl;
35  }

Member Function Documentation

◆ analyze()

void edmtest::L1TriggerScalerESAnalyzer::analyze ( const edm::Event e,
const edm::EventSetup c 
)
virtual

Implements edm::EDAnalyzer.

Definition at line 60 of file L1TriggerScalerESAnalyzer.cc.

References visDQMUpload::context, gather_cfg::cout, MillePedeFileConverter_cfg::e, edm::eventsetup::heterocontainer::HCTypeTag::findType(), L1TriggerScaler::printFormat(), L1TriggerScaler::printGTAlgoCounts(), L1TriggerScaler::printGTAlgoPrescaling(), L1TriggerScaler::printGTAlgoRates(), L1TriggerScaler::printGTPartition0DeadTime(), L1TriggerScaler::printGTPartition0DeadTimeRatio(), L1TriggerScaler::printGTPartition0TriggerCounts(), L1TriggerScaler::printGTPartition0TriggerRates(), L1TriggerScaler::printGTTechCounts(), L1TriggerScaler::printGTTechPrescaling(), L1TriggerScaler::printGTTechRates(), L1TriggerScaler::printLumiSegmentValues(), L1TriggerScaler::printRunValue(), edm::ESHandle< T >::product(), and edm::eventsetup::EventSetupRecordKey::type().

60  {
61  using namespace edm::eventsetup;
62  std::cout<<"###L1TriggerScalerESAnalyzer::analyze"<<std::endl;
63 
64  // Context is not used.
65  std::cout <<" I AM IN RUN NUMBER "<<e.id().run() <<std::endl;
66  std::cout <<" ---EVENT NUMBER "<<e.id().event() <<std::endl;
68  if( recordKey.type() == edm::eventsetup::EventSetupRecordKey::TypeTag()) {
69  //record not found
70  std::cout <<"Record \"L1TriggerScalerRcd"<<"\" does not exist "<<std::endl;
71  }
73  std::cout<<"got eshandle"<<std::endl;
74  context.get<L1TriggerScalerRcd>().get(l1tr);
75  std::cout<<"got context"<<std::endl;
76  const L1TriggerScaler* l1lumiscaler=l1tr.product();
77  std::cout<<"got L1TriggerScaler* "<< std::endl;
78 
79  /* let's user the printValues method
80  std::cout<< "print result" << std::endl;
81  l1lumiscaler->printAllValues();
82  std::cout<< "print finished" << std::endl;
83  */
84 std::cout<< "print result" << std::endl;
85  l1lumiscaler->printRunValue();
86  l1lumiscaler->printLumiSegmentValues();
87  l1lumiscaler->printFormat();
88  l1lumiscaler->printGTAlgoCounts();
89  l1lumiscaler->printGTAlgoRates();
90  l1lumiscaler->printGTAlgoPrescaling();
91  l1lumiscaler->printGTTechCounts();
92  l1lumiscaler->printGTTechRates();
93  l1lumiscaler->printGTTechPrescaling();
94  l1lumiscaler->printGTPartition0TriggerCounts();
95  l1lumiscaler->printGTPartition0TriggerRates();
96  l1lumiscaler->printGTPartition0DeadTime();
97  l1lumiscaler->printGTPartition0DeadTimeRatio();
98  std::cout<< "print finished" << std::endl;
99 
100 
101 
102  /*
103  for(std::vector<L1TriggerScaler::Lumi>::const_iterator it=l1lumiscaler->m_run.begin(); it!=l1lumiscaler->m_run.end(); ++it){
104  std::cout << " run: " <<it->m_rn<<
105  "\nlumisegment: " << it->m_lumisegment<<std::endl;
106 
107 
108 
109  for(size_t i=0; i<it->m_GTAlgoRates.size(); i++ ){
110  std::cout << "m_GTAlgoRates["<<i<<"] = "<< it->m_GTAlgoRates[i]<<std::endl;
111  }
112  for(size_t i=0; i<it->m_GTAlgoPrescaling.size(); i++ ){
113  std::cout << "m_GTAlgoPrescaling["<<i<<"] = "<< it->m_GTAlgoPrescaling[i]<<std::endl;
114  }
115 for(size_t i=0; i<it->m_GTTechCounts.size(); i++ ){
116  std::cout << " m_GTTechCounts["<<i<<"] = "<< it->m_GTTechCounts[i]<<std::endl;
117  }
118 
119 for(size_t i=0; i<it->m_GTTechRates.size(); i++ ){
120  std::cout << " m_GTTechRates["<<i<<"] = "<< it->m_GTTechRates[i]<<std::endl;
121  }
122 for(size_t i=0; i<it->m_GTTechPrescaling.size(); i++ ){
123  std::cout << " m_GTTechPrescaling["<<i<<"] = "<< it->m_GTTechPrescaling[i]<<std::endl;
124  }
125 for(size_t i=0; i<it->m_GTPartition0TriggerCounts.size(); i++ ){
126  std::cout << " m_GTPartition0TriggerCounts["<<i<<"] = "<< it->m_GTPartition0TriggerCounts[i]<<std::endl;
127  }
128 for(size_t i=0; i<it->m_GTPartition0TriggerRates.size(); i++ ){
129  std::cout << " m_GTPartition0TriggerRates["<<i<<"] = "<< it->m_GTPartition0TriggerRates[i]<<std::endl;
130  }
131 
132 for(size_t i=0; i<it->m_GTPartition0DeadTime.size(); i++ ){
133  std::cout << " m_GTPartition0DeadTime["<<i<<"] = "<< it->m_GTPartition0DeadTime[i]<<std::endl;
134  }
135 for(size_t i=0; i<it->m_GTPartition0DeadTimeRatio.size(); i++ ){
136  std::cout << " m_GTPartition0DeadTimeRatio["<<i<<"] = "<< it->m_GTPartition0DeadTimeRatio[i]<<std::endl;
137  }
138  }
139  */
140  }
void printGTTechCounts() const
void printRunValue() const
void printGTPartition0TriggerRates() const
void printGTPartition0TriggerCounts() const
void printGTPartition0DeadTimeRatio() const
void printGTAlgoPrescaling() const
void printGTAlgoRates() const
T const * product() const
Definition: ESHandle.h:86
void printGTTechRates() const
void printFormat() const
void printGTPartition0DeadTime() const
void printLumiSegmentValues() const
heterocontainer::HCTypeTag TypeTag
void printGTAlgoCounts() const
void printGTTechPrescaling() const
static HCTypeTag findType(char const *iTypeName)
find a type based on the types name, if not found will return default HCTypeTag
Definition: HCTypeTag.cc:121

◆ beginJob()

void edmtest::L1TriggerScalerESAnalyzer::beginJob ( void  )
virtual

Reimplemented from edm::EDAnalyzer.

Definition at line 53 of file L1TriggerScalerESAnalyzer.cc.

References gather_cfg::cout.

53  {
54  std::cout<<"###L1TriggerScalerESAnalyzer::beginJob"<<std::endl;
55 
56  }

◆ beginRun()

void edmtest::L1TriggerScalerESAnalyzer::beginRun ( const edm::Run ,
const edm::EventSetup context 
)
virtual

Reimplemented from edm::EDAnalyzer.

Definition at line 44 of file L1TriggerScalerESAnalyzer.cc.

References visDQMUpload::context, and gather_cfg::cout.

44  {
45  std::cout<<"###L1TriggerScalerESAnalyzer::beginRun"<<std::endl;
46  edm::ESHandle<L1TriggerScaler> L1TriggerScaler_lumiarray;
47  std::cout<<"got eshandle"<<std::endl;
48  context.get<L1TriggerScalerRcd>().get(L1TriggerScaler_lumiarray);
49  std::cout<<"got data"<<std::endl;
50  }