CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
SiStripThresholdReader Class Reference

#include <SiStripThresholdReader.h>

Inheritance diagram for SiStripThresholdReader:
edm::EDAnalyzer edm::EDConsumerBase

Public Member Functions

void analyze (const edm::Event &, const edm::EventSetup &) override
 
 SiStripThresholdReader (const edm::ParameterSet &)
 
 ~SiStripThresholdReader () 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
 
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::vector< ModuleDescription const * > &modules, 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
 
ProductResolverIndexAndSkipBit uncheckedIndexFrom (EDGetToken) const
 
void updateLookup (BranchType iBranchType, ProductResolverIndexHelper const &, bool iPrefetchMayGet)
 
void updateLookup (eventsetup::ESRecordsToProxyIndices const &)
 
virtual ~EDConsumerBase () noexcept(false)
 

Private Attributes

uint32_t printdebug_
 

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 wantsStreamLuminosityBlocks ()
 
static bool wantsStreamRuns ()
 
- Protected Member Functions inherited from edm::EDConsumerBase
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > consumes (edm::InputTag const &tag)
 
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<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)
 

Detailed Description

Definition at line 25 of file SiStripThresholdReader.h.

Constructor & Destructor Documentation

SiStripThresholdReader::SiStripThresholdReader ( const edm::ParameterSet iConfig)
explicit

Definition at line 7 of file SiStripThresholdReader.cc.

8  : printdebug_(iConfig.getUntrackedParameter<uint32_t>("printDebug", 3)) {}
T getUntrackedParameter(std::string const &, T const &) const
SiStripThresholdReader::~SiStripThresholdReader ( )
override

Definition at line 10 of file SiStripThresholdReader.cc.

10 {}

Member Function Documentation

void SiStripThresholdReader::analyze ( const edm::Event e,
const edm::EventSetup iSetup 
)
override

Definition at line 12 of file SiStripThresholdReader.cc.

References data, SiStripThreshold::Data::FirstStrip_and_Hth, edm::EventSetup::get(), SiStripThreshold::Data::getClusth(), SiStripThreshold::getData(), SiStripThreshold::getDetIds(), SiStripThreshold::Data::getFirstStrip(), SiStripThreshold::Data::getHth(), SiStripThreshold::Data::getLth(), SiStripThreshold::getRange(), triggerObjects_cff::id, SiStripThreshold::Data::print(), printdebug_, FastTimerService_cff::range, and contentValuesCheck::ss.

12  {
13  edm::ESHandle<SiStripThreshold> SiStripThreshold_;
14  iSetup.get<SiStripThresholdRcd>().get(SiStripThreshold_);
15  edm::LogInfo("SiStripThresholdReader") << "[SiStripThresholdReader::analyze] End Reading SiStripThreshold"
16  << std::endl;
17 
18  std::vector<uint32_t> detid;
19  SiStripThreshold_->getDetIds(detid);
20  edm::LogInfo("Number of detids ") << detid.size() << std::endl;
21  if (printdebug_)
22  for (size_t id = 0; id < detid.size() && id < printdebug_; id++) {
23  SiStripThreshold::Range range = SiStripThreshold_->getRange(detid[id]);
24 
25  //int strip=0;
26  float old_clusTh = -1, old_lowTh = -1, old_highTh = -1, old_FirstStrip = -1;
27  for (int it = 0; it < 768; it++) {
28  SiStripThreshold::Data data = SiStripThreshold_->getData(it, range);
29  std::stringstream ss;
30  data.print(ss);
31  if (old_clusTh != data.getClusth() || old_lowTh != data.getLth() || old_highTh != data.getHth() ||
32  old_FirstStrip != data.getFirstStrip()) {
33  edm::LogInfo("SiStripThresholdReader")
34  << "detid: " << detid[id] << " \t"
35  << "strip: " << it << " \t" << ss.str() << "FirstStrip_and_Hth: " << data.FirstStrip_and_Hth << " \n"
36  << std::endl;
37  old_lowTh = data.getLth();
38  old_highTh = data.getHth();
39  old_clusTh = data.getClusth();
40  old_FirstStrip = data.getFirstStrip();
41  }
42  }
43  }
44 }
SiStripThreshold::Data getData(const uint16_t &strip, const Range &range) const
uint16_t getFirstStrip() const
void print(std::stringstream &ss) const
std::pair< ContainerIterator, ContainerIterator > Range
void getDetIds(std::vector< uint32_t > &DetIds_) const
char data[epos_bytes_allocation]
Definition: EPOS_Wrapper.h:79
T get() const
Definition: EventSetup.h:73
const Range getRange(const uint32_t &detID) const
float getClusth() const

Member Data Documentation

uint32_t SiStripThresholdReader::printdebug_
private

Definition at line 33 of file SiStripThresholdReader.h.

Referenced by analyze().