36 edm::LogInfo(
"SiStripPedestalsDQMService") <<
"[SiStripPedestalsDQMService::SiStripPedestalsDQMService]";
40 edm::LogInfo(
"SiStripPedestalsDQMService") <<
"[SiStripPedestalsDQMService::~SiStripPedestalsDQMService]";
44 std::cout <<
"SiStripPedestalsDQMService::readPedestals" << std::endl;
53 uint32_t stripsPerApv = 128;
61 MEs.erase(std::remove_if(MEs.begin(),
64 return std::string::npos ==
ME->getName().find(
"PedsPerStrip__det__");
69 for (
const auto& detInfo : detInfo.getAllData()) {
76 std::string MEname(
"PedsPerStrip__det__" + std::to_string(detInfo.first));
78 if (ime->getName() == MEname) {
88 TH1F*
histo = mE->getTH1F();
91 uint32_t nBinsX = histo->GetXaxis()->GetNbins();
93 if (nBinsX != stripsPerApv * (detInfo.second.nApvs)) {
94 std::cout <<
"ERROR: number of bin = " << nBinsX
95 <<
" != number of strips = " << stripsPerApv * (detInfo.second.nApvs) << std::endl;
100 for (uint32_t iBin = 1; iBin <= nBinsX; ++iBin) {
102 m_obj.
setData(histo->GetBinContent(iBin), theSiStripVector);
105 std::cout <<
"ERROR: histo = " << histo << std::endl;
108 std::cout <<
"ERROR: ME = " << mE << std::endl;
111 if (theSiStripVector.empty()) {
112 for (
unsigned short j = 0;
j < 128 * detInfo.second.nApvs; ++
j) {
117 if (!
m_obj.
put(detInfo.first, theSiStripVector))
118 edm::LogError(
"SiStripPedestalsFakeESSource::produce ") <<
" detid already exists" << std::endl;
T getUntrackedParameter(std::string const &, T const &) const
dqm::legacy::DQMStore DQMStore
SiStripPedestals * getObj() const override
dqm::legacy::MonitorElement MonitorElement
#define DEFINE_FWK_MODULE(type)
~SiStripPopConPedestalsHandlerFromDQM() override
void dqmEndJob(DQMStore::IBooker &booker, DQMStore::IGetter &getter) override
SiStripPopConPedestalsHandlerFromDQM(const edm::ParameterSet &iConfig, edm::ConsumesCollector &&)
virtual std::vector< dqm::harvesting::MonitorElement * > getAllContents(std::string const &path) const
std::vector< uint16_t > InputVector
SiStripDetInfo read(std::string filePath)
Log< level::Info, false > LogInfo
bool put(const uint32_t &detID, InputVector &input)
void setData(float ped, InputVector &vped)
dqm::harvesting::MonitorElement ME
std::string fullPath() const
static constexpr char const *const kDefaultFile