test
CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
SiStripDigitizer.h
Go to the documentation of this file.
1 #ifndef SiStripDigitizer_h
2 #define SiStripDigitizer_h
3 
4 #include <map>
5 #include <memory>
6 #include <string>
7 #include <vector>
8 
11 
12 class TrackerTopology;
13 
14 namespace CLHEP {
15  class HepRandomEngine;
16 }
17 
18 namespace edm {
19  class ConsumesCollector;
20  namespace one {
21  class EDProducerBase;
22  }
23  class Event;
24  class EventSetup;
25  class ParameterSet;
26  template<typename T> class Handle;
27  class StreamID;
28 }
29 
30 class MagneticField;
32 class PSimHit;
34 class StripGeomDetUnit;
35 class TrackerGeometry;
36 
46 public:
48 
49  virtual ~SiStripDigitizer();
50 
51  virtual void initializeEvent(edm::Event const& e, edm::EventSetup const& c) override;
52  virtual void accumulate(edm::Event const& e, edm::EventSetup const& c) override;
53  virtual void accumulate(PileUpEventPrincipal const& e, edm::EventSetup const& c, edm::StreamID const&) override;
54  virtual void finalizeEvent(edm::Event& e, edm::EventSetup const& c) override;
55 
56 private:
57  void accumulateStripHits(edm::Handle<std::vector<PSimHit> >, const TrackerTopology *tTopo, size_t globalSimHitIndex, const unsigned int tofBin, CLHEP::HepRandomEngine*);
58  CLHEP::HepRandomEngine* randomEngine(edm::StreamID const& streamID);
59 
60  typedef std::vector<std::string> vstring;
61  typedef std::map<unsigned int, std::vector<std::pair<const PSimHit*, int> >,std::less<unsigned int> > simhit_map;
62  typedef simhit_map::iterator simhit_map_iterator;
63 
72  const bool useConfFromDB;
73  const bool zeroSuppression;
74  const bool makeDigiSimLinks_;
75 
83  std::map<std::string,size_t> crossingSimHitIndexOffset_;
84 
85  std::unique_ptr<SiStripDigitizerAlgorithm> theDigiAlgo;
86  std::map<uint32_t, std::vector<int> > theDetIdList;
89  std::map<unsigned int, StripGeomDetUnit const *> detectorUnits;
90  std::vector<CLHEP::HepRandomEngine*> randomEngines_;
91 };
92 
93 #endif
const vstring trackerContainers
const std::string ZSDigi
void accumulateStripHits(edm::Handle< std::vector< PSimHit > >, const TrackerTopology *tTopo, size_t globalSimHitIndex, const unsigned int tofBin, CLHEP::HepRandomEngine *)
edm::ESHandle< TrackerGeometry > pDD
const bool zeroSuppression
virtual void initializeEvent(edm::Event const &e, edm::EventSetup const &c) override
const std::string hitsProducer
virtual void finalizeEvent(edm::Event &e, edm::EventSetup const &c) override
virtual void accumulate(edm::Event const &e, edm::EventSetup const &c) override
const bool useConfFromDB
std::map< uint32_t, std::vector< int > > theDetIdList
virtual ~SiStripDigitizer()
std::map< std::string, size_t > crossingSimHitIndexOffset_
Offset to add to the index of each sim hit to account for which crossing it&#39;s in. ...
CLHEP::HepRandomEngine * randomEngine(edm::StreamID const &streamID)
simhit_map::iterator simhit_map_iterator
Accumulator to perform digitisation on the strip tracker sim hits.
SiStripDigitizer(const edm::ParameterSet &conf, edm::one::EDProducerBase &mixMod, edm::ConsumesCollector &iC)
tuple conf
Definition: dbtoconf.py:185
std::unique_ptr< SiStripDigitizerAlgorithm > theDigiAlgo
edm::ESHandle< MagneticField > pSetup
const std::string VRDigi
const std::string PRDigi
const std::string geometryType
std::vector< std::string > vstring
const bool makeDigiSimLinks_
Whether or not to create the association to sim truth collection. Set in configuration.
std::map< unsigned int, std::vector< std::pair< const PSimHit *, int > >, std::less< unsigned int > > simhit_map
const std::string gainLabel
std::map< unsigned int, StripGeomDetUnit const * > detectorUnits
const std::string SCDigi
std::vector< CLHEP::HepRandomEngine * > randomEngines_