122 std::vector<uint32_t> SelectedDetIds;
135 edm::LogInfo(
"SiStripMonitorPedestals") <<
"SiStripMonitorPedestals::createMEs: " 136 <<
"Number of Detector Present in cabling " << SelectedDetIds.size();
138 for (std::vector<uint32_t>::const_iterator idetid=SelectedDetIds.begin(), iEnd=SelectedDetIds.end();idetid!=iEnd;++idetid){
140 uint32_t detid = *idetid;
143 if (detid == 0 || detid == 0xFFFFFFFF){
144 edm::LogError(
"SiStripMonitorPedestals") <<
"SiStripMonitorPedestals::createMEs: " 145 <<
"Wrong DetId !!!!!! " << detid <<
" Neglecting !!!!!! ";
152 if (apv_pairs < 1 || apv_pairs > 3) {
153 edm::LogError(
"SiStripMonitorPedestals") <<
"SiStripMonitorPedestals::createMEs: Wrong APV Pairs => detId " 154 << detid <<
" APV pairs " << apv_pairs <<
" Neglecting !!!!!! ";
157 unsigned int napvs = apv_pairs * 2;
158 unsigned int nStrip = napvs * 128;
164 local_modmes.PedsPerStrip =
nullptr;
165 local_modmes.PedsDistribution =
nullptr;
166 local_modmes.PedsEvolution =
nullptr;
167 local_modmes.CMSubNoisePerStrip =
nullptr;
168 local_modmes.RawNoisePerStrip =
nullptr;
169 local_modmes.CMSubNoiseProfile =
nullptr;
170 local_modmes.RawNoiseProfile =
nullptr;
171 local_modmes.NoisyStrips =
nullptr;
172 local_modmes.NoisyStripDistribution =
nullptr;
173 local_modmes.CMDistribution =
nullptr;
174 local_modmes.CMSlopeDistribution =
nullptr;
175 local_modmes.PedsPerStripDB =
nullptr;
176 local_modmes.CMSubNoisePerStripDB =
nullptr;
177 local_modmes.BadStripsDB =
nullptr;
188 hid = hidmanager.
createHistoId(
"PedestalFromCondDB",
"det", detid);
189 local_modmes.PedsPerStripDB = ibooker.book1D(hid, hid, nStrip,0.5,nStrip+0.5);
190 ibooker.tag(local_modmes.PedsPerStripDB, detid);
191 (local_modmes.PedsPerStripDB)->setAxisTitle(
"Pedestal from CondDB(ADC) vs Strip Number",1);
193 hid = hidmanager.
createHistoId(
"NoiseFromCondDB",
"det", detid);
194 local_modmes.CMSubNoisePerStripDB = ibooker.book1D(hid, hid, nStrip,0.5,nStrip+0.5);
195 ibooker.tag(local_modmes.CMSubNoisePerStripDB, detid);
196 (local_modmes.CMSubNoisePerStripDB)->setAxisTitle(
"CMSubNoise from CondDB(ADC) vs Strip Number",1);
198 hid = hidmanager.
createHistoId(
"BadStripFlagCondDB",
"det", detid);
199 local_modmes.BadStripsDB = ibooker.book2D(hid, hid, nStrip,0.5,nStrip+0.5,6,-0.5,5.5);
200 ibooker.tag(local_modmes.BadStripsDB, detid);
201 (local_modmes.BadStripsDB)->setAxisTitle(
"Strip Flag from CondDB(ADC) vs Strip Number",1);
206 local_modmes.PedsPerStrip = ibooker.book1D(hid, hid, nStrip,0.5,nStrip+0.5);
207 ibooker.tag(local_modmes.PedsPerStrip, detid);
208 (local_modmes.PedsPerStrip)->setAxisTitle(
"Pedestal (ADC) vs Strip Number ",1);
210 hid = hidmanager.
createHistoId(
"PedsDistribution",
"det", detid);
211 local_modmes.PedsDistribution = ibooker.book2D(hid, hid, napvs,-0.5,napvs-0.5, 300, 200, 500);
212 ibooker.tag(local_modmes.PedsDistribution, detid);
213 (local_modmes.PedsDistribution)->setAxisTitle(
"Apv Number",1);
214 (local_modmes.PedsDistribution)->setAxisTitle(
"Mean Pedestal Value (ADC)",2);
216 hid = hidmanager.
createHistoId(
"PedsEvolution",
"det", detid);
217 local_modmes.PedsEvolution = ibooker.book2D(hid, hid, napvs,-0.5,napvs-0.5, 50, 0., 50.);
218 ibooker.tag(local_modmes.PedsEvolution, detid);
219 (local_modmes.PedsEvolution)->setAxisTitle(
"Apv Number",1);
220 (local_modmes.PedsEvolution)->setAxisTitle(
"Iteration Number",2);
223 hid = hidmanager.
createHistoId(
"CMSubNoisePerStrip",
"det", detid);
224 local_modmes.CMSubNoisePerStrip = ibooker.book1D(hid, hid, nStrip,0.5,nStrip+0.5);
225 ibooker.tag(local_modmes.CMSubNoisePerStrip, detid);
226 (local_modmes.CMSubNoisePerStrip)->setAxisTitle(
"CMSubNoise (ADC) vs Strip Number",1);
228 hid = hidmanager.
createHistoId(
"RawNoisePerStrip",
"det", detid);
229 local_modmes.RawNoisePerStrip = ibooker.book1D(hid, hid, nStrip,0.5,nStrip+0.5);
230 ibooker.tag(local_modmes.RawNoisePerStrip, detid);
231 (local_modmes.RawNoisePerStrip)->setAxisTitle(
"RawNoise(ADC) vs Strip Number",1);
233 hid = hidmanager.
createHistoId(
"CMSubNoiseProfile",
"det", detid);
234 local_modmes.CMSubNoiseProfile = ibooker.bookProfile(hid, hid, nStrip,0.5,nStrip+0.5, 100, 0., 100.);
235 ibooker.tag(local_modmes.CMSubNoiseProfile, detid);
236 (local_modmes.CMSubNoiseProfile)->setAxisTitle(
"Mean of CMSubNoise (ADC) vs Strip Number",1);
238 hid = hidmanager.
createHistoId(
"RawNoiseProfile",
"det", detid);
239 local_modmes.RawNoiseProfile = ibooker.bookProfile(hid, hid, nStrip,0.5,nStrip+0.5, 100, 0., 100.);
240 ibooker.tag(local_modmes.RawNoiseProfile, detid);
241 (local_modmes.RawNoiseProfile)->setAxisTitle(
"Mean of RawNoise (ADC) vs Strip Number",1);
244 local_modmes.NoisyStrips = ibooker.book2D(hid, hid, nStrip,0.5,nStrip+0.5,6,-0.5,5.5);
245 ibooker.tag(local_modmes.NoisyStrips, detid);
246 (local_modmes.NoisyStrips)->setAxisTitle(
"Strip Number",1);
247 (local_modmes.NoisyStrips)->setAxisTitle(
"Flag Value",2);
249 hid = hidmanager.
createHistoId(
"NoisyStripDistribution",
"det", detid);
250 local_modmes.NoisyStripDistribution = ibooker.book1D(hid, hid, 11, -0.5,10.5);
251 ibooker.tag(local_modmes.NoisyStripDistribution, detid);
252 (local_modmes.NoisyStripDistribution)->setAxisTitle(
"Flag Value",1);
255 hid = hidmanager.
createHistoId(
"CMDistribution",
"det", detid);
256 local_modmes.CMDistribution = ibooker.book2D(hid, hid, napvs,-0.5,napvs-0.5, 150, -15., 15.);
257 ibooker.tag(local_modmes.CMDistribution, detid);
258 (local_modmes.CMDistribution)->setAxisTitle(
"Common Mode (ADC) vs APV Number",1);
260 hid = hidmanager.
createHistoId(
"CMSlopeDistribution",
"det", detid);
261 local_modmes.CMSlopeDistribution = ibooker.book2D(hid, hid, napvs,-0.5,napvs-0.5, 100, -0.05, 0.05);
262 ibooker.tag(local_modmes.CMSlopeDistribution, detid);
263 (local_modmes.CMSlopeDistribution)->setAxisTitle(
"Common Mode Slope vs APV Number",1);
268 PedMEs.insert( std::make_pair(detid, local_modmes));
272 edm::LogInfo(
"SiStripMonitorPedestals") <<
"SiStripMonitorPedestals::createMEs: Number of DETS used "
edm::ESHandle< SiStripDetCabling > detcabling
void addActiveDetectorsRawIds(std::vector< uint32_t > &) const
static const std::string RunMode1
void setDetectorFolder(uint32_t rawdetid, const TrackerTopology *tTopo)
edm::ParameterSet pedsPSet_
static const std::string RunMode3
bool instantiateApvs(uint32_t det_id, int numberOfApvs)
ApvAnalysisFactory * apvFactory_
std::string createHistoId(std::string description, std::string id_type, uint32_t component_id)
const uint16_t nApvPairs(uint32_t det_id) const
static const std::string RunMode2
T const * product() const
void resetMEs(uint32_t idet)
std::map< uint32_t, ModMEs > PedMEs