CMS 3D CMS Logo

DTResidualCalibration.h
Go to the documentation of this file.
1 #ifndef CalibMuon_DTCalibration_DTResidualCalibration_h
2 #define CalibMuon_DTCalibration_DTResidualCalibration_h
3 
14 
16 
17 #include <string>
18 #include <vector>
19 #include <map>
20 
21 class TFile;
22 class TH1F;
23 class TH2F;
24 class DTGeometry;
25 class DTSuperLayerId;
26 class DTLayerId;
27 
29  public:
33  virtual ~DTResidualCalibration();
34 
35  void beginJob();
36  void beginRun(const edm::Run&, const edm::EventSetup&);
37  void endJob();
38  void analyze(const edm::Event& event, const edm::EventSetup& setup);
39 
40  protected:
41 
42  private:
43  float segmentToWireDistance(const DTRecHit1D& recHit1D, const DTRecSegment4D& segment);
44  // Book a set of histograms for a given super-layer/layer
45  void bookHistos(DTSuperLayerId slId);
46  void bookHistos(DTLayerId slId);
47  // Fill a set of histograms for a given super-layer/layer
48  void fillHistos(DTSuperLayerId slId, float distance, float residualOnDistance);
49  void fillHistos(DTLayerId slId, float distance, float residualOnDistance);
50 
54 
56  TFile* rootFile_;
57  // Geometry
59  // Histograms per super-layer
60  std::map<DTSuperLayerId, std::vector<TH1F*> > histoMapTH1F_;
61  std::map<DTSuperLayerId, std::vector<TH2F*> > histoMapTH2F_;
62  // Histograms per layer
63  std::map<DTLayerId, std::vector<TH1F*> > histoMapPerLayerTH1F_;
64  std::map<DTLayerId, std::vector<TH2F*> > histoMapPerLayerTH2F_;
65 };
66 #endif
void fillHistos(DTSuperLayerId slId, float distance, float residualOnDistance)
void bookHistos(DTSuperLayerId slId)
std::map< DTLayerId, std::vector< TH1F * > > histoMapPerLayerTH1F_
DTResidualCalibration(const edm::ParameterSet &pset)
Constructor.
virtual ~DTResidualCalibration()
Destructor.
def setup(process, global_tag, zero_tesla=False)
Definition: GeneralSetup.py:1
void analyze(const edm::Event &event, const edm::EventSetup &setup)
void beginRun(const edm::Run &, const edm::EventSetup &)
std::map< DTSuperLayerId, std::vector< TH1F * > > histoMapTH1F_
std::map< DTLayerId, std::vector< TH2F * > > histoMapPerLayerTH2F_
std::map< DTSuperLayerId, std::vector< TH2F * > > histoMapTH2F_
const DTGeometry * dtGeom_
float segmentToWireDistance(const DTRecHit1D &recHit1D, const DTRecSegment4D &segment)
Definition: event.py:1
Definition: Run.h:42