CMS 3D CMS Logo

SiStripGainCosmicCalculator.h
Go to the documentation of this file.
1 #ifndef CalibTracker_SiStripChannelGain_SiStripGainCosmicCalculator_h
2 #define CalibTracker_SiStripChannelGain_SiStripGainCosmicCalculator_h
3 // -*- C++ -*-
4 // Package: SiStripApvGainCalculator
5 // Class: SiStripApvGainCalculator
10 // Original Author: Dorian Kcira, Pierre Rodeghiero
11 // Created: Mon Nov 20 10:04:31 CET 2006
14 #include <vector>
15 #include "TF1.h"
16 #include "TH1F.h"
17 #include "TObjArray.h"
18 #include "TFile.h"
19 #include "TString.h"
20 #include <fstream>
21 #include <sstream>
22 #include <memory>
23 
24 class TrackerTopology;
25 class SiStripDetCabling;
26 class TrackerGeometry;
27 
28 class SiStripGainCosmicCalculator : public ConditionDBWriter<SiStripApvGain> {
29 public:
32 
33 private:
34  void algoAnalyze(const edm::Event&, const edm::EventSetup&) override;
35  void algoBeginJob(const edm::EventSetup&) override;
36  void algoEndJob() override;
37  std::unique_ptr<SiStripApvGain> getNewObject() override;
38 
39 private:
40  std::pair<double, double> getPeakOfLandau(TH1F* inputHisto);
41  double moduleWidth(const uint32_t detid);
42  double moduleThickness(const uint32_t detid);
43 
44 private:
47  //
48  TObjArray* HlistAPVPairs;
49  TObjArray* HlistOtherHistos;
52  std::map<uint32_t, double> thickness_map; // map of detector id to respective thickness
53  std::vector<uint32_t> SelectedDetIds;
54  std::vector<uint32_t> detModulesToBeExcluded;
56  TrackerGeometry const* tkGeom = nullptr;
57  unsigned int MinNrEntries;
60  TString outputFileName;
63 };
64 #endif
SiStripGainCosmicCalculator::algoEndJob
void algoEndJob() override
Definition: SiStripGainCosmicCalculator.cc:72
SiStripGainCosmicCalculator::getNewObject
std::unique_ptr< SiStripApvGain > getNewObject() override
Definition: SiStripGainCosmicCalculator.cc:317
TrackerTopology
Definition: TrackerTopology.h:16
SiStripGainCosmicCalculator::tkGeom
TrackerGeometry const * tkGeom
Definition: SiStripGainCosmicCalculator.h:56
SiStripGainCosmicCalculator
Definition: SiStripGainCosmicCalculator.h:28
SiStripGainCosmicCalculator::algoBeginJob
void algoBeginJob(const edm::EventSetup &) override
Definition: SiStripGainCosmicCalculator.cc:74
SiStripGainCosmicCalculator::thickness_map
std::map< uint32_t, double > thickness_map
Definition: SiStripGainCosmicCalculator.h:52
SiStripGainCosmicCalculator::HlistAPVPairs
TObjArray * HlistAPVPairs
Definition: SiStripGainCosmicCalculator.h:48
SiStripGainCosmicCalculator::ExpectedChargeDeposition
double ExpectedChargeDeposition
Definition: SiStripGainCosmicCalculator.h:51
SiStripGainCosmicCalculator::printdebug_
bool printdebug_
Definition: SiStripGainCosmicCalculator.h:61
SiStripGainCosmicCalculator::total_nr_of_events
uint32_t total_nr_of_events
Definition: SiStripGainCosmicCalculator.h:50
SiStripGainCosmicCalculator::moduleThickness
double moduleThickness(const uint32_t detid)
Definition: SiStripGainCosmicCalculator.cc:304
SiStripGainCosmicCalculator::siStripDetCabling
SiStripDetCabling const * siStripDetCabling
Definition: SiStripGainCosmicCalculator.h:55
SiStripGainCosmicCalculator::getPeakOfLandau
std::pair< double, double > getPeakOfLandau(TH1F *inputHisto)
Definition: SiStripGainCosmicCalculator.cc:243
ConditionDBWriter
Definition: ConditionDBWriter.h:149
SiStripGainCosmicCalculator::SiStripGainCosmicCalculator
SiStripGainCosmicCalculator(const edm::ParameterSet &)
Definition: SiStripGainCosmicCalculator.cc:37
SiStripDetCabling
Definition: SiStripDetCabling.h:21
SiStripApvGain.h
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
SiStripGainCosmicCalculator::MinNrEntries
unsigned int MinNrEntries
Definition: SiStripGainCosmicCalculator.h:57
SiStripGainCosmicCalculator::TrackLabel
std::string TrackLabel
Definition: SiStripGainCosmicCalculator.h:46
edm::ParameterSet
Definition: ParameterSet.h:36
SiStripGainCosmicCalculator::~SiStripGainCosmicCalculator
~SiStripGainCosmicCalculator() override
Definition: SiStripGainCosmicCalculator.cc:68
edm::EventSetup
Definition: EventSetup.h:57
SiStripGainCosmicCalculator::SelectedDetIds
std::vector< uint32_t > SelectedDetIds
Definition: SiStripGainCosmicCalculator.h:53
SiStripGainCosmicCalculator::detModulesToBeExcluded
std::vector< uint32_t > detModulesToBeExcluded
Definition: SiStripGainCosmicCalculator.h:54
ConditionDBWriter.h
SiStripGainCosmicCalculator::tTopo
const TrackerTopology * tTopo
Definition: SiStripGainCosmicCalculator.h:62
SiStripGainCosmicCalculator::outputHistogramsInRootFile
bool outputHistogramsInRootFile
Definition: SiStripGainCosmicCalculator.h:59
SiStripGainCosmicCalculator::MaxChi2OverNDF
double MaxChi2OverNDF
Definition: SiStripGainCosmicCalculator.h:58
SiStripGainCosmicCalculator::TrackProducer
std::string TrackProducer
Definition: SiStripGainCosmicCalculator.h:45
SiStripGainCosmicCalculator::algoAnalyze
void algoAnalyze(const edm::Event &, const edm::EventSetup &) override
Definition: SiStripGainCosmicCalculator.cc:175
SiStripGainCosmicCalculator::outputFileName
TString outputFileName
Definition: SiStripGainCosmicCalculator.h:60
edm::Event
Definition: Event.h:73
SiStripGainCosmicCalculator::moduleWidth
double moduleWidth(const uint32_t detid)
Definition: SiStripGainCosmicCalculator.cc:291
SiStripGainCosmicCalculator::HlistOtherHistos
TObjArray * HlistOtherHistos
Definition: SiStripGainCosmicCalculator.h:49
TrackerGeometry
Definition: TrackerGeometry.h:14