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 Member Functions | Private Attributes
L1TUtmTriggerMenuDumper Class Reference
Inheritance diagram for L1TUtmTriggerMenuDumper:
edm::EDAnalyzer edm::EDConsumerBase

Public Member Functions

 L1TUtmTriggerMenuDumper (const ParameterSet &)
 
 ~L1TUtmTriggerMenuDumper () override
 
- 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)
 

Static Public Member Functions

static void fillDescriptions (ConfigurationDescriptions &descriptions)
 
- 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 ()
 

Private Member Functions

void analyze (Event const &, EventSetup const &) override
 
void beginJob () override
 
void beginLuminosityBlock (LuminosityBlock const &, EventSetup const &) override
 
void beginRun (Run const &, EventSetup const &) override
 
void endJob () override
 
void endLuminosityBlock (LuminosityBlock const &, EventSetup const &) override
 
void endRun (Run const &, EventSetup const &) override
 

Private Attributes

edm::ESGetToken
< L1TUtmTriggerMenu,
L1TUtmTriggerMenuRcd
m_l1TriggerMenuToken
 

Additional Inherited Members

- Public Types inherited from edm::EDAnalyzer
typedef EDAnalyzer ModuleType
 
- Public Types inherited from edm::EDConsumerBase
typedef ProductLabels Labels
 
- 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

Definition at line 36 of file L1TUtmTriggerMenuDumper.cc.

Constructor & Destructor Documentation

L1TUtmTriggerMenuDumper::L1TUtmTriggerMenuDumper ( const ParameterSet iConfig)
explicit

Definition at line 55 of file L1TUtmTriggerMenuDumper.cc.

56  : m_l1TriggerMenuToken(esConsumes<L1TUtmTriggerMenu, L1TUtmTriggerMenuRcd, edm::Transition::BeginRun>()) {}
edm::ESGetToken< L1TUtmTriggerMenu, L1TUtmTriggerMenuRcd > m_l1TriggerMenuToken
L1TUtmTriggerMenuDumper::~L1TUtmTriggerMenuDumper ( )
override

Definition at line 58 of file L1TUtmTriggerMenuDumper.cc.

58 {}

Member Function Documentation

void L1TUtmTriggerMenuDumper::analyze ( Event const &  iEvent,
EventSetup const &  iSetup 
)
overrideprivatevirtual

Implements edm::EDAnalyzer.

Definition at line 60 of file L1TUtmTriggerMenuDumper.cc.

60 {}
void L1TUtmTriggerMenuDumper::beginJob ( void  )
overrideprivatevirtual

Reimplemented from edm::EDAnalyzer.

Definition at line 62 of file L1TUtmTriggerMenuDumper.cc.

References gather_cfg::cout.

62 { cout << "INFO: L1TUtmTriggerMenuDumper module beginJob called.\n"; }
tuple cout
Definition: gather_cfg.py:144
void L1TUtmTriggerMenuDumper::beginLuminosityBlock ( LuminosityBlock const &  ,
EventSetup const &   
)
overrideprivatevirtual

Reimplemented from edm::EDAnalyzer.

Definition at line 188 of file L1TUtmTriggerMenuDumper.cc.

188 {}
void L1TUtmTriggerMenuDumper::beginRun ( Run const &  run,
EventSetup const &  iSetup 
)
overrideprivatevirtual

Reimplemented from edm::EDAnalyzer.

Definition at line 66 of file L1TUtmTriggerMenuDumper.cc.

References gather_cfg::cout, GOODCOLL_filter_cfg::cut, cuts, submitPVResolutionJobs::EXT, edm::EventSetup::getHandle(), cuy::ii, findQualityFiles::jj, GetRecoTauVFromDQM_MC_cff::kk, m_l1TriggerMenuToken, relval_steps::menu, dqmiodumpmetadata::n, hgcalPerformanceValidation::objects, edm::ESHandle< class >::product(), AlCaHLTBitMon_QueryRunRegistry::string, and unpackBuffers-CaloStage2::token.

66  {
68  const esTriggerMenu* menu = reinterpret_cast<const esTriggerMenu*>(hmenu.product());
69 
70  const std::map<std::string, esAlgorithm>& algoMap = menu->getAlgorithmMap();
71  const std::map<std::string, esCondition>& condMap = menu->getConditionMap();
72  const std::map<std::string, esScale>& scaleMap = menu->getScaleMap();
73 
74  bool hasPrecision = false;
75  std::map<std::string, unsigned int> precisions;
76  getPrecisions(precisions, scaleMap);
77  for (std::map<std::string, unsigned int>::const_iterator cit = precisions.begin(); cit != precisions.end(); cit++) {
78  std::cout << cit->first << " = " << cit->second << "\n";
79  hasPrecision = true;
80  }
81 
82  if (hasPrecision) {
83  std::map<std::string, esScale>::iterator it1, it2;
84  const esScale* scale1 = &scaleMap.find("EG-ETA")->second;
85  const esScale* scale2 = &scaleMap.find("MU-ETA")->second;
86 
87  std::vector<long long> lut_eg_2_mu_eta;
88  getCaloMuonEtaConversionLut(lut_eg_2_mu_eta, scale1, scale2);
89 
90  scale1 = &scaleMap.find("EG-PHI")->second;
91  scale2 = &scaleMap.find("MU-PHI")->second;
92 
93  std::vector<long long> lut_eg_2_mu_phi;
94  getCaloMuonPhiConversionLut(lut_eg_2_mu_phi, scale1, scale2);
95 
96  scale1 = &scaleMap.find("EG-ETA")->second;
97  scale2 = &scaleMap.find("MU-ETA")->second;
98 
99  std::vector<double> eg_mu_delta_eta;
100  std::vector<long long> lut_eg_mu_delta_eta;
101  size_t n = getDeltaVector(eg_mu_delta_eta, scale1, scale2);
102  setLut(lut_eg_mu_delta_eta, eg_mu_delta_eta, precisions["PRECISION-EG-MU-Delta"]);
103 
104  std::vector<long long> lut_eg_mu_cosh;
105  applyCosh(eg_mu_delta_eta, n);
106  setLut(lut_eg_mu_cosh, eg_mu_delta_eta, precisions["PRECISION-EG-MU-Math"]);
107 
108  scale1 = &scaleMap.find("EG-PHI")->second;
109  scale2 = &scaleMap.find("MU-PHI")->second;
110 
111  std::vector<double> eg_mu_delta_phi;
112  std::vector<long long> lut_eg_mu_delta_phi;
113  n = getDeltaVector(eg_mu_delta_phi, scale1, scale2);
114  setLut(lut_eg_mu_delta_phi, eg_mu_delta_phi, precisions["PRECISION-EG-MU-Delta"]);
115 
116  std::vector<long long> lut_eg_mu_cos;
117  applyCos(eg_mu_delta_phi, n);
118  setLut(lut_eg_mu_cos, eg_mu_delta_phi, precisions["PRECISION-EG-MU-Math"]);
119 
120  scale1 = &scaleMap.find("EG-ET")->second;
121  std::vector<long long> lut_eg_et;
122  getLut(lut_eg_et, scale1, precisions["PRECISION-EG-MU-MassPt"]);
123 
124  scale1 = &scaleMap.find("MU-ET")->second;
125  std::vector<long long> lut_mu_et;
126  getLut(lut_mu_et, scale1, precisions["PRECISION-EG-MU-MassPt"]);
127  for (size_t ii = 0; ii < lut_mu_et.size(); ii++) {
128  std::cout << lut_mu_et.at(ii) << "\n";
129  }
130  }
131 
132  for (std::map<std::string, esAlgorithm>::const_iterator cit = algoMap.begin(); cit != algoMap.end(); cit++) {
133  const esAlgorithm& algo = cit->second;
134  std::cout << "algo name = " << algo.getName() << "\n";
135  std::cout << "algo exp. = " << algo.getExpression() << "\n";
136  std::cout << "algo exp. in cond. = " << algo.getExpressionInCondition() << "\n";
137 
138  const std::vector<std::string>& rpn_vec = algo.getRpnVector();
139  for (size_t ii = 0; ii < rpn_vec.size(); ii++) {
140  const std::string& token = rpn_vec.at(ii);
141  if (Algorithm::isGate(token))
142  continue;
143  const esCondition& condition = condMap.find(token)->second;
144  std::cout << " cond type = " << condition.getType() << "\n";
145 
146  const std::vector<esCut>& cuts = condition.getCuts();
147  for (size_t jj = 0; jj < cuts.size(); jj++) {
148  const esCut& cut = cuts.at(jj);
149  std::cout << " cut name = " << cut.getName() << "\n";
150  std::cout << " cut target = " << cut.getObjectType() << "\n";
151  std::cout << " cut type = " << cut.getCutType() << "\n";
152  std::cout << " cut min. value index = " << cut.getMinimum().value << " " << cut.getMinimum().index << "\n";
153  std::cout << " cut max. value index = " << cut.getMaximum().value << " " << cut.getMaximum().index << "\n";
154  std::cout << " cut data = " << cut.getData() << "\n";
155  }
156 
157  const std::vector<esObject>& objects = condition.getObjects();
158  for (size_t jj = 0; jj < objects.size(); jj++) {
159  const esObject& object = objects.at(jj);
160  std::cout << " obj name = " << object.getName() << "\n";
161  std::cout << " obj type = " << object.getType() << "\n";
162  std::cout << " obj op = " << object.getComparisonOperator() << "\n";
163  std::cout << " obj bx = " << object.getBxOffset() << "\n";
164  if (object.getType() == esObjectType::EXT) {
165  std::cout << " ext name = " << object.getExternalSignalName() << "\n";
166  std::cout << " ext ch id = " << object.getExternalChannelId() << "\n";
167  }
168 
169  const std::vector<esCut>& cuts = object.getCuts();
170  for (size_t kk = 0; kk < cuts.size(); kk++) {
171  const esCut& cut = cuts.at(kk);
172  std::cout << " cut name = " << cut.getName() << "\n";
173  std::cout << " cut target = " << cut.getObjectType() << "\n";
174  std::cout << " cut type = " << cut.getCutType() << "\n";
175  std::cout << " cut min. value index = " << cut.getMinimum().value << " " << cut.getMinimum().index
176  << "\n";
177  std::cout << " cut max. value index = " << cut.getMaximum().value << " " << cut.getMaximum().index
178  << "\n";
179  std::cout << " cut data = " << cut.getData() << "\n";
180  }
181  }
182  }
183  }
184 }
int ii
Definition: cuy.py:589
TkSoA const *__restrict__ CAHitNtupletGeneratorKernelsGPU::QualityCuts cuts
edm::ESGetToken< L1TUtmTriggerMenu, L1TUtmTriggerMenuRcd > m_l1TriggerMenuToken
T const * product() const
Definition: ESHandle.h:86
tuple cout
Definition: gather_cfg.py:144
void L1TUtmTriggerMenuDumper::endJob ( void  )
overrideprivatevirtual

Reimplemented from edm::EDAnalyzer.

Definition at line 64 of file L1TUtmTriggerMenuDumper.cc.

References gather_cfg::cout.

64 { cout << "INFO: L1TUtmTriggerMenuDumper module endJob called.\n"; }
tuple cout
Definition: gather_cfg.py:144
void L1TUtmTriggerMenuDumper::endLuminosityBlock ( LuminosityBlock const &  ,
EventSetup const &   
)
overrideprivatevirtual

Reimplemented from edm::EDAnalyzer.

Definition at line 190 of file L1TUtmTriggerMenuDumper.cc.

190 {}
void L1TUtmTriggerMenuDumper::endRun ( Run const &  ,
EventSetup const &   
)
overrideprivatevirtual

Reimplemented from edm::EDAnalyzer.

Definition at line 186 of file L1TUtmTriggerMenuDumper.cc.

186 {}
void L1TUtmTriggerMenuDumper::fillDescriptions ( ConfigurationDescriptions descriptions)
static

Definition at line 192 of file L1TUtmTriggerMenuDumper.cc.

References edm::ConfigurationDescriptions::addDefault(), submitPVResolutionJobs::desc, and edm::ParameterSetDescription::setUnknown().

192  {
193  //The following says we do not know what parameters are allowed so do no validation
194  // Please change this to state exactly what you do use, even if it is no parameters
196  desc.setUnknown();
197  descriptions.addDefault(desc);
198 }
void addDefault(ParameterSetDescription const &psetDescription)

Member Data Documentation

edm::ESGetToken<L1TUtmTriggerMenu, L1TUtmTriggerMenuRcd> L1TUtmTriggerMenuDumper::m_l1TriggerMenuToken
private

Definition at line 52 of file L1TUtmTriggerMenuDumper.cc.

Referenced by beginRun().