4 :
gainToken_{esConsumes<edm::Transition::BeginRun>()},
tTopoToken_{esConsumes<edm::Transition::BeginRun>()} {
6 file =
new TFile(
"correlTest.root",
"RECREATE");
25 std::vector<TH1F *>
histos;
35 for (; iter != iterE; ++iter) {
39 edm::LogInfo(
"") <<
"[Doanalysis] detid " << *iter <<
" range " << range.second - range.first;
40 size_t apv = 0, apvE = (range.second - range.first);
41 for (; apv < apvE; apv += 2) {
44 for (
size_t i = 0;
i < histos.size(); ++
i)
45 histos[
i]->
Fill(value);
69 int index = 100 + subdet * 100 + component;
71 histos.push_back(
getHisto(subdet + 1));
76 if (
vTH1.size() < index + 1)
77 vTH1.resize(index + 1,
nullptr);
79 if (
vTH1[index] ==
nullptr) {
81 sprintf(name,
"%lu", index);
82 edm::LogInfo(
"") <<
"[getHisto] creating index " << index << std::endl;
83 vTH1[
index] =
new TH1F(name, name, 150, 0., 5.);
90 for (
size_t i = 0;
i <
vTH1.size();
i++)
91 if (
vTH1[
i] !=
nullptr)
97 tkmap->
save(
false, 0, 0,
"testTkMap.png");
ContainerIterator getFirstElement(RegistryConstIterator &idet)
edm::ESGetToken< TrackerTopology, TrackerTopologyRcd > tTopoToken_
unsigned int tibLayer(const DetId &id) const
Registry::const_iterator RegistryConstIterator
static float getApvGain(uint16_t apv, const Range &range)
RegistryConstIterator detid_end
RegistryConstIterator detid_begin
unsigned int tidWheel(const DetId &id) const
const uint16_t range(const Frame &aFrame)
bool getData(T &iHolder) const
void DoAnalysis(const TrackerTopology &tTopo, const SiStripApvGain &)
unsigned int tidSide(const DetId &id) const
void Fill(HcalDetId &id, double val, std::vector< TH2F > &depth)
void save(bool print_total=true, float minval=0., float maxval=0., std::string s="svgmap.svg", int width=1500, int height=800)
constexpr int subdetId() const
get the contents of the subdetector field (not cast into any detector's numbering enum) ...
std::pair< ContainerIterator, ContainerIterator > Range
Log< level::Info, false > LogInfo
ContainerIterator getLastElement(RegistryConstIterator &idet)
TH1F * getHisto(const long unsigned int &index)
edm::ESGetToken< SiStripApvGain, SiStripApvGainRcd > gainToken_
bool check(const edm::EventSetup &iSetup)
void getHistos(DetId detid, const TrackerTopology &tTopo, std::vector< TH1F * > &histos)
SiStripPlotGain(const edm::ParameterSet &)
std::vector< TH1F * > vTH1
edm::ESWatcher< SiStripApvGainRcd > gainWatcher_
void beginRun(const edm::Run &run, const edm::EventSetup &es) override
unsigned int tecWheel(const DetId &id) const
RegistryPointers getRegistryPointers() const
void fill(int layer, int ring, int nmod, float x)
unsigned int tobLayer(const DetId &id) const
~SiStripPlotGain() override
unsigned int tecSide(const DetId &id) const