6 #include <boost/regex.hpp>
7 #include <boost/format.hpp>
41 event.getByToken(
token, handle);
47 template <
typename R,
typename T>
51 setup.get<
R>().
get(handle);
120 descriptions.
add(
"triggerBxMonitor", desc);
127 m_hlt_results( consumes<edm::TriggerResults>( config.getUntrackedParameter<edm::
InputTag>(
"hltResults" ) ) ),
128 m_dqm_path( config.getUntrackedParameter<std::
string>(
"dqmPath" ) ),
153 m_l1tMenu = & get<L1TUtmTriggerMenuRcd, L1TUtmTriggerMenu>(
setup);
158 edm::LogError(
"TriggerBxMonitor") <<
"failed to read the L1 menu from the EventSetup, the L1 trigger bx distribution will not be monitored";
170 edm::LogError(
"TriggerBxMonitor") <<
"failed to initialise HLTConfigProvider, the HLT bx distribution will not be monitored";
186 for (
unsigned int i = 0;
i <
size; ++
i) {
203 unsigned int bit = keyval.second.getIndex();
206 m_l1t_bx_all->GetYaxis()->SetBinLabel(bit+1, keyval.first.c_str());
229 unsigned int bx =
event.bunchCrossing();
234 unsigned int type =
event.experimentType();
243 if (not bxvector.isEmpty(0)) {
244 auto const &
results = bxvector.at(0, 0);
246 if (
results.getAlgoDecisionFinal(
i)) {
258 for (
unsigned int i = 0;
i <
m_hlt_bx.size(); ++
i) {
265 edm::LogWarning(
"TriggerBxMonitor") <<
"This should never happen: the number of HLT paths has changed since the beginning of the run";
unsigned int size() const
number of trigger paths in trigger table
static const char *const s_tcds_trigger_types[]
HLTConfigProvider m_hltConfig
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
ParameterDescriptionBase * addUntracked(U const &iLabel, T const &value)
const std::string & triggerName(unsigned int triggerIndex) const
#define DEFINE_FWK_MODULE(type)
const edm::EDGetTokenT< GlobalAlgBlkBxCollection > m_l1t_results
string format
Some error handling for the usage.
const edm::EDGetTokenT< edm::TriggerResults > m_hlt_results
virtual void bookHistograms(DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &) override
static const unsigned int maxPhysicsTriggers
bool inited() const
Accessors (const methods)
std::vector< TH1F * > m_tcds_bx
std::vector< TH1F * > m_l1t_bx
MonitorElement * book1D(Args &&...args)
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is excluding the probing of A single or multiple positive and the trigger will pass if any such matching triggers are PASS or EXCEPTION[A criterion thatmatches no triggers at all is detected and causes a throw.] A single negative with an expectation of appropriate bit checking in the decision and the trigger will pass if any such matching triggers are FAIL or EXCEPTION A wildcarded negative criterion that matches more than one trigger in the trigger but the state exists so we define the behavior If all triggers are the negative crieriion will lead to accepting the event(this again matches the behavior of"!*"before the partial wildcard feature was incorporated).The per-event"cost"of each negative criterion with multiple relevant triggers is about the same as!*was in the past
const std::string m_dqm_path
TriggerBxMonitor(edm::ParameterSet const &)
virtual void dqmBeginRun(edm::Run const &, edm::EventSetup const &) override
L1TUtmTriggerMenu const * m_l1tMenu
void setCurrentFolder(const std::string &fullpath)
T const * product() const
MonitorElement * book2D(Args &&...args)
bool init(const edm::Run &iRun, const edm::EventSetup &iSetup, const std::string &processName, bool &changed)
d'tor
T const * product() const
static const unsigned int s_bx_range
TH1F * getTH1F(void) const
void add(std::string const &label, ParameterSetDescription const &psetDescription)
std::vector< TH1F * > m_hlt_bx
void labelsForToken(EDGetToken iToken, Labels &oLabels) const
std::shared_ptr< cms::Exception > whyFailed() const
TH2F * getTH2F(void) const
virtual void analyze(edm::Event const &, edm::EventSetup const &) override
void setup(std::vector< TH2F > &depth, std::string name, std::string units="")
tuple size
Write out results.