CMS 3D CMS Logo

SiStripPedestalsReader.cc
Go to the documentation of this file.
2 
3 using namespace std;
4 using namespace cms;
5 
7  : printdebug_(iConfig.getUntrackedParameter<uint32_t>("printDebug", 1)), pedestalsToken_(esConsumes()) {}
8 
10 
12  const auto& pedestals = iSetup.getData(pedestalsToken_);
13  edm::LogInfo("SiStripPedestalsReader") << "[SiStripPedestalsReader::analyze] End Reading SiStripPedestals"
14  << std::endl;
15 
16  std::vector<uint32_t> detid;
17  pedestals.getDetIds(detid);
18  edm::LogInfo("Number of detids ") << detid.size() << std::endl;
19 
20  if (printdebug_)
21  for (size_t id = 0; id < detid.size() && id < printdebug_; id++) {
22  SiStripPedestals::Range range = pedestals.getRange(detid[id]);
23 
24  int strip = 0;
25  for (int it = 0; it < (range.second - range.first) * 8 / 10; it++) {
26  edm::LogInfo("SiStripPedestalsReader")
27  << "detid " << detid[id] << " \t"
28  << " strip " << strip++ << " \t" << pedestals.getPed(it, range) << " \t" << std::endl;
29  }
30  }
31 }
FastTimerService_cff.range
range
Definition: FastTimerService_cff.py:34
SiStripPedestals::Range
std::pair< ContainerIterator, ContainerIterator > Range
Definition: SiStripPedestals.h:51
SiStripPedestalsReader::SiStripPedestalsReader
SiStripPedestalsReader(const edm::ParameterSet &)
Definition: SiStripPedestalsReader.cc:6
digitizers_cfi.strip
strip
Definition: digitizers_cfi.py:19
edm::LogInfo
Log< level::Info, false > LogInfo
Definition: MessageLogger.h:125
edm::ParameterSet
Definition: ParameterSet.h:47
SiStripPedestalsReader::analyze
void analyze(const edm::Event &, const edm::EventSetup &) override
Definition: SiStripPedestalsReader.cc:11
edm::EventSetup
Definition: EventSetup.h:58
edm::EventSetup::getData
bool getData(T &iHolder) const
Definition: EventSetup.h:127
SiStripPedestalsReader.h
std
Definition: JetResolutionObject.h:76
SiStripPedestalsReader::~SiStripPedestalsReader
~SiStripPedestalsReader() override
Definition: SiStripPedestalsReader.cc:9
triggerObjects_cff.id
id
Definition: triggerObjects_cff.py:29
SiStripPedestalsReader::printdebug_
uint32_t printdebug_
Definition: SiStripPedestalsReader.h:33
DeDxTools::esConsumes
ESGetTokenH3DDVariant esConsumes(std::string const &Reccord, edm::ConsumesCollector &)
Definition: DeDxTools.cc:283
edm::Event
Definition: Event.h:73
SiStripPedestalsReader::pedestalsToken_
edm::ESGetToken< SiStripPedestals, SiStripPedestalsRcd > pedestalsToken_
Definition: SiStripPedestalsReader.h:34
cms
Namespace of DDCMS conversion namespace.
Definition: ProducerAnalyzer.cc:21
MillePedeFileConverter_cfg.e
e
Definition: MillePedeFileConverter_cfg.py:37