CMS 3D CMS Logo

MuonPathAnalyzerInChamber.h
Go to the documentation of this file.
1 #ifndef L1Trigger_DTTriggerPhase2_MuonPathAnalyzerInChamber_h
2 #define L1Trigger_DTTriggerPhase2_MuonPathAnalyzerInChamber_h
3 
5 
6 // ===============================================================================
7 // Previous definitions and declarations
8 // ===============================================================================
9 namespace {
10  typedef std::array<cmsdt::LATERAL_CASES, cmsdt::NUM_LAYERS_2SL> TLateralities;
11 } // namespace
12 // ===============================================================================
13 // Class declarations
14 // ===============================================================================
15 
17 public:
18  // Constructors and destructor
21  std::shared_ptr<GlobalCoordsObtainer> &globalcoordsobtainer);
22  ~MuonPathAnalyzerInChamber() override;
23 
24  // Main methods
25  void initialise(const edm::EventSetup &iEventSetup) override;
27  const edm::EventSetup &iEventSetup,
28  MuonPathPtrs &inMpath,
29  std::vector<cmsdt::metaPrimitive> &metaPrimitives) override{};
30  void run(edm::Event &iEvent,
31  const edm::EventSetup &iEventSetup,
32  MuonPathPtrs &inMpath,
33  MuonPathPtrs &outMPath) override;
34 
35  void finish() override;
36 
37  // Other public methods
38  void setBxTolerance(int t) { bxTolerance_ = t; };
39  void setMinHits4Fit(int h) { minHits4Fit_ = h; };
40  void setChiSquareThreshold(float ch2Thr) { chiSquareThreshold_ = ch2Thr; };
42  if (minQuality_ >= cmsdt::LOWQ)
43  minQuality_ = q;
44  };
45 
46  int bxTolerance(void) { return bxTolerance_; };
47  int minHits4Fit(void) { return minHits4Fit_; };
49 
50  bool hasPosRF(int wh, int sec) { return wh > 0 || (wh == 0 && sec % 4 > 1); };
51 
52  // Public attributes
53  DTGeometry const *dtGeo_;
55 
56  //shift
57  std::map<int, float> shiftinfo_;
58 
59 private:
60  // Private methods
61  void analyze(MuonPathPtr &inMPath, MuonPathPtrs &outMPaths);
62 
63  void setCellLayout(MuonPathPtr &mpath);
64  void buildLateralities(MuonPathPtr &mpath);
65  void setLateralitiesInMP(MuonPathPtr &mpath, TLateralities lat);
68  TLateralities lat,
69  int present_layer[cmsdt::NUM_LAYERS_2SL],
70  int &lat_added);
71 
72  void evaluateQuality(MuonPathPtr &mPath);
74  std::vector<TLateralities> lateralities_;
75  std::vector<cmsdt::LATQ_TYPE> latQuality_;
76 
77  const bool debug_;
78  double chi2Th_;
83  short minHits4Fit_;
86 
87  // global coordinates
88  std::shared_ptr<GlobalCoordsObtainer> globalcoordsobtainer_;
89 };
90 
91 #endif
void setChiSquareThreshold(float ch2Thr)
MuonPathAnalyzerInChamber(const edm::ParameterSet &pset, edm::ConsumesCollector &iC, std::shared_ptr< GlobalCoordsObtainer > &globalcoordsobtainer)
void setCellLayout(MuonPathPtr &mpath)
std::vector< MuonPathPtr > MuonPathPtrs
Definition: MuonPath.h:128
void setWirePosAndTimeInMP(MuonPathPtr &mpath)
edm::ESGetToken< DTGeometry, MuonGeometryRecord > dtGeomH
void evaluateQuality(MuonPathPtr &mPath)
int iEvent
Definition: GenABIO.cc:224
void buildLateralities(MuonPathPtr &mpath)
void setLateralitiesInMP(MuonPathPtr &mpath, TLateralities lat)
std::map< int, float > shiftinfo_
void initialise(const edm::EventSetup &iEventSetup) override
std::vector< TLateralities > lateralities_
MP_QUALITY
Definition: constants.h:42
void calculateFitParameters(MuonPathPtr &mpath, TLateralities lat, int present_layer[cmsdt::NUM_LAYERS_2SL], int &lat_added)
cmsdt::MP_QUALITY minQuality(void)
constexpr int NUM_LAYERS_2SL
Definition: constants.h:254
std::vector< cmsdt::LATQ_TYPE > latQuality_
void analyze(MuonPathPtr &inMPath, MuonPathPtrs &outMPaths)
std::shared_ptr< MuonPath > MuonPathPtr
Definition: MuonPath.h:127
std::shared_ptr< GlobalCoordsObtainer > globalcoordsobtainer_
void setMinimumQuality(cmsdt::MP_QUALITY q)
The Signals That Services Can Subscribe To This is based on ActivityRegistry h
Helper function to determine trigger accepts.
Definition: Activities.doc:4
void run(edm::Event &iEvent, const edm::EventSetup &iEventSetup, MuonPathPtrs &inMpath, std::vector< cmsdt::metaPrimitive > &metaPrimitives) override
int cellLayout_[cmsdt::NUM_LAYERS_2SL]