CMS 3D CMS Logo

GlobalMuonRefitter.h
Go to the documentation of this file.
1 #ifndef RecoMuon_GlobalTrackingTools_GlobalMuonRefitter_H
2 #define RecoMuon_GlobalTrackingTools_GlobalMuonRefitter_H
3 
34 #include "DynamicTruncation.h"
35 
36 namespace reco {
37  class TransientTrack;
38 }
39 
41 class TrackerTopology;
42 
44 class MuonServiceProxy;
45 class Trajectory;
46 
47 class TrajectoryFitter;
50 
52 public:
57 
62 
63  typedef std::vector<Trajectory> TC;
64  typedef TC::const_iterator TI;
65 
66  enum subDetector { PXB = 1, PXF = 2, TIB = 3, TID = 4, TOB = 5, TEC = 6 };
67 
68 public:
71 
73  virtual ~GlobalMuonRefitter();
74 
76  virtual void setEvent(const edm::Event&);
77 
79  void setServices(const edm::EventSetup&);
80 
82  std::vector<Trajectory> refit(const reco::Track& globalTrack,
83  const int theMuonHitsOption,
84  const TrackerTopology* tTopo) const;
85 
87  std::vector<Trajectory> refit(const reco::Track& globalTrack,
90  const int theMuonHitsOption,
91  const TrackerTopology* tTopo) const;
92 
94  std::vector<Trajectory> transform(const reco::Track& newTrack,
96  const TransientTrackingRecHit::ConstRecHitContainer& recHitsForReFit) const;
97 
98  // get rid of selected station RecHits
100 
101  // return DYT-related informations
102  const reco::DYTInfo* getDYTInfo() { return dytInfo; }
103 
104 protected:
106 
108  void checkMuonHits(const reco::Track&, ConstRecHitContainer&, std::map<DetId, int>&) const;
109 
112 
114  ConstRecHitContainer selectMuonHits(const Trajectory&, const std::map<DetId, int>&) const;
115 
117  void printHits(const ConstRecHitContainer&) const;
118 
120 
121  const MuonServiceProxy* service() const { return theService; }
122 
123 protected:
126  float thePtCut;
127 
128 private:
130  float theProbCut;
138 
151 
155 
156  unsigned long long theCacheId_TRH;
157 
159 
161 
163 
165 
166  std::vector<int> theDYTthrs;
173 
175  std::unique_ptr<TrajectoryFitter> theFitter;
176 
180 
183 
190 
192 };
193 #endif
DynamicTruncation::Config theDynamicTruncationConfig
edm::Handle< DTRecHitCollection > theDTRecHits
const reco::DYTInfo * getDYTInfo()
MuonTransientTrackingRecHit::MuonRecHitPointer MuonRecHitPointer
TransientTrackingRecHit::RecHitPointer RecHitPointer
edm::ESGetToken< TransientTrackingRecHitBuilder, TransientRecHitRecord > theMuonRecHitBuilderToken
MuonTransientTrackingRecHit::ConstMuonRecHitPointer ConstMuonRecHitPointer
const MuonServiceProxy * theService
RefitDirection theRefitDirection
edm::Handle< CSCSegmentCollection > CSCSegments
std::string thePropagatorName
edm::Handle< GEMRecHitCollection > theGEMRecHits
std::vector< ConstRecHitPointer > RecHitContainer
void setServices(const edm::EventSetup &)
set the services needed by the TrackTransformer
TransientTrackingRecHit::ConstRecHitContainer ConstRecHitContainer
edm::EDGetTokenT< CSCSegmentCollection > CSCSegmentsToken
void printHits(const ConstRecHitContainer &) const
print all RecHits of a trajectory
TransientTrackingRecHit::ConstRecHitPointer ConstRecHitPointer
std::unique_ptr< TrajectoryFitter > theFitter
edm::Handle< ME0SegmentCollection > theME0RecHits
std::vector< int > theDYTthrs
edm::ESGetToken< TransientTrackingRecHitBuilder, TransientRecHitRecord > theTrackerRecHitBuilderToken
TC::const_iterator TI
edm::Handle< DTRecSegment4DCollection > all4DSegments
const TransientTrackingRecHitBuilder * theMuonRecHitBuilder
std::shared_ptr< MuonTransientTrackingRecHit > MuonRecHitPointer
std::shared_ptr< TrackingRecHit const > ConstRecHitPointer
const TransientTrackingRecHitBuilder * theTrackerRecHitBuilder
ConstRecHitContainer selectMuonHits(const Trajectory &, const std::map< DetId, int > &) const
select muon hits compatible with trajectory; check hits in chambers with showers
MuonTransientTrackingRecHit::MuonRecHitContainer MuonRecHitContainer
std::vector< Trajectory > TC
edm::EDGetTokenT< ME0SegmentCollection > theME0RecHitToken
edm::ParameterSet theDYTthrsParameters
edm::Handle< CSCRecHit2DCollection > theCSCRecHits
edm::EDGetTokenT< DTRecHitCollection > theDTRecHitToken
edm::EDGetTokenT< CSCRecHit2DCollection > theCSCRecHitToken
std::shared_ptr< TrackingRecHit const > RecHitPointer
std::vector< Trajectory > transform(const reco::Track &newTrack, const reco::TransientTrack track, const TransientTrackingRecHit::ConstRecHitContainer &recHitsForReFit) const
refit the track with a new set of RecHits
edm::InputTag theDTRecHitLabel
std::vector< ConstMuonRecHitPointer > ConstMuonRecHitContainer
std::vector< ConstRecHitPointer > ConstRecHitContainer
const edm::EventSetup * theEventSetup
edm::InputTag theGEMRecHitLabel
virtual void setEvent(const edm::Event &)
pass the Event to the algo at each event
RefitDirection checkRecHitsOrdering(const ConstRecHitContainer &) const
edm::ESGetToken< TrajectoryFitter, TrajectoryFitterRecord > theFitterToken
edm::InputTag theME0RecHitLabel
GlobalMuonRefitter(const edm::ParameterSet &, const MuonServiceProxy *, edm::ConsumesCollector &)
constructor with Parameter Set and MuonServiceProxy
edm::EDGetTokenT< DTRecSegment4DCollection > all4DSegmentsToken
ConstRecHitContainer getRidOfSelectStationHits(const ConstRecHitContainer &hits, const TrackerTopology *tTopo) const
reco::DYTInfo * dytInfo
TransientTrackingRecHit::RecHitContainer RecHitContainer
fixed size matrix
TransientTrackingRecHit::ConstRecHitContainer ConstRecHitContainer
void getFirstHits(const reco::Track &, ConstRecHitContainer &, ConstRecHitContainer &) const
get the RecHits in the tracker and the first muon chamber with hits
std::vector< Trajectory > refit(const reco::Track &globalTrack, const int theMuonHitsOption, const TrackerTopology *tTopo) const
build combined trajectory from sta Track and tracker RecHits
MuonTransientTrackingRecHit::ConstMuonRecHitContainer ConstMuonRecHitContainer
virtual ~GlobalMuonRefitter()
destructor
const MuonServiceProxy * service() const
std::shared_ptr< MuonTransientTrackingRecHit const > ConstMuonRecHitPointer
unsigned long long theCacheId_TRH
std::vector< MuonRecHitPointer > MuonRecHitContainer
edm::InputTag theCSCRecHitLabel
void checkMuonHits(const reco::Track &, ConstRecHitContainer &, std::map< DetId, int > &) const
check muon RecHits, calculate chamber occupancy and select hits to be used in the final fit ...
edm::EDGetTokenT< GEMRecHitCollection > theGEMRecHitToken