ATLAS Offline Software
Loading...
Searching...
No Matches
HitMapBuilder.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2023 CERN for the benefit of the ATLAS collaboration
3*/
4
5#ifndef PIXELCONDITIONSALGS_HITMAPBUILDER_H
6#define PIXELCONDITIONSALGS_HITMAPBUILDER_H
7
9#include "GaudiKernel/ServiceHandle.h"
13#include "GaudiKernel/ITHistSvc.h"
14
15#include <string>
16#include <vector>
17#include <utility> // pair
18
19// EDM
21
22#include "TH1.h"
23#include "TH2.h"
24
25
26class PixelID;
27
28
29namespace InDetDD{
31}
32
45
47
48 public:
49
50 //Delegate to base-class constructor
52
54
55 StatusCode initialize();
56 StatusCode execute();
57 StatusCode finalize();
58
59 private:
60 std::string getDCSIDFromPosition(int bec, int layer, int modPhi, int modEta);
61 std::vector<std::string> &splitter(const std::string &str, char delim, std::vector<std::string> &elems);
62 std::vector<std::string> splitter(const std::string &str, char delim);
63 StatusCode registerHistograms();
64 const std::string histoSuffix(const int bec, const int layer);
65
66 private:
67 ServiceHandle <ITHistSvc> m_tHistSvc{this, "THistSvc", "THistSvc/THistSvc"};
68 SG::ReadHandleKey<PixelRDO_Container> m_pixelRDOKey{this,"PixelRDOKey","PixelRDOs","StoreGate Key of Pixel RDOs"};
69
71 const PixelID *m_pixelID=nullptr;
72
73 // vector of modulename and vector(barrel/endcap, layer, phi, eta)
74 std::vector< std::pair< std::string, std::vector<int> > > m_pixelMapping;
75
76 double m_nEvents=0;
77 std::vector<double> m_nEventsLB; // Events per LB
78 std::vector<double> m_nEventsLBCategory; // Events per certain LB for LB category
79
80 std::unique_ptr<TH1F> m_nEventsHist;
81 std::unique_ptr<TH1F> m_nEventsLBHist;
82 std::vector<std::unique_ptr<TH2F>> m_occupancyMaps;
83 std::vector<std::unique_ptr<TH2F>> m_occupancyMapsIBL2dLB;
84 std::vector<std::unique_ptr<TH1F>> m_TOTdistributions;
85 std::vector<std::unique_ptr<TH1F>> m_TOTdistributionsIBL2dLB;
86 std::vector<std::unique_ptr<TH1F>> m_occupancyLB;
87
88 Gaudi::Property<int> m_hist_lbMax{this,"nLBmax", 3001, "Maximum number of LB (for histograms binning)"}; // max number of LB
89 Gaudi::Property<int> m_evt_lbMin{this,"LBMin",0,"First lumi block to consider"}; // lower limit for LB to be taken into account
90 Gaudi::Property<int> m_evt_lbMax{this,"LBMax",-1,"Last lumi block to consider"}; // upper limit for LB to be taken into account
91
92 int m_LBrange_max = -9999;
93
94 const unsigned int m_nIblFes = 14 * (4 + 6*2) * 2; // 14 stave * (4 3Ds + 6 2Ds * 2 Fes) * 2 sides = 448
95 const int m_perLB_min=0, m_perLB_max=3000, m_perLB_step=100; // For plots per certain LBs
96 const int m_perLB_n = (m_perLB_max-m_perLB_min)/m_perLB_step; // For plots per certain LBs
97
98 const int m_fei4bPixels = 26880; // 80 * 336
99 const int m_pixModPixels = 46080; // 144 * 320;
100};
101
102
103#endif // PIXELCONDITIONSALGS_HITMAPBUILDER_H
Property holding a SG store/key/clid from which a ReadHandle is made.
AthAlgorithm(const std::string &name, ISvcLocator *pSvcLocator)
Constructor with parameters:
HitMapBuilder.h.
std::vector< std::unique_ptr< TH1F > > m_occupancyLB
const std::string histoSuffix(const int bec, const int layer)
Gaudi::Property< int > m_evt_lbMax
const PixelID * m_pixelID
const int m_pixModPixels
SG::ReadHandleKey< PixelRDO_Container > m_pixelRDOKey
StatusCode registerHistograms()
std::string getDCSIDFromPosition(int bec, int layer, int modPhi, int modEta)
std::vector< std::unique_ptr< TH1F > > m_TOTdistributions
std::vector< std::unique_ptr< TH2F > > m_occupancyMapsIBL2dLB
StatusCode execute()
const int m_perLB_step
std::vector< std::pair< std::string, std::vector< int > > > m_pixelMapping
std::vector< double > m_nEventsLB
StatusCode finalize()
const int m_perLB_n
const int m_perLB_max
Gaudi::Property< int > m_evt_lbMin
ServiceHandle< ITHistSvc > m_tHistSvc
StatusCode initialize()
std::unique_ptr< TH1F > m_nEventsLBHist
std::vector< std::unique_ptr< TH1F > > m_TOTdistributionsIBL2dLB
const InDetDD::PixelDetectorManager * m_pixman
const int m_perLB_min
AthAlgorithm(const std::string &name, ISvcLocator *pSvcLocator)
Constructor with parameters:
std::vector< std::unique_ptr< TH2F > > m_occupancyMaps
std::unique_ptr< TH1F > m_nEventsHist
const int m_fei4bPixels
std::vector< double > m_nEventsLBCategory
Gaudi::Property< int > m_hist_lbMax
std::vector< std::string > & splitter(const std::string &str, char delim, std::vector< std::string > &elems)
const unsigned int m_nIblFes
Dedicated detector manager extending the functionality of the SiDetectorManager with dedicated pixel ...
This is an Identifier helper class for the Pixel subdetector.
Definition PixelID.h:67
Property holding a SG store/key/clid from which a ReadHandle is made.
Message Stream Member.