CMS 3D CMS Logo

MuonShowerInformationFiller.h
Go to the documentation of this file.
1 
12 #ifndef MuonIdentification_MuonShowerInformationFiller_h
13 #define MuonIdentification_MuonShowerInformationFiller_h
14 
15 #include <vector>
16 
19 
34 
37 
39 
41 
42 namespace edm {
43  class ParameterSet;
44  class Event;
45  class EventSetup;
46 } // namespace edm
47 namespace reco {
48  class TransientTrack;
49  struct MuonShower;
50 } // namespace reco
51 
52 class MuonServiceProxy;
53 class Trajectory;
54 class Cylinder;
55 class Disk;
56 class BarrelDetLayer;
57 class ForwardDetLayer;
65 class MuonGeometryRecord;
67 
69 public:
73 
74 public:
78 
81 
84 
86  virtual void setEvent(const edm::Event&);
87 
89  void setServices(const edm::EventSetup&);
90 
91  //set the data members
92  void fillHitsByStation(const reco::Muon&);
93 
94 protected:
95  const MuonServiceProxy* getService() const { return theService; }
96 
97 private:
98  std::vector<float> theStationShowerDeltaR;
99  std::vector<float> theStationShowerTSize;
100  std::vector<int> theAllStationHits;
101  std::vector<int> theCorrelatedStationHits;
102 
104 
105  GlobalPoint crossingPoint(const GlobalPoint&, const GlobalPoint&, const BarrelDetLayer*) const;
106  GlobalPoint crossingPoint(const GlobalPoint&, const GlobalPoint&, const Cylinder&) const;
107  GlobalPoint crossingPoint(const GlobalPoint&, const GlobalPoint&, const ForwardDetLayer*) const;
108  GlobalPoint crossingPoint(const GlobalPoint&, const GlobalPoint&, const Disk&) const;
109  std::vector<const GeomDet*> dtPositionToDets(const GlobalPoint&) const;
110  std::vector<const GeomDet*> cscPositionToDets(const GlobalPoint&) const;
113  const GlobalPoint&) const;
117  std::vector<const GeomDet*> getCompatibleDets(const reco::Track&) const;
118 
119  struct LessMag {
121  bool operator()(const GlobalPoint& lhs, const GlobalPoint& rhs) const {
122  return (lhs - thePoint).mag() < (rhs - thePoint).mag();
123  }
126  return (lhs->globalPosition() - thePoint).mag() < (rhs->globalPosition() - thePoint).mag();
127  }
129  };
130 
131  struct LessDPhi {
135  return deltaPhi(lhs->globalPosition().barePhi(), thePoint.barePhi()) <
136  deltaPhi(rhs->globalPosition().barePhi(), thePoint.barePhi());
137  }
139  };
140 
141  struct AbsLessDPhi {
145  return (fabs(deltaPhi(lhs->globalPosition().barePhi(), thePoint.barePhi())) <
146  fabs(deltaPhi(rhs->globalPosition().barePhi(), thePoint.barePhi())));
147  }
149  };
150 
151  struct AbsLessDTheta {
155  return (fabs(lhs->globalPosition().bareTheta() - thePoint.bareTheta()) <
156  fabs(rhs->globalPosition().bareTheta() - thePoint.bareTheta()));
157  }
159  };
160 
161  struct LessPhi {
162  LessPhi() : thePoint(0, 0, 0) {}
165  return (lhs->globalPosition().barePhi() < rhs->globalPosition().barePhi());
166  }
168  };
169 
170  struct LessPerp {
171  LessPerp() : thePoint(0, 0, 0) {}
174  return (lhs->globalPosition().perp() < rhs->globalPosition().perp());
175  }
177  };
178 
179  struct LessAbsMag {
180  LessAbsMag() : thePoint(0, 0, 0) {}
183  return (lhs->globalPosition().mag() < rhs->globalPosition().mag());
184  }
186  };
187 
189 
190  unsigned long long theCacheId_TRH;
191  unsigned long long theCacheId_MT;
192 
195 
198 
203 
208 
213 
214  // geometry
220 
226 };
227 #endif
MuonTransientTrackingRecHit::MuonRecHitContainer MuonRecHitContainer
std::vector< const GeomDet * > cscPositionToDets(const GlobalPoint &) const
TransientTrackingRecHit::ConstRecHitContainer findThetaCluster(TransientTrackingRecHit::ConstRecHitContainer &, const GlobalPoint &) const
virtual void setEvent(const edm::Event &)
pass the Event to the algorithm at each event
edm::ESGetToken< CSCGeometry, MuonGeometryRecord > theCSCGeometryToken
bool operator()(const MuonTransientTrackingRecHit::MuonRecHitPointer &lhs, const MuonTransientTrackingRecHit::MuonRecHitPointer &rhs) const
edm::ESHandle< MagneticField > theField
bool operator()(const GlobalPoint &lhs, const GlobalPoint &rhs) const
reco::MuonShower fillShowerInformation(const reco::Muon &muon, const edm::Event &, const edm::EventSetup &)
fill muon shower variables
void setServices(const edm::EventSetup &)
set the services needed
bool operator()(const MuonTransientTrackingRecHit::MuonRecHitPointer &lhs, const MuonTransientTrackingRecHit::MuonRecHitPointer &rhs) const
TransientTrackingRecHit::ConstRecHitContainer hitsFromSegments(const GeomDet *, edm::Handle< DTRecSegment4DCollection >, edm::Handle< CSCSegmentCollection >) const
bool operator()(const MuonTransientTrackingRecHit::MuonRecHitPointer &lhs, const MuonTransientTrackingRecHit::MuonRecHitPointer &rhs) const
edm::ESGetToken< TransientTrackingRecHitBuilder, TransientRecHitRecord > theMuonRecHitBuilderToken
edm::EDGetTokenT< CSCSegmentCollection > theCSCSegmentsToken
edm::ESHandle< GeometricSearchTracker > theTracker
edm::ESHandle< CSCGeometry > theCSCGeometry
edm::ESHandle< DTGeometry > theDTGeometry
const MuonServiceProxy * getService() const
T bareTheta() const
Definition: PV3DBase.h:71
std::vector< const GeomDet * > getCompatibleDets(const reco::Track &) const
edm::EDGetTokenT< CSCRecHit2DCollection > theCSCRecHitToken
T barePhi() const
Definition: PV3DBase.h:65
virtual ~MuonShowerInformationFiller()
destructor
Definition: BoundDisk.h:19
edm::ESGetToken< GeometricSearchTracker, TrackerRecoGeometryRecord > theTrackerToken
bool operator()(const TransientTrackingRecHit::ConstRecHitPointer &lhs, const TransientTrackingRecHit::ConstRecHitPointer &rhs) const
void fillHitsByStation(const reco::Muon &)
std::shared_ptr< MuonTransientTrackingRecHit > MuonRecHitPointer
std::shared_ptr< TrackingRecHit const > ConstRecHitPointer
GlobalPoint crossingPoint(const GlobalPoint &, const GlobalPoint &, const BarrelDetLayer *) const
edm::Handle< DTRecHitCollection > theDTRecHits
edm::ESGetToken< DTGeometry, MuonGeometryRecord > theDTGeometryToken
edm::Handle< CSCSegmentCollection > theCSCSegments
edm::ESHandle< TransientTrackingRecHitBuilder > theTrackerRecHitBuilder
std::vector< ConstRecHitPointer > ConstRecHitContainer
edm::ESGetToken< MagneticField, IdealMagneticFieldRecord > theFieldToken
T mag() const
The vector magnitude. Equivalent to sqrt(vec.mag2())
edm::EDGetTokenT< DTRecSegment4DCollection > theDT4DRecSegmentToken
TransientTrackingRecHit::ConstRecHitContainer ConstRecHitContainer
edm::Handle< CSCRecHit2DCollection > theCSCRecHits
bool operator()(const MuonTransientTrackingRecHit::MuonRecHitPointer &lhs, const MuonTransientTrackingRecHit::MuonRecHitPointer &rhs) const
bool operator()(const MuonTransientTrackingRecHit::MuonRecHitPointer &lhs, const MuonTransientTrackingRecHit::MuonRecHitPointer &rhs) const
edm::ESGetToken< GlobalTrackingGeometry, GlobalTrackingGeometryRecord > theTrackingGeometryToken
MuonRecHitContainer findPerpCluster(MuonRecHitContainer &muonRecHits) const
edm::ESHandle< TransientTrackingRecHitBuilder > theMuonRecHitBuilder
fixed size matrix
HLT enums.
std::shared_ptr< MuonTransientTrackingRecHit const > ConstMuonRecHitPointer
edm::EDGetTokenT< DTRecHitCollection > theDTRecHitToken
edm::ESHandle< GlobalTrackingGeometry > theTrackingGeometry
std::vector< const GeomDet * > dtPositionToDets(const GlobalPoint &) const
edm::ESGetToken< TransientTrackingRecHitBuilder, TransientRecHitRecord > theTrackerRecHitBuilderToken
bool operator()(const MuonTransientTrackingRecHit::MuonRecHitPointer &lhs, const MuonTransientTrackingRecHit::MuonRecHitPointer &rhs) const
std::vector< MuonRecHitPointer > MuonRecHitContainer
MuonTransientTrackingRecHit::ConstMuonRecHitPointer ConstMuonRecHitPointer
*vegas h *****************************************************used in the default bin number in original ***version of VEGAS is ***a higher bin number might help to derive a more precise ***grade subtle point
Definition: invegas.h:5
edm::Handle< DTRecSegment4DCollection > theDT4DRecSegments