18 fL1GtDaqReadoutRecordInputTag(iConfig.getParameter<
edm::
InputTag>(
"L1GtDaqReadoutRecordInputTag")),
19 fL1GtRecordInputTag(iConfig.getParameter<
edm::
InputTag>(
"L1GtRecordInputTag")),
20 m_l1GtUtils(iConfig, consumesCollector(),
false, *this, fL1GtRecordInputTag, fL1GtDaqReadoutRecordInputTag,
edm::
InputTag()) {
22 LogDebug(
"HLTSeedL1LogicScalers") <<
"constructor";
31 "DQMFolder",
string(
"HLT/HLTSeedL1LogicScalers/HLT_LogicL1"));
44 <<
"HLTConfigProvider failed to initialize.";
49 for (
unsigned int j = 0; j !=
n; ++j) {
50 LogTrace(
"HLTSeedL1LogicScalers") <<
"HLTConfig path " 60 <<
"size of vector of paths to monitor = " <<
fMonitorPaths.size()
62 for (
unsigned int iPath = 0; iPath <
fMonitorPaths.size(); iPath++) {
64 LogTrace(
"HLTSeedL1LogicScalers") <<
"monPath = " << monPath << endl;
66 string folderName =
fDQMFolder +
"/" + monPath;
74 << endl <<
"size of vector of GTSeedL1LogicalExpression = " 75 << hltL1GTSeed.size() << endl;
78 for (
unsigned int iSeed = 0; iSeed < hltL1GTSeed.size(); iSeed++) {
80 <<
" TechBit_flag = " << hltL1GTSeed[iSeed].first
81 <<
" GTSeedL1LogicalExpression = " << hltL1GTSeed[iSeed].second
84 istringstream totalSString(hltL1GTSeed[iSeed].
second);
87 vector<string> l1Algos;
90 while (!hltL1GTSeed[iSeed].
first) {
91 totalSString >> temp_string;
93 if (!l1Algos.empty()) {
94 if (temp_string == l1Algos.back())
break;
96 if (temp_string !=
"OR" && temp_string !=
"AND" &&
97 temp_string !=
"NOT" && temp_string !=
"(" && temp_string !=
")" &&
99 l1Algos.push_back(temp_string);
103 int nL1Algo = l1Algos.size();
108 <<
" number of l1 Algos grater than 32. Using only the first 32." 112 int nBins = 1 << nL1Algo;
114 for (
unsigned int k = 0;
k < l1Algos.size();
k++) {
115 LogTrace(
"HLTSeedL1LogicScalers") <<
" l1 Algo = " << l1Algos[
k]
119 std::stringstream
title;
120 std::stringstream
name;
122 name << monPath <<
"_Seed_" << iSeed <<
"_L1BitLogic";
123 title << monPath <<
" BitPacked L1Algos of GTSeed " << iSeed <<
": '" 124 << hltL1GTSeed[iSeed].second <<
"'";
126 LogTrace(
"HLTSeedL1LogicScalers") <<
" MonitorElement name = " << name
128 LogTrace(
"HLTSeedL1LogicScalers") <<
" MonitorElement title = " << title
130 LogTrace(
"HLTSeedL1LogicScalers") <<
" MonitorElement nBins = " << nBins
145 LogDebug(
"HLTSeedL1LogicScalers") <<
"HLTSeedL1LogicScalers::analyze event ";
162 unsigned int myL1Word = 0;
165 for (
unsigned int j = 0; j < l1Algos.size(); j++) {
168 LogTrace(
"HLTSeedL1LogicScalers") <<
"l1Algo = " << l1Algos[j]
169 <<
" l1Pass = " << l1Pass << endl;
172 myL1Word |= (1 << j);
181 const string& l1AlgoName) {
182 LogTrace(
"HLTSeedL1LogicScalers") <<
"analyzeL1GtUtils..." << endl;
189 LogTrace(
"HLTSeedL1LogicScalers") <<
"l1AlgoName = " << l1AlgoName << endl;
191 bool decisionAlgTechTrig =
false;
206 <<
" decisionAlgTechTrig = " << decisionAlgTechTrig << endl;
208 if (iErrorCode == 0) {
209 return decisionAlgTechTrig;
210 }
else if (iErrorCode == 1) {
213 <<
"L1 algorithm " << l1AlgoName
214 <<
" not in L1 menu, but HLTConfigProvider found it in " 215 "L1SeedsLogicalExpression of at least one HLT path of the HLT menu."
unsigned int size() const
number of trigger paths in trigger table
T getParameter(std::string const &) const
T getUntrackedParameter(std::string const &, T const &) const
const std::string & getName(void) const
get name of ME
const std::string & triggerName(unsigned int triggerIndex) const
~HLTSeedL1LogicScalers() override
const std::vector< std::vector< std::pair< bool, std::string > > > & hltL1GTSeeds() const
bool analyzeL1GtUtils(const edm::Event &, const edm::EventSetup &, const std::string &)
std::vector< std::pair< MonitorElement *, std::vector< std::string > > > fMapMEL1Algos
HLTSeedL1LogicScalers(const edm::ParameterSet &)
unsigned int triggerIndex(const std::string &triggerName) const
slot position of trigger path in trigger table (0 to size-1)
U second(std::pair< T, U > const &p)
MonitorElement * book1D(Args &&...args)
void retrieveL1EventSetup(const edm::EventSetup &)
retrieve all the relevant L1 trigger event setup records and cache them to improve the speed ...
HLTConfigProvider fHLTConfig
std::vector< std::string > fMonitorPaths
const bool decisionBeforeMask(const edm::Event &iEvent, const std::string &nameAlgoTechTrig, int &errorCode) const
return decision before trigger mask for a given algorithm or technical trigger
std::vector< MonitorElement * > fMonitorPathsME
void setCurrentFolder(const std::string &fullpath)
bool init(const edm::Run &iRun, const edm::EventSetup &iSetup, const std::string &processName, bool &changed)
d'tor
void bookHistograms(DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &) override
void dqmBeginRun(const edm::Run &run, const edm::EventSetup &c) override
const bool decisionAfterMask(const edm::Event &iEvent, const std::string &nameAlgoTechTrig, int &errorCode) const
return decision after trigger mask for a given algorithm or technical trigger
void setAxisTitle(const std::string &title, int axis=1)
set x-, y- or z-axis title (axis=1, 2, 3 respectively)
void analyze(const edm::Event &, const edm::EventSetup &) override