CMS 3D CMS Logo

List of all members | Classes | Public Types | Public Member Functions | Static Public Member Functions | Public Attributes | Static Private Attributes
ResidualRefitting Class Reference

#include <ResidualRefitting.h>

Inheritance diagram for ResidualRefitting:
edm::one::EDAnalyzer<> edm::one::EDAnalyzerBase edm::EDConsumerBase

Classes

struct  storage_event
 
struct  StorageHit
 
struct  StorageMuon
 
struct  StorageTrackExtrap
 
struct  StorageTrackHit
 

Public Types

typedef struct ResidualRefitting::StorageHit storage_hit
 
typedef struct ResidualRefitting::StorageMuon storage_muon
 
typedef struct ResidualRefitting::StorageTrackExtrap storage_trackExtrap
 
typedef struct ResidualRefitting::StorageTrackHit storage_trackHit
 
- Public Types inherited from edm::one::EDAnalyzerBase
typedef EDAnalyzerBase ModuleType
 
- Public Types inherited from edm::EDConsumerBase
typedef ProductLabels Labels
 

Public Member Functions

void analyze (const edm::Event &, const edm::EventSetup &) override
 
void beginJob () override
 
void branchMuon (ResidualRefitting::storage_muon &storageTmp, std::string branchName)
 
void branchTrackExtrap (ResidualRefitting::storage_trackExtrap &storageTmp, std::string branchName)
 
void CollectTrackHits (edm::Handle< reco::TrackCollection > trackColl, ResidualRefitting::storage_trackExtrap &trackExtrap, const edm::EventSetup &eventSetup)
 
void cylExtrapTrkSam (int recNum, reco::TrackRef track, ResidualRefitting::storage_trackExtrap &storage, double rho)
 
void dumpMuonRecHits (const ResidualRefitting::storage_hit &hit)
 
void dumpTrackExtrap (const ResidualRefitting::storage_trackExtrap &track)
 
void dumpTrackHits (const ResidualRefitting::storage_trackHit &hit)
 
void dumpTrackRef (reco::TrackRef muon, std::string str)
 
void endJob () override
 
FreeTrajectoryState freeTrajStateMuon (reco::TrackRef muon)
 
bool IsSameHit (TrackingRecHit const &hit1, TrackingRecHit const &hit2)
 
int MatchTrackWithRecHits (reco::TrackCollection::const_iterator trackIt, edm::Handle< reco::TrackCollection > ref)
 
void muonInfo (ResidualRefitting::storage_muon &storeMuon, reco::TrackRef muon, int val)
 
void NewTrackMeasurements (const edm::Handle< reco::TrackCollection > &trackCollOrig, const edm::Handle< reco::TrackCollection > &trackColl, ResidualRefitting::storage_trackExtrap &trackExtrap)
 
void omitStation (edm::Handle< reco::MuonCollection > funcMuons, edm::Handle< reco::TrackCollection >, ResidualRefitting::storage_muon &storeGmr, ResidualRefitting::storage_muon &storeSam, ResidualRefitting::storage_trackExtrap &storeExtrap, int omitStation)
 
void omitTrackerSystem (edm::Handle< reco::MuonCollection > trkMuons, ResidualRefitting::storage_muon &storeGmr, ResidualRefitting::storage_muon &storeTrk, ResidualRefitting::storage_trackExtrap &storeExtrap, int omitSystem)
 
 ResidualRefitting (const edm::ParameterSet &)
 
int ReturnSector (DetId detid)
 
int ReturnStation (DetId detid)
 
void StoreTrackerRecHits (DetId detid, const TrackerTopology *tTopo, int iTrack, int iRec)
 
void trkExtrap (const DetId &detid, int iTrkLink, int iTrk, int iRec, const FreeTrajectoryState &freeTrajState, const LocalPoint &recPoint, storage_trackExtrap &storeTemp)
 
void zero_muon (ResidualRefitting::storage_muon *str)
 
void zero_storage ()
 
void zero_trackExtrap (ResidualRefitting::storage_trackExtrap *str)
 
 ~ResidualRefitting () override
 
- Public Member Functions inherited from edm::one::EDAnalyzer<>
 EDAnalyzer ()=default
 
 EDAnalyzer (const EDAnalyzer &)=delete
 
SerialTaskQueueglobalLuminosityBlocksQueue () final
 
SerialTaskQueueglobalRunsQueue () final
 
const EDAnalyzeroperator= (const EDAnalyzer &)=delete
 
bool wantsGlobalLuminosityBlocks () const final
 
bool wantsGlobalRuns () const final
 
bool wantsInputProcessBlocks () const final
 
bool wantsProcessBlocks () const final
 
- Public Member Functions inherited from edm::one::EDAnalyzerBase
void callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func)
 
 EDAnalyzerBase ()
 
ModuleDescription const & moduleDescription () const
 
bool wantsStreamLuminosityBlocks () const
 
bool wantsStreamRuns () const
 
 ~EDAnalyzerBase () override
 
- Public Member Functions inherited from edm::EDConsumerBase
std::vector< ConsumesInfoconsumesInfo () const
 
void convertCurrentProcessAlias (std::string const &processName)
 Convert "@currentProcess" in InputTag process names to the actual current process name. More...
 
 EDConsumerBase ()
 
 EDConsumerBase (EDConsumerBase const &)=delete
 
 EDConsumerBase (EDConsumerBase &&)=default
 
ESResolverIndex const * esGetTokenIndices (edm::Transition iTrans) const
 
std::vector< ESResolverIndex > const & esGetTokenIndicesVector (edm::Transition iTrans) const
 
std::vector< ESRecordIndex > const & esGetTokenRecordIndicesVector (edm::Transition iTrans) const
 
ProductResolverIndexAndSkipBit indexFrom (EDGetToken, BranchType, TypeID const &) const
 
void itemsMayGet (BranchType, std::vector< ProductResolverIndexAndSkipBit > &) const
 
void itemsToGet (BranchType, std::vector< ProductResolverIndexAndSkipBit > &) const
 
std::vector< ProductResolverIndexAndSkipBit > const & itemsToGetFrom (BranchType iType) const
 
void labelsForToken (EDGetToken iToken, Labels &oLabels) const
 
void modulesWhoseProductsAreConsumed (std::array< std::vector< ModuleDescription const *> *, NumBranchTypes > &modulesAll, std::vector< ModuleProcessName > &modulesInPreviousProcesses, ProductRegistry const &preg, std::map< std::string, ModuleDescription const *> const &labelsToDesc, std::string const &processName) const
 
EDConsumerBase const & operator= (EDConsumerBase const &)=delete
 
EDConsumerBaseoperator= (EDConsumerBase &&)=default
 
bool registeredToConsume (ProductResolverIndex, bool, BranchType) const
 
void selectInputProcessBlocks (ProductRegistry const &productRegistry, ProcessBlockHelperBase const &processBlockHelperBase)
 
ProductResolverIndexAndSkipBit uncheckedIndexFrom (EDGetToken) const
 
void updateLookup (BranchType iBranchType, ProductResolverIndexHelper const &, bool iPrefetchMayGet)
 
void updateLookup (eventsetup::ESRecordsToProductResolverIndices const &)
 
virtual ~EDConsumerBase () noexcept(false)
 

Static Public Member Functions

static void fillDescriptions (edm::ConfigurationDescriptions &descriptions)
 
- Static Public Member Functions inherited from edm::one::EDAnalyzerBase
static const std::string & baseType ()
 
static void fillDescriptions (ConfigurationDescriptions &descriptions)
 
static void prevalidate (ConfigurationDescriptions &descriptions)
 

Public Attributes

const bool debug_
 
ResidualRefitting::storage_event eventInfo_
 
const edm::ESGetToken< MagneticField, IdealMagneticFieldRecordmagFieldToken_
 
const edm::InputTag muons_
 
const edm::EDGetTokenT< reco::TrackCollectionmuonsNoSt1Token_
 
const edm::EDGetTokenT< reco::TrackCollectionmuonsNoSt2Token_
 
const edm::EDGetTokenT< reco::TrackCollectionmuonsNoSt3Token_
 
const edm::EDGetTokenT< reco::TrackCollectionmuonsNoSt4Token_
 
const edm::InputTag muonsNoStation1_
 
const edm::InputTag muonsNoStation2_
 
const edm::InputTag muonsNoStation3_
 
const edm::InputTag muonsNoStation4_
 
const edm::InputTag muonsRemake_
 
const edm::EDGetTokenT< reco::MuonCollectionmuonsToken_
 
const edm::EDGetTokenT< reco::TrackCollectionmuonTracksToken_
 
TBranch * outputBranch_
 
TFile * outputFile_
 
std::string outputFileName_
 
TTree * outputTree_
 
std::string PropagatorSource_
 
const edm::ESGetToken< Propagator, TrackingComponentsRecordpropagatorToken_
 
ResidualRefitting::storage_trackExtrap samExtrap120_
 
ResidualRefitting::storage_muon storageGmrNew_
 
ResidualRefitting::storage_muon storageGmrNoPXBLayer1
 
ResidualRefitting::storage_muon storageGmrNoPXBLayer2
 
ResidualRefitting::storage_muon storageGmrNoPXBLayer3
 
ResidualRefitting::storage_muon storageGmrNoPXF
 
ResidualRefitting::storage_muon storageGmrNoSt1_
 
ResidualRefitting::storage_muon storageGmrNoSt2_
 
ResidualRefitting::storage_muon storageGmrNoSt3_
 
ResidualRefitting::storage_muon storageGmrNoSt4_
 
ResidualRefitting::storage_muon storageGmrNoTEC
 
ResidualRefitting::storage_muon storageGmrNoTIBLayer1
 
ResidualRefitting::storage_muon storageGmrNoTIBLayer2
 
ResidualRefitting::storage_muon storageGmrNoTIBLayer3
 
ResidualRefitting::storage_muon storageGmrNoTIBLayer4
 
ResidualRefitting::storage_muon storageGmrNoTID
 
ResidualRefitting::storage_muon storageGmrNoTOBLayer1
 
ResidualRefitting::storage_muon storageGmrNoTOBLayer2
 
ResidualRefitting::storage_muon storageGmrNoTOBLayer3
 
ResidualRefitting::storage_muon storageGmrNoTOBLayer4
 
ResidualRefitting::storage_muon storageGmrNoTOBLayer5
 
ResidualRefitting::storage_muon storageGmrNoTOBLayer6
 
ResidualRefitting::storage_muon storageGmrOld_
 
ResidualRefitting::storage_hit storageRecMuon_
 
ResidualRefitting::storage_muon storageSamNew_
 
ResidualRefitting::storage_muon storageSamNoSt1_
 
ResidualRefitting::storage_muon storageSamNoSt2_
 
ResidualRefitting::storage_muon storageSamNoSt3_
 
ResidualRefitting::storage_muon storageSamNoSt4_
 
ResidualRefitting::storage_trackExtrap storageTrackExtrapRec_
 
ResidualRefitting::storage_trackExtrap storageTrackExtrapRecNoSt1_
 
ResidualRefitting::storage_trackExtrap storageTrackExtrapRecNoSt2_
 
ResidualRefitting::storage_trackExtrap storageTrackExtrapRecNoSt3_
 
ResidualRefitting::storage_trackExtrap storageTrackExtrapRecNoSt4_
 
ResidualRefitting::storage_trackExtrap storageTrackExtrapTracker_
 
ResidualRefitting::storage_trackHit storageTrackHit_
 
ResidualRefitting::storage_trackExtrap storageTrackNoPXBLayer1
 
ResidualRefitting::storage_trackExtrap storageTrackNoPXBLayer2
 
ResidualRefitting::storage_trackExtrap storageTrackNoPXBLayer3
 
ResidualRefitting::storage_trackExtrap storageTrackNoPXF
 
ResidualRefitting::storage_trackExtrap storageTrackNoTEC
 
ResidualRefitting::storage_trackExtrap storageTrackNoTIBLayer1
 
ResidualRefitting::storage_trackExtrap storageTrackNoTIBLayer2
 
ResidualRefitting::storage_trackExtrap storageTrackNoTIBLayer3
 
ResidualRefitting::storage_trackExtrap storageTrackNoTIBLayer4
 
ResidualRefitting::storage_trackExtrap storageTrackNoTID
 
ResidualRefitting::storage_trackExtrap storageTrackNoTOBLayer1
 
ResidualRefitting::storage_trackExtrap storageTrackNoTOBLayer2
 
ResidualRefitting::storage_trackExtrap storageTrackNoTOBLayer3
 
ResidualRefitting::storage_trackExtrap storageTrackNoTOBLayer4
 
ResidualRefitting::storage_trackExtrap storageTrackNoTOBLayer5
 
ResidualRefitting::storage_trackExtrap storageTrackNoTOBLayer6
 
ResidualRefitting::storage_muon storageTrkNew_
 
ResidualRefitting::storage_muon storageTrkNoPXBLayer1
 
ResidualRefitting::storage_muon storageTrkNoPXBLayer2
 
ResidualRefitting::storage_muon storageTrkNoPXBLayer3
 
ResidualRefitting::storage_muon storageTrkNoPXF
 
ResidualRefitting::storage_muon storageTrkNoTEC
 
ResidualRefitting::storage_muon storageTrkNoTIBLayer1
 
ResidualRefitting::storage_muon storageTrkNoTIBLayer2
 
ResidualRefitting::storage_muon storageTrkNoTIBLayer3
 
ResidualRefitting::storage_muon storageTrkNoTIBLayer4
 
ResidualRefitting::storage_muon storageTrkNoTID
 
ResidualRefitting::storage_muon storageTrkNoTOBLayer1
 
ResidualRefitting::storage_muon storageTrkNoTOBLayer2
 
ResidualRefitting::storage_muon storageTrkNoTOBLayer3
 
ResidualRefitting::storage_muon storageTrkNoTOBLayer4
 
ResidualRefitting::storage_muon storageTrkNoTOBLayer5
 
ResidualRefitting::storage_muon storageTrkNoTOBLayer6
 
const MagneticFieldtheField
 
edm::ESHandle< PropagatorthePropagator
 
MuonServiceProxytheService
 
const edm::ESGetToken< TrackerTopology, TrackerTopologyRcdtopoToken_
 
ResidualRefitting::storage_trackExtrap trackExtrap120_
 
const edm::ESHandle< GlobalTrackingGeometrytrackingGeometry
 
const edm::ESGetToken< GlobalTrackingGeometry, GlobalTrackingGeometryRecordtrackingGeometryToken_
 
const edm::InputTag tracks_
 

Static Private Attributes

static const int N_MAX_STORED = 10
 
static const int N_MAX_STORED_HIT = 1000
 
static const int PXB = 1
 
static const int PXF = 2
 
static const int TEC = 6
 
static const int TIB = 3
 
static const int TID = 4
 
static const int TOB = 5
 

Additional Inherited Members

- Protected Member Functions inherited from edm::EDConsumerBase
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > consumes (edm::InputTag const &tag)
 
template<BranchType B = InEvent>
EDConsumerBaseAdaptor< Bconsumes (edm::InputTag tag) noexcept
 
EDGetToken consumes (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken consumes (TypeToGet const &id, edm::InputTag const &tag)
 
ConsumesCollector consumesCollector ()
 Use a ConsumesCollector to gather consumes information from helper functions. More...
 
template<typename ESProduct , typename ESRecord , Transition Tr = Transition::Event>
auto esConsumes ()
 
template<typename ESProduct , typename ESRecord , Transition Tr = Transition::Event>
auto esConsumes (ESInputTag const &tag)
 
template<Transition Tr = Transition::Event>
constexpr auto esConsumes ()
 
template<Transition Tr = Transition::Event>
auto esConsumes (ESInputTag tag)
 
template<Transition Tr = Transition::Event>
ESGetTokenGeneric esConsumes (eventsetup::EventSetupRecordKey const &iRecord, eventsetup::DataKey const &iKey)
 Used with EventSetupRecord::doGet. More...
 
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > mayConsume (edm::InputTag const &tag)
 
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
void resetItemsToGetFrom (BranchType iType)
 

Detailed Description

Definition at line 33 of file ResidualRefitting.h.

Member Typedef Documentation

◆ storage_hit

◆ storage_muon

◆ storage_trackExtrap

◆ storage_trackHit

Constructor & Destructor Documentation

◆ ResidualRefitting()

ResidualRefitting::ResidualRefitting ( const edm::ParameterSet cfg)
explicit

Definition at line 36 of file ResidualRefitting.cc.

References looper::cfg, edm::EDConsumerBase::consumesCollector(), eventInfo_, ResidualRefitting::storage_event::evtNum_, MuonServiceProxy_cff::MuonServiceProxy, and theService.

40  propagatorToken_(esConsumes(edm::ESInputTag("", cfg.getParameter<std::string>("propagator")))),
41  outputFileName_(cfg.getUntrackedParameter<std::string>("histoutputFile")),
42  muons_(cfg.getParameter<edm::InputTag>("muons")),
43  muonsRemake_(cfg.getParameter<edm::InputTag>("muonsRemake")), //This Feels Misalignment
44  muonsNoStation1_(cfg.getParameter<edm::InputTag>("muonsNoStation1")),
45  muonsNoStation2_(cfg.getParameter<edm::InputTag>("muonsNoStation2")),
46  muonsNoStation3_(cfg.getParameter<edm::InputTag>("muonsNoStation3")),
47  muonsNoStation4_(cfg.getParameter<edm::InputTag>("muonsNoStation4")),
48  debug_(cfg.getUntrackedParameter<bool>("doDebug")),
49  muonsToken_(consumes<reco::MuonCollection>(muons_)),
50  muonTracksToken_(consumes<reco::TrackCollection>(muonsRemake_)),
51  muonsNoSt1Token_(consumes<reco::TrackCollection>(muonsNoStation1_)),
52  muonsNoSt2Token_(consumes<reco::TrackCollection>(muonsNoStation2_)),
53  muonsNoSt3Token_(consumes<reco::TrackCollection>(muonsNoStation3_)),
54  muonsNoSt4Token_(consumes<reco::TrackCollection>(muonsNoStation4_)),
55  outputFile_(nullptr),
56  outputTree_(nullptr),
57  outputBranch_(nullptr),
58  theField(nullptr) {
59  eventInfo_.evtNum_ = 0;
60  eventInfo_.evtNum_ = 0;
61 
62  // service parameters
63  edm::ParameterSet serviceParameters = cfg.getParameter<edm::ParameterSet>("ServiceParameters");
64 
65  // the services
66  theService = new MuonServiceProxy(serviceParameters, consumesCollector());
67 } //The constructor
const MagneticField * theField
const edm::EDGetTokenT< reco::TrackCollection > muonsNoSt4Token_
const edm::InputTag muonsNoStation1_
const edm::InputTag muonsNoStation2_
const edm::ESGetToken< Propagator, TrackingComponentsRecord > propagatorToken_
const edm::InputTag muonsNoStation3_
ConsumesCollector consumesCollector()
Use a ConsumesCollector to gather consumes information from helper functions.
MuonServiceProxy * theService
const edm::EDGetTokenT< reco::TrackCollection > muonsNoSt1Token_
const edm::ESGetToken< TrackerTopology, TrackerTopologyRcd > topoToken_
const edm::EDGetTokenT< reco::TrackCollection > muonsNoSt2Token_
std::string outputFileName_
const edm::InputTag muonsRemake_
const edm::ESGetToken< GlobalTrackingGeometry, GlobalTrackingGeometryRecord > trackingGeometryToken_
const edm::InputTag muonsNoStation4_
const edm::EDGetTokenT< reco::TrackCollection > muonsNoSt3Token_
ResidualRefitting::storage_event eventInfo_
const edm::ESGetToken< MagneticField, IdealMagneticFieldRecord > magFieldToken_
const edm::EDGetTokenT< reco::TrackCollection > muonTracksToken_
const edm::EDGetTokenT< reco::MuonCollection > muonsToken_
const edm::InputTag muons_

◆ ~ResidualRefitting()

ResidualRefitting::~ResidualRefitting ( )
override

Definition at line 198 of file ResidualRefitting.cc.

References outputFile_, and theService.

198  {
199  delete outputFile_;
200  delete theService;
201 }
MuonServiceProxy * theService

Member Function Documentation

◆ analyze()

void ResidualRefitting::analyze ( const edm::Event event,
const edm::EventSetup eventSetup 
)
overridevirtual

Implements edm::one::EDAnalyzerBase.

Definition at line 82 of file ResidualRefitting.cc.

References CollectTrackHits(), cylExtrapTrkSam(), debug_, dumpTrackRef(), eventInfo_, options_cfi::eventSetup, ResidualRefitting::storage_event::evtNum_, createfilelist::int, magFieldToken_, muonInfo(), DiMuonV_cfg::muons, muonsNoSt1Token_, muonsNoSt2Token_, muonsNoSt3Token_, muonsNoSt4Token_, muonsToken_, DiMuonV_cfg::muonTracks, muonTracksToken_, ResidualRefitting::StorageMuon::n_, ResidualRefitting::StorageTrackExtrap::n_, N_MAX_STORED, NewTrackMeasurements(), outputBranch_, outputTree_, propagatorToken_, ResidualRefitting::storage_event::runNum_, samExtrap120_, storageGmrNew_, storageTrackExtrapRec_, storageTrackExtrapRecNoSt1_, storageTrackExtrapRecNoSt2_, storageTrackExtrapRecNoSt3_, storageTrackExtrapRecNoSt4_, theField, thePropagator, theService, trackExtrap120_, trackingGeometryToken_, MuonServiceProxy::update(), and zero_storage().

82  {
83  if (debug_)
84  printf("STARTING EVENT\n");
85 
86  eventInfo_.evtNum_ = (int)event.id().run();
87  eventInfo_.runNum_ = (int)event.id().event();
88 
89  // Generator Collection
90 
91  // The original muon collection that is sitting in memory
92  const edm::Handle<reco::MuonCollection>& muons = event.getHandle(muonsToken_);
94  const edm::Handle<reco::TrackCollection>& muonsNoSt1 = event.getHandle(muonsNoSt1Token_);
95  const edm::Handle<reco::TrackCollection>& muonsNoSt2 = event.getHandle(muonsNoSt2Token_);
96  const edm::Handle<reco::TrackCollection>& muonsNoSt3 = event.getHandle(muonsNoSt3Token_);
97  const edm::Handle<reco::TrackCollection>& muonsNoSt4 = event.getHandle(muonsNoSt4Token_);
98 
99  //magnetic field information
100  theField = &eventSetup.getData(magFieldToken_);
101  edm::ESHandle<GlobalTrackingGeometry> globalTrackingGeometry = eventSetup.getHandle(trackingGeometryToken_);
104 
105  //Zero storage
106  zero_storage();
107 
108  //Do the Gmr Muons from the unModified Collection
109 
110  //Refitted muons
111  if (debug_)
112  printf("Data Dump:: Rebuilt GMR Muon Track With TeV refitter default\n");
113  int iGmrRemake = 0;
114  for (reco::TrackCollection::const_iterator muon = muonTracks->begin(); muon != muonTracks->end();
115  muon++, iGmrRemake++) {
116  if (iGmrRemake >= ResidualRefitting::N_MAX_STORED)
117  break; // error checking
118  // from TrackInfoProducer/test/TrackInfoAnalyzerExample.cc
119  reco::TrackRef trackref = reco::TrackRef(muonTracks, iGmrRemake);
120 
121  if (debug_)
122  dumpTrackRef(trackref, "gmr");
123  muonInfo(storageGmrNew_, trackref, iGmrRemake);
124  }
125  storageGmrNew_.n_ = iGmrRemake;
126 
127  if (debug_)
128  printf("muons Remake");
129  if (debug_)
130  printf("-----------------------------------------\n");
132 
133  if (true) {
134  printf("muons No Station 1");
135  printf("-----------------------------------------\n");
136  }
138 
139  if (true) {
140  printf("muons No Station 2");
141  printf("-----------------------------------------\n");
142  }
144 
145  if (true) {
146  printf("muons No Station 3");
147  printf("-----------------------------------------\n");
148  }
150 
151  if (true) {
152  printf("muons No Station 4");
153  printf("-----------------------------------------\n");
154  }
156 
157  // dumpMuonRecHits(storageRecMuon_);
158 
159  /****************************************************************************************************************************************/
160 
161  /*
162  * extrapolates track to a cylinder.
163  * commented for cosmic runs with no tracker in reco muons!!
164  *
165 */
166 
167  int iGmrCyl = 0;
168  for (reco::MuonCollection::const_iterator muon = muons->begin(); muon != muons->end(); muon++, iGmrCyl++) {
169  dumpTrackRef(muon->combinedMuon(), "cmb");
170  dumpTrackRef(muon->standAloneMuon(), "sam");
171  dumpTrackRef(muon->track(), "trk");
172 
173  cylExtrapTrkSam(iGmrCyl, muon->standAloneMuon(), samExtrap120_, 120.);
174  cylExtrapTrkSam(iGmrCyl, muon->track(), trackExtrap120_, 120.);
175  }
176  samExtrap120_.n_ = iGmrCyl;
177  trackExtrap120_.n_ = iGmrCyl;
178 
179  if (iGmrRemake > 0 || iGmrCyl > 0) {
180  outputTree_->Fill();
181  edm::LogVerbatim("ResidualRefitting") << "FILLING NTUPLE!";
182  edm::LogVerbatim("ResidualRefitting")
183  << "Entries Recorded: " << outputTree_->GetEntries() << " Branch :: " << outputBranch_->GetEntries();
184  } else
185  edm::LogVerbatim("ResidualRefitting") << "no tracks -- no fill!\n";
186 
187  // /*************************************************************************************************************/
188  // //END OF ntuple dumper
189  // //END OF ntuple dumper
190  // /***********************************************************************************************************/
191 }
void CollectTrackHits(edm::Handle< reco::TrackCollection > trackColl, ResidualRefitting::storage_trackExtrap &trackExtrap, const edm::EventSetup &eventSetup)
Log< level::Info, true > LogVerbatim
static const int N_MAX_STORED
void dumpTrackRef(reco::TrackRef muon, std::string str)
const MagneticField * theField
ResidualRefitting::storage_trackExtrap storageTrackExtrapRecNoSt3_
const edm::EDGetTokenT< reco::TrackCollection > muonsNoSt4Token_
muons
the two sets of parameters below are mutually exclusive, depending if RECO or ALCARECO is used the us...
Definition: DiMuonV_cfg.py:214
ResidualRefitting::storage_trackExtrap storageTrackExtrapRecNoSt1_
ResidualRefitting::storage_trackExtrap storageTrackExtrapRec_
ResidualRefitting::storage_trackExtrap storageTrackExtrapRecNoSt4_
const edm::ESGetToken< Propagator, TrackingComponentsRecord > propagatorToken_
void muonInfo(ResidualRefitting::storage_muon &storeMuon, reco::TrackRef muon, int val)
ResidualRefitting::storage_trackExtrap storageTrackExtrapRecNoSt2_
MuonServiceProxy * theService
ResidualRefitting::storage_trackExtrap trackExtrap120_
const edm::EDGetTokenT< reco::TrackCollection > muonsNoSt1Token_
const edm::EDGetTokenT< reco::TrackCollection > muonsNoSt2Token_
ResidualRefitting::storage_muon storageGmrNew_
void cylExtrapTrkSam(int recNum, reco::TrackRef track, ResidualRefitting::storage_trackExtrap &storage, double rho)
edm::Ref< TrackCollection > TrackRef
persistent reference to a Track
Definition: TrackFwd.h:20
const edm::ESGetToken< GlobalTrackingGeometry, GlobalTrackingGeometryRecord > trackingGeometryToken_
const edm::EDGetTokenT< reco::TrackCollection > muonsNoSt3Token_
ResidualRefitting::storage_event eventInfo_
void update(const edm::EventSetup &setup, bool duringEvent=true)
update the services each event
const edm::ESGetToken< MagneticField, IdealMagneticFieldRecord > magFieldToken_
edm::ESHandle< Propagator > thePropagator
void NewTrackMeasurements(const edm::Handle< reco::TrackCollection > &trackCollOrig, const edm::Handle< reco::TrackCollection > &trackColl, ResidualRefitting::storage_trackExtrap &trackExtrap)
const edm::EDGetTokenT< reco::TrackCollection > muonTracksToken_
Definition: event.py:1
const edm::EDGetTokenT< reco::MuonCollection > muonsToken_
ResidualRefitting::storage_trackExtrap samExtrap120_

◆ beginJob()

void ResidualRefitting::beginJob ( )
overridevirtual

Reimplemented from edm::one::EDAnalyzerBase.

Definition at line 902 of file ResidualRefitting.cc.

References branchMuon(), branchTrackExtrap(), eventInfo_, outputBranch_, outputFile_, outputFileName_, outputTree_, samExtrap120_, storageGmrNew_, storageGmrNoPXBLayer1, storageGmrNoPXBLayer2, storageGmrNoPXBLayer3, storageGmrNoPXF, storageGmrNoSt1_, storageGmrNoSt2_, storageGmrNoSt3_, storageGmrNoSt4_, storageGmrNoTEC, storageGmrNoTIBLayer1, storageGmrNoTIBLayer2, storageGmrNoTIBLayer3, storageGmrNoTIBLayer4, storageGmrNoTID, storageGmrNoTOBLayer1, storageGmrNoTOBLayer2, storageGmrNoTOBLayer3, storageGmrNoTOBLayer4, storageGmrNoTOBLayer5, storageGmrNoTOBLayer6, storageGmrOld_, storageRecMuon_, storageSamNew_, storageSamNoSt1_, storageSamNoSt2_, storageSamNoSt3_, storageSamNoSt4_, storageTrackExtrapRec_, storageTrackExtrapRecNoSt1_, storageTrackExtrapRecNoSt2_, storageTrackExtrapRecNoSt3_, storageTrackExtrapRecNoSt4_, storageTrackExtrapTracker_, storageTrackHit_, storageTrackNoPXBLayer1, storageTrackNoPXBLayer2, storageTrackNoPXBLayer3, storageTrackNoPXF, storageTrackNoTEC, storageTrackNoTIBLayer1, storageTrackNoTIBLayer2, storageTrackNoTIBLayer3, storageTrackNoTIBLayer4, storageTrackNoTID, storageTrackNoTOBLayer1, storageTrackNoTOBLayer2, storageTrackNoTOBLayer3, storageTrackNoTOBLayer4, storageTrackNoTOBLayer5, storageTrackNoTOBLayer6, storageTrkNew_, storageTrkNoPXBLayer1, storageTrkNoPXBLayer2, storageTrkNoPXBLayer3, storageTrkNoPXF, storageTrkNoTEC, storageTrkNoTIBLayer1, storageTrkNoTIBLayer2, storageTrkNoTIBLayer3, storageTrkNoTIBLayer4, storageTrkNoTID, storageTrkNoTOBLayer1, storageTrkNoTOBLayer2, storageTrkNoTOBLayer3, storageTrkNoTOBLayer4, storageTrkNoTOBLayer5, storageTrkNoTOBLayer6, and trackExtrap120_.

902  {
903  edm::LogVerbatim("ResidualRefitting") << "Creating file " << outputFileName_.c_str();
904 
905  outputFile_ = new TFile(outputFileName_.c_str(), "RECREATE");
906 
907  outputTree_ = new TTree("outputTree", "outputTree");
908 
909  outputTree_->Branch("eventInfo",
910  &eventInfo_,
911  "evtNum_/I:"
912  "runNum_/I");
913 
920 
926 
944 
961 
962  outputBranch_ = outputTree_->Branch("recHitsNew",
964 
965  "n_/I:"
966  "muonLink_[1000]/I:"
967 
968  "system_[1000]/I:"
969  "endcap_[1000]/I:"
970  "station_[1000]/I:"
971  "ring_[1000]/I:"
972  "chamber_[1000]/I:"
973  "layer_[1000]/I:"
974  "superLayer_[1000]/I:"
975  "wheel_[1000]/I:"
976  "sector_[1000]/I:"
977 
978  "gpX_[1000]/F:"
979  "gpY_[1000]/F:"
980  "gpZ_[1000]/F:"
981  "gpEta_[1000]/F:"
982  "gpPhi_[1000]/F:"
983  "lpX_[1000]/F:"
984  "lpY_[1000]/F:"
985  "lpZ_[1000]/F");
986 
987  outputBranch_ = outputTree_->Branch("recHitsTracker",
989 
990  "n_/I:"
991 
992  "muonLink_[1000]/I:"
993  "detector_[1000]/I:"
994  "subdetector_[1000]/I:"
995  "blade_[1000]/I:"
996  "disk_[1000]/I:"
997  "ladder_[1000]/I:"
998  "layer_[1000]/I:"
999  "module_[1000]/I:"
1000  "panel_[1000]/I:"
1001  "ring_[1000]/I:"
1002  "side_[1000]/I:"
1003  "wheel_[1000]/I:"
1004 
1005  "gpX_[1000]/F:"
1006  "gpY_[1000]/F:"
1007  "gpZ_[1000]/F:"
1008  "gpEta_[1000]/F:"
1009  "gpPhi_[1000]/F:"
1010  "lpX_[1000]/F:"
1011  "lpY_[1000]/F:"
1012  "lpZ_[1000]/F");
1013 
1019 
1037 
1040 }
ResidualRefitting::storage_muon storageGmrNoTIBLayer4
Log< level::Info, true > LogVerbatim
ResidualRefitting::storage_muon storageTrkNoTOBLayer4
ResidualRefitting::storage_muon storageGmrNoTOBLayer1
ResidualRefitting::storage_trackExtrap storageTrackNoTEC
ResidualRefitting::storage_muon storageGmrNoPXBLayer1
ResidualRefitting::storage_trackExtrap storageTrackNoPXBLayer1
ResidualRefitting::storage_muon storageGmrNoTID
ResidualRefitting::storage_muon storageTrkNoTOBLayer6
ResidualRefitting::storage_muon storageGmrNoTIBLayer1
ResidualRefitting::storage_trackHit storageTrackHit_
ResidualRefitting::storage_trackExtrap storageTrackExtrapRecNoSt3_
ResidualRefitting::storage_muon storageTrkNoTOBLayer5
ResidualRefitting::storage_trackExtrap storageTrackNoTIBLayer2
ResidualRefitting::storage_trackExtrap storageTrackNoTIBLayer4
ResidualRefitting::storage_muon storageTrkNoTIBLayer2
ResidualRefitting::storage_muon storageGmrNoTOBLayer2
ResidualRefitting::storage_muon storageGmrNoSt1_
ResidualRefitting::storage_trackExtrap storageTrackNoTOBLayer6
ResidualRefitting::storage_trackExtrap storageTrackExtrapRecNoSt1_
ResidualRefitting::storage_muon storageGmrNoTOBLayer6
ResidualRefitting::storage_muon storageSamNew_
ResidualRefitting::storage_trackExtrap storageTrackNoTOBLayer4
ResidualRefitting::storage_muon storageTrkNoTID
ResidualRefitting::storage_trackExtrap storageTrackExtrapTracker_
ResidualRefitting::storage_trackExtrap storageTrackExtrapRec_
ResidualRefitting::storage_muon storageGmrNoTOBLayer4
ResidualRefitting::storage_muon storageGmrNoSt4_
ResidualRefitting::storage_trackExtrap storageTrackExtrapRecNoSt4_
ResidualRefitting::storage_trackExtrap storageTrackNoTOBLayer2
void branchMuon(ResidualRefitting::storage_muon &storageTmp, std::string branchName)
ResidualRefitting::storage_muon storageSamNoSt4_
ResidualRefitting::storage_trackExtrap storageTrackExtrapRecNoSt2_
ResidualRefitting::storage_muon storageTrkNoPXBLayer2
ResidualRefitting::storage_muon storageGmrNoSt2_
ResidualRefitting::storage_muon storageGmrNoSt3_
ResidualRefitting::storage_muon storageGmrNoPXBLayer2
ResidualRefitting::storage_muon storageGmrOld_
ResidualRefitting::storage_muon storageTrkNoPXF
ResidualRefitting::storage_muon storageGmrNoTEC
ResidualRefitting::storage_trackExtrap trackExtrap120_
ResidualRefitting::storage_muon storageGmrNoTIBLayer3
ResidualRefitting::storage_muon storageGmrNew_
std::string outputFileName_
ResidualRefitting::storage_muon storageGmrNoTIBLayer2
ResidualRefitting::storage_muon storageTrkNoTIBLayer3
ResidualRefitting::storage_trackExtrap storageTrackNoTID
ResidualRefitting::storage_muon storageTrkNoTOBLayer2
ResidualRefitting::storage_trackExtrap storageTrackNoPXBLayer3
ResidualRefitting::storage_trackExtrap storageTrackNoTOBLayer5
ResidualRefitting::storage_muon storageSamNoSt2_
ResidualRefitting::storage_trackExtrap storageTrackNoTOBLayer3
ResidualRefitting::storage_muon storageTrkNoTOBLayer1
ResidualRefitting::storage_muon storageGmrNoPXBLayer3
ResidualRefitting::storage_muon storageTrkNoTEC
ResidualRefitting::storage_muon storageSamNoSt3_
ResidualRefitting::storage_muon storageTrkNoPXBLayer1
ResidualRefitting::storage_muon storageTrkNoTIBLayer1
ResidualRefitting::storage_muon storageGmrNoTOBLayer3
ResidualRefitting::storage_trackExtrap storageTrackNoTIBLayer1
ResidualRefitting::storage_event eventInfo_
ResidualRefitting::storage_hit storageRecMuon_
ResidualRefitting::storage_muon storageTrkNoTOBLayer3
ResidualRefitting::storage_muon storageTrkNew_
ResidualRefitting::storage_trackExtrap storageTrackNoPXF
ResidualRefitting::storage_muon storageSamNoSt1_
ResidualRefitting::storage_muon storageGmrNoTOBLayer5
ResidualRefitting::storage_trackExtrap storageTrackNoTIBLayer3
ResidualRefitting::storage_trackExtrap storageTrackNoTOBLayer1
void branchTrackExtrap(ResidualRefitting::storage_trackExtrap &storageTmp, std::string branchName)
ResidualRefitting::storage_muon storageGmrNoPXF
ResidualRefitting::storage_trackExtrap storageTrackNoPXBLayer2
ResidualRefitting::storage_muon storageTrkNoPXBLayer3
ResidualRefitting::storage_muon storageTrkNoTIBLayer4
ResidualRefitting::storage_trackExtrap samExtrap120_

◆ branchMuon()

void ResidualRefitting::branchMuon ( ResidualRefitting::storage_muon storageTmp,
std::string  branchName 
)

Definition at line 1044 of file ResidualRefitting.cc.

References electrons_cff::branchName, outputBranch_, and outputTree_.

Referenced by beginJob().

1044  {
1045  outputBranch_ = outputTree_->Branch(branchName.c_str(),
1046  &storageTmp,
1047  "n_/I:"
1048  "charge_[10]/I:"
1049  "pt_[10]/F:"
1050  "eta_[10]/F:"
1051  "p_[10]/F:"
1052  "phi_[10]/F:"
1053  "numRecHits_[10]/I:"
1054  "chiSq_[10]/F:"
1055  "ndf_[10]/F:"
1056  "chiSqOvrNdf_[10]/F"
1057 
1058  );
1059 }

◆ branchTrackExtrap()

void ResidualRefitting::branchTrackExtrap ( ResidualRefitting::storage_trackExtrap storageTmp,
std::string  branchName 
)

Definition at line 1063 of file ResidualRefitting.cc.

References electrons_cff::branchName, outputBranch_, and outputTree_.

Referenced by beginJob().

1063  {
1064  outputBranch_ = outputTree_->Branch(branchName.c_str(),
1065  &storageTmp,
1066  "n_/I:"
1067  "muonLink_[1000]/I:"
1068  "recLink_[1000]/I:"
1069  "gpX_[1000]/F:"
1070  "gpY_[1000]/F:"
1071  "gpZ_[1000]/F:"
1072  "gpEta_[1000]/F:"
1073  "gpPhi_[1000]/F:"
1074  "lpX_[1000]/F:"
1075  "lpY_[1000]/F:"
1076  "lpZ_[1000]/F:"
1077  "resX_[1000]/F:"
1078  "resY_[1000]/F:"
1079  "resZ_[1000]/F"
1080 
1081  );
1082 }

◆ CollectTrackHits()

void ResidualRefitting::CollectTrackHits ( edm::Handle< reco::TrackCollection trackColl,
ResidualRefitting::storage_trackExtrap trackExtrap,
const edm::EventSetup eventSetup 
)

Definition at line 205 of file ResidualRefitting.cc.

References relativeConstraints::chamber, ResidualRefitting::StorageHit::chamber_, MuonSubdetId::CSC, debug_, DetId::det(), MuonSubdetId::DT, dumpTrackRef(), makeMuonMisalignmentScenario::endcap, ResidualRefitting::StorageHit::endcap_, options_cfi::eventSetup, freeTrajStateMuon(), runTauDisplay::gp, ResidualRefitting::StorageHit::gpEta_, ResidualRefitting::StorageTrackHit::gpEta_, ResidualRefitting::StorageHit::gpPhi_, ResidualRefitting::StorageTrackHit::gpPhi_, ResidualRefitting::StorageHit::gpX_, ResidualRefitting::StorageTrackHit::gpX_, ResidualRefitting::StorageHit::gpY_, ResidualRefitting::StorageTrackHit::gpY_, ResidualRefitting::StorageHit::gpZ_, ResidualRefitting::StorageTrackHit::gpZ_, l1ctLayer2EG_cff::id, GlobalTrackingGeometry::idToDet(), nano_mu_digi_cff::layer, ResidualRefitting::StorageHit::layer_, ResidualRefitting::StorageHit::lpX_, ResidualRefitting::StorageTrackHit::lpX_, ResidualRefitting::StorageHit::lpY_, ResidualRefitting::StorageTrackHit::lpY_, ResidualRefitting::StorageHit::lpZ_, ResidualRefitting::StorageTrackHit::lpZ_, DetId::Muon, ResidualRefitting::StorageHit::muonLink_, ResidualRefitting::StorageHit::n_, ResidualRefitting::StorageTrackExtrap::n_, ResidualRefitting::StorageTrackHit::n_, DetId::rawId(), relativeConstraints::ring, ResidualRefitting::StorageHit::ring_, MuonSubdetId::RPC, nano_mu_digi_cff::sector, ResidualRefitting::StorageHit::sector_, MuonTransientTrackingRecHit::specificBuild(), relativeConstraints::station, ResidualRefitting::StorageHit::station_, storageRecMuon_, storageTrackHit_, StoreTrackerRecHits(), DetId::subdetId(), nano_mu_digi_cff::superLayer, ResidualRefitting::StorageHit::superLayer_, ResidualRefitting::StorageHit::system_, theService, topoToken_, pfDisplacedTrackerVertex_cfi::trackColl, DetId::Tracker, MuonServiceProxy::trackingGeometry(), trkExtrap(), makeMuonMisalignmentScenario::wheel, ResidualRefitting::StorageHit::wheel_, PV3DBase< T, PVType, FrameType >::x(), PV3DBase< T, PVType, FrameType >::y(), and PV3DBase< T, PVType, FrameType >::z().

Referenced by analyze().

207  {
208  //Retrieve tracker topology from geometry
209  const TrackerTopology* const tTopo = &eventSetup.getData(topoToken_);
210 
211  int iMuonHit = 0;
212  int iTrackHit = 0;
213  int numTracks = 0;
214 
215  for (reco::TrackCollection::const_iterator muon = trackColl->begin(); muon != trackColl->end(); muon++) {
216  int iTrack = muon - trackColl->begin();
217  reco::TrackRef trackref = reco::TrackRef(trackColl, iTrack);
219 
220  if (debug_)
221  dumpTrackRef(trackref, "CollectTrackHits Track");
222 
223  int iRec = 0;
224  for (auto const& rec : muon->recHits()) {
225  DetId detid = rec->geographicalId();
226 
227  if (detid.det() != DetId::Muon && detid.det() != DetId::Tracker) {
228  if (debug_)
229  printf("Rec Hit not from muon system or tracker... continuing...\n");
230  continue;
231  }
232  // numTracks++;
233  // Get Local and Global Position of Hits
234 
235  LocalPoint lp = rec->localPosition();
236  float lpX = lp.x();
237  float lpY = lp.y();
238  float lpZ = lp.z();
239 
241  theService->trackingGeometry()->idToDet(rec->geographicalId()), rec);
242 
243  GlobalPoint gp = mrhp->globalPosition();
244  float gpRecX = gp.x();
245  float gpRecY = gp.y();
246  float gpRecZ = gp.z();
247  float gpRecEta = gp.eta();
248  float gpRecPhi = gp.phi();
249 
250  if (detid.det() == DetId::Muon) {
251  int systemMuon = detid.subdetId(); // 1 DT; 2 CSC; 3 RPC
252  int endcap = -999;
253  int station = -999;
254  int ring = -999;
255  int chamber = -999;
256  int layer = -999;
257  int superLayer = -999;
258  int wheel = -999;
259  int sector = -999;
260  if (systemMuon == MuonSubdetId::CSC) {
261  CSCDetId id(detid.rawId());
262  endcap = id.endcap();
263  station = id.station();
264  ring = id.ring();
265  chamber = id.chamber();
266  layer = id.layer();
267  if (debug_)
268  printf("CSC\t[endcap][station][ringN][chamber][layer]:[%d][%d][%d][%d][%d]\t",
269  endcap,
270  station,
271  ring,
272  chamber,
273  layer);
274 
275  } else if (systemMuon == MuonSubdetId::DT) {
276  DTWireId id(detid.rawId());
277  station = id.station();
278  layer = id.layer();
279  superLayer = id.superLayer();
280  wheel = id.wheel();
281  sector = id.sector();
282  if (debug_)
283  printf("DT \t[station][layer][superlayer]:[%d][%d][%d]\n", station, layer, superLayer);
284 
285  } else if (systemMuon == MuonSubdetId::RPC) {
286  RPCDetId id(detid.rawId());
287  station = id.station();
288  if (debug_)
289  printf("RPC\t[station]:[%d]\n", station);
290  }
291 
292  storageRecMuon_.muonLink_[iMuonHit] = iTrack;
293  storageRecMuon_.system_[iMuonHit] = systemMuon;
294  storageRecMuon_.endcap_[iMuonHit] = endcap;
295  storageRecMuon_.station_[iMuonHit] = station;
296  storageRecMuon_.ring_[iMuonHit] = ring;
297  storageRecMuon_.chamber_[iMuonHit] = chamber;
298  storageRecMuon_.layer_[iMuonHit] = layer;
300  storageRecMuon_.wheel_[iMuonHit] = wheel;
301  storageRecMuon_.sector_[iMuonHit] = sector;
302 
303  storageRecMuon_.gpX_[iMuonHit] = gpRecX;
304  storageRecMuon_.gpY_[iMuonHit] = gpRecY;
305  storageRecMuon_.gpZ_[iMuonHit] = gpRecZ;
306  storageRecMuon_.gpEta_[iMuonHit] = gpRecEta;
307  storageRecMuon_.gpPhi_[iMuonHit] = gpRecPhi;
308  storageRecMuon_.lpX_[iMuonHit] = lpX;
309  storageRecMuon_.lpY_[iMuonHit] = lpY;
310  storageRecMuon_.lpZ_[iMuonHit] = lpZ;
311  iMuonHit++;
312 
313  } else if (detid.det() == DetId::Tracker) {
314  if (debug_)
315  printf("Tracker\n");
316 
317  StoreTrackerRecHits(detid, tTopo, iTrack, iTrackHit);
318 
319  storageTrackHit_.gpX_[iTrackHit] = gpRecX;
320  storageTrackHit_.gpY_[iTrackHit] = gpRecY;
321  storageTrackHit_.gpZ_[iTrackHit] = gpRecZ;
322  storageTrackHit_.gpEta_[iTrackHit] = gpRecEta;
323  storageTrackHit_.gpPhi_[iTrackHit] = gpRecPhi;
324  storageTrackHit_.lpX_[iTrackHit] = lpX;
325  storageTrackHit_.lpY_[iTrackHit] = lpY;
326  storageTrackHit_.lpZ_[iTrackHit] = lpZ;
327  iTrackHit++;
328  } else
329  printf("THIS CAN NOT HAPPEN\n");
330 
331  trkExtrap(detid, numTracks, iTrack, iRec, recoStart, lp, trackExtrap);
332  numTracks++;
333 
334  if (debug_)
335  printf("\tLocal Positon: \tx = %2.2f\ty = %2.2f\tz = %2.2f\n", lpX, lpY, lpZ);
336  if (debug_)
337  printf("\tGlobal Position: \tx = %6.2f\ty = %6.2f\tz = %6.2f\teta = %4.2f\tphi = %3.2f\n",
338  gpRecX,
339  gpRecY,
340  gpRecZ,
341  gpRecEta,
342  gpRecPhi);
343 
344  ++iRec;
345  }
346  }
347 
348  storageRecMuon_.n_ = iMuonHit;
349  storageTrackHit_.n_ = iTrackHit;
350  trackExtrap.n_ = numTracks;
351 }
int endcap_[N_MAX_STORED_HIT]
edm::ESHandle< GlobalTrackingGeometry > trackingGeometry() const
get the tracking geometry
void dumpTrackRef(reco::TrackRef muon, std::string str)
float lpZ_[N_MAX_STORED_HIT]
T z() const
Definition: PV3DBase.h:61
ResidualRefitting::storage_trackHit storageTrackHit_
int sector_[N_MAX_STORED_HIT]
int layer_[N_MAX_STORED_HIT]
int chamber_[N_MAX_STORED_HIT]
float lpY_[N_MAX_STORED_HIT]
const GeomDet * idToDet(DetId) const override
void trkExtrap(const DetId &detid, int iTrkLink, int iTrk, int iRec, const FreeTrajectoryState &freeTrajState, const LocalPoint &recPoint, storage_trackExtrap &storeTemp)
constexpr Detector det() const
get the detector field from this detid
Definition: DetId.h:46
int muonLink_[N_MAX_STORED_HIT]
float gpEta_[N_MAX_STORED_HIT]
T x() const
Definition: PV3DBase.h:59
T y() const
Definition: PV3DBase.h:60
float lpX_[N_MAX_STORED_HIT]
int wheel_[N_MAX_STORED_HIT]
float gpY_[N_MAX_STORED_HIT]
MuonServiceProxy * theService
constexpr int subdetId() const
get the contents of the subdetector field (not cast into any detector&#39;s numbering enum) ...
Definition: DetId.h:48
FreeTrajectoryState freeTrajStateMuon(reco::TrackRef muon)
const edm::ESGetToken< TrackerTopology, TrackerTopologyRcd > topoToken_
Definition: DetId.h:17
float gpX_[N_MAX_STORED_HIT]
int station_[N_MAX_STORED_HIT]
constexpr uint32_t rawId() const
get the raw id
Definition: DetId.h:57
float gpPhi_[N_MAX_STORED_HIT]
edm::Ref< TrackCollection > TrackRef
persistent reference to a Track
Definition: TrackFwd.h:20
static constexpr int RPC
Definition: MuonSubdetId.h:13
int ring_[N_MAX_STORED_HIT]
float gpZ_[N_MAX_STORED_HIT]
int superLayer_[N_MAX_STORED_HIT]
ResidualRefitting::storage_hit storageRecMuon_
void StoreTrackerRecHits(DetId detid, const TrackerTopology *tTopo, int iTrack, int iRec)
static constexpr int DT
Definition: MuonSubdetId.h:11
static constexpr int CSC
Definition: MuonSubdetId.h:12
static MuonRecHitPointer specificBuild(const GeomDet *geom, const TrackingRecHit *rh)
int system_[N_MAX_STORED_HIT]

◆ cylExtrapTrkSam()

void ResidualRefitting::cylExtrapTrkSam ( int  recNum,
reco::TrackRef  track,
ResidualRefitting::storage_trackExtrap storage,
double  rho 
)

Definition at line 716 of file ResidualRefitting.cc.

References Cylinder::build(), debug_, PV3DBase< T, PVType, FrameType >::eta(), freeTrajStateMuon(), TrajectoryStateOnSurface::globalPosition(), ResidualRefitting::StorageTrackExtrap::gpEta_, ResidualRefitting::StorageTrackExtrap::gpPhi_, ResidualRefitting::StorageTrackExtrap::gpX_, ResidualRefitting::StorageTrackExtrap::gpY_, ResidualRefitting::StorageTrackExtrap::gpZ_, TrajectoryStateOnSurface::isValid(), ResidualRefitting::StorageTrackExtrap::muonLink_, PV3DBase< T, PVType, FrameType >::phi(), Propagator::propagate(), rho, makeMuonMisalignmentScenario::rot, mathSSE::sqrt(), thePropagator, HLT_2024v10_cff::track, PV3DBase< T, PVType, FrameType >::x(), PV3DBase< T, PVType, FrameType >::y(), and PV3DBase< T, PVType, FrameType >::z().

Referenced by analyze().

719  {
720  Cylinder::PositionType pos(0, 0, 0);
722 
724  // SteppingHelixPropagator inwardProp ( theField, oppositeToMomentum );
725  // SteppingHelixPropagator outwardProp ( theField, alongMomentum );
727  // TrajectoryStateOnSurface recoProp = outwardProp.propagate(recoStart, *myCylinder);
728  TrajectoryStateOnSurface recoProp = thePropagator->propagate(recoStart, *myCylinder);
729 
730  double xVal = -9999;
731  double yVal = -9999;
732  double zVal = -9999;
733  double phiVal = -9999;
734  double etaVal = -9999;
735 
736  if (recoProp.isValid()) {
737  GlobalPoint recoPoint = recoProp.globalPosition();
738  xVal = recoPoint.x();
739  yVal = recoPoint.y();
740  zVal = recoPoint.z();
741  phiVal = recoPoint.phi();
742  etaVal = recoPoint.eta();
743  }
744  storage.muonLink_[recNum] = recNum;
745  storage.gpX_[recNum] = xVal;
746  storage.gpY_[recNum] = yVal;
747  storage.gpZ_[recNum] = zVal;
748  storage.gpEta_[recNum] = etaVal;
749  storage.gpPhi_[recNum] = phiVal;
750 
751  float rhoVal = sqrt(xVal * xVal + yVal * yVal);
752 
753  printf("Cylinder: rho = %4.2f\tphi = %4.2f\teta = %4.2f\n", rhoVal, phiVal, etaVal);
754  if (debug_)
755  printf("Cylinder: rho = %4.2f\tphi = %4.2f\teta = %4.2f\n", rhoVal, phiVal, etaVal);
756 }
T z() const
Definition: PV3DBase.h:61
Geom::Phi< T > phi() const
Definition: PV3DBase.h:66
T eta() const
Definition: PV3DBase.h:73
TrajectoryStateOnSurface propagate(STA const &state, SUR const &surface) const
Definition: Propagator.h:50
T x() const
Definition: PV3DBase.h:59
T y() const
Definition: PV3DBase.h:60
GlobalPoint globalPosition() const
T sqrt(T t)
Definition: SSEVec.h:19
FreeTrajectoryState freeTrajStateMuon(reco::TrackRef muon)
static CylinderPointer build(const PositionType &pos, const RotationType &rot, Scalar radius, Bounds *bounds=nullptr)
Definition: Cylinder.h:45
edm::ESHandle< Propagator > thePropagator

◆ dumpMuonRecHits()

void ResidualRefitting::dumpMuonRecHits ( const ResidualRefitting::storage_hit hit)

Definition at line 1137 of file ResidualRefitting.cc.

References mps_fire::i, and createfilelist::int.

1137  {
1138  edm::LogVerbatim("ResidualRefitting") << "Muon Rec Hits Dump:\n";
1139  for (unsigned int i = 0; i < (unsigned int)hit.n_; i++) {
1140  // double rho = sqrt( (float)hit.gpX_[i] * (float)hit.gpX_[i] + (float)hit.gpY_[i] * (float)hit.gpY_[i] );
1141 
1142  printf("%d\tsubdetector = %d\t superLayer =%d", i, (int)hit.system_[i], (int)hit.superLayer_[i]);
1143  // printf ("\tGlobal\tx = %0.3f" , (float)hit.gpX_[i] );
1144  // printf ("\ty = %0.3f" , (float)hit.gpY_[i] );
1145  // printf ("\tz = %0.3f" , (float)hit.gpZ_[i] );
1146  // printf ("\trho =%0.3f" , rho );
1147  // printf ("\teta = %0.3f" , (float)hit.gpEta_[i] );
1148  // printf ("\tphi = %0.3f\n" , (float)hit.gpPhi_[i] );
1149  printf("\t\tLocal\tx = %0.3f", (float)hit.lpX_[i]);
1150  printf("\ty = %0.3f", (float)hit.lpY_[i]);
1151  printf("\tz = %0.3f\n", (float)hit.lpZ_[i]);
1152  }
1153 }
Log< level::Info, true > LogVerbatim

◆ dumpTrackExtrap()

void ResidualRefitting::dumpTrackExtrap ( const ResidualRefitting::storage_trackExtrap track)

Definition at line 1116 of file ResidualRefitting.cc.

References mps_fire::i, createfilelist::int, and HLT_2024v10_cff::track.

1116  {
1117  edm::LogVerbatim("ResidualRefitting") << "\n\nExtrapolation Dump:\n";
1118  for (unsigned int i = 0; i < (unsigned int)track.n_; i++) {
1119  // double rho = sqrt( (float)track.gpX_[i] * (float)track.gpX_[i] + (float)track.gpY_[i] * (float)track.gpY_[i] );
1120 
1121  printf("%d\tmuonLink= %d", i, (int)track.muonLink_[i]);
1122  printf("\trecLink = %d", (int)track.recLink_[i]);
1123  // printf ("\tGlobal\tx = %0.3f" , (float)track.gpX_[i] );
1124  // printf ("\ty = %0.3f" , (float)track.gpY_[i] );
1125  // printf ("\tz = %0.3f" , (float)track.gpZ_[i] );
1126  // printf ("\trho =%0.3f" , rho );
1127  // printf ("\teta = %0.3f" , (float)track.gpEta_[i] );
1128  // printf ("\tphi = %0.3f" , (float)track.gpPhi_[i] );
1129  printf("\t\tLocal\tx = %0.3f", (float)track.lpX_[i]);
1130  printf("\ty = %0.3f", (float)track.lpY_[i]);
1131  printf("\tz = %0.3f\n", (float)track.lpZ_[i]);
1132  }
1133 }
Log< level::Info, true > LogVerbatim

◆ dumpTrackHits()

void ResidualRefitting::dumpTrackHits ( const ResidualRefitting::storage_trackHit hit)

Definition at line 1157 of file ResidualRefitting.cc.

References mps_fire::i, and createfilelist::int.

1157  {
1158  edm::LogVerbatim("ResidualRefitting") << "Tracker Rec Hits Dump:\n";
1159  for (unsigned int i = 0; i < (unsigned int)hit.n_; i++) {
1160  // double rho = sqrt( (float)hit.gpX_[i] * (float)hit.gpX_[i] + (float)hit.gpY_[i] * (float)hit.gpY_[i] );
1161 
1162  printf("%d\tsubdetector = %d", i, (int)hit.subdetector_[i]);
1163  printf("\tlayer = %d", (int)hit.layer_[i]);
1164  // printf ("\tGlobal\tx = %0.3f" , (float)hit.gpX_[i] );
1165  // printf ("\ty = %0.3f" , (float)hit.gpY_[i] );
1166  // printf ("\tz = %0.3f" , (float)hit.gpZ_[i] );
1167  // printf ("\trho =%0.3f" , rho );
1168  // printf ("\teta = %0.3f" , (float)hit.gpEta_[i] );
1169  // printf ("\tphi = %0.3f\n" , (float)hit.gpPhi_[i] );
1170  printf("\t\tLocal\tx = %0.3f", (float)hit.lpX_[i]);
1171  printf("\ty = %0.3f", (float)hit.lpY_[i]);
1172  printf("\tz = %0.3f\n", (float)hit.lpZ_[i]);
1173  }
1174 }
Log< level::Info, true > LogVerbatim

◆ dumpTrackRef()

void ResidualRefitting::dumpTrackRef ( reco::TrackRef  muon,
std::string  str 
)

Definition at line 1178 of file ResidualRefitting.cc.

References PVValHelper::eta, AlCaHLTBitMon_ParallelJobs::p, phi, DiDispStaMuonMonitor_cfi::pt, and str.

Referenced by analyze(), and CollectTrackHits().

1178  {
1179  float pt = muon->pt();
1180  float p = muon->p();
1181  float eta = muon->eta();
1182  float phi = muon->phi();
1183  printf("\t%s: \tp = %4.2f \t pt = %4.2f \t eta = %4.2f \t phi = %4.2f\n", str.c_str(), p, pt, eta, phi);
1184 }
#define str(s)

◆ endJob()

void ResidualRefitting::endJob ( void  )
overridevirtual

Reimplemented from edm::one::EDAnalyzerBase.

Definition at line 1086 of file ResidualRefitting.cc.

References outputFile_.

Referenced by o2olib.O2ORunMgr::executeJob().

1086  {
1087  outputFile_->Write();
1088 
1089  outputFile_->Close();
1090 }

◆ fillDescriptions()

void ResidualRefitting::fillDescriptions ( edm::ConfigurationDescriptions descriptions)
static

Definition at line 69 of file ResidualRefitting.cc.

References edm::ConfigurationDescriptions::add(), submitPVResolutionJobs::desc, ProducerED_cfi::InputTag, and AlCaHLTBitMon_QueryRunRegistry::string.

69  {
71  desc.add<edm::InputTag>("muons", edm::InputTag("muons"));
72  desc.add<edm::InputTag>("muonsRemake", edm::InputTag("globalMuons"));
73  desc.add<edm::InputTag>("muonsNoStation1", edm::InputTag("muonsNoSt1"));
74  desc.add<edm::InputTag>("muonsNoStation2", edm::InputTag("muonsNoSt2"));
75  desc.add<edm::InputTag>("muonsNoStation3", edm::InputTag("muonsNoSt3"));
76  desc.add<edm::InputTag>("muonsNoStation4", edm::InputTag("muonsNoSt4"));
77  desc.addUntracked<std::string>("histoutputFile", "histFile.root");
78  desc.addUntracked<bool>("doDebug", false);
79  descriptions.add("residualRefitting", desc);
80 }
void add(std::string const &label, ParameterSetDescription const &psetDescription)

◆ freeTrajStateMuon()

FreeTrajectoryState ResidualRefitting::freeTrajStateMuon ( reco::TrackRef  muon)

Definition at line 1094 of file ResidualRefitting.cc.

References debug_, and theField.

Referenced by CollectTrackHits(), cylExtrapTrkSam(), and NewTrackMeasurements().

1094  {
1095  math::XYZPoint innerPos = muon->referencePoint();
1096  math::XYZVector innerMom = muon->momentum();
1097  if (debug_)
1098  edm::LogVerbatim("ResidualRefitting")
1099  << "Inner Pos: "
1100  << "\tx = " << innerPos.X() << "\ty = " << innerPos.Y() << "\tz = " << innerPos.Z();
1101 
1102  GlobalPoint innerPoint(innerPos.X(), innerPos.Y(), innerPos.Z());
1103  GlobalVector innerVec(innerMom.X(), innerMom.Y(), innerMom.Z());
1104 
1105  FreeTrajectoryState recoStart(innerPoint, innerVec, muon->charge(), theField);
1106  return recoStart;
1107 }
Log< level::Info, true > LogVerbatim
const MagneticField * theField
XYZVectorD XYZVector
spatial vector with cartesian internal representation
Definition: Vector3D.h:31
XYZPointD XYZPoint
point in space with cartesian internal representation
Definition: Point3D.h:12

◆ IsSameHit()

bool ResidualRefitting::IsSameHit ( TrackingRecHit const &  hit1,
TrackingRecHit const &  hit2 
)

Definition at line 468 of file ResidualRefitting.cc.

References MillePedeFileConverter_cfg::e, TrackingRecHit::localPosition(), PV3DBase< T, PVType, FrameType >::x(), PV3DBase< T, PVType, FrameType >::y(), and PV3DBase< T, PVType, FrameType >::z().

Referenced by MatchTrackWithRecHits(), and NewTrackMeasurements().

468  {
469  double lpx1 = hit1.localPosition().x();
470  double lpy1 = hit1.localPosition().y();
471  double lpz1 = hit1.localPosition().z();
472 
473  double lpx2 = hit2.localPosition().x();
474  double lpy2 = hit2.localPosition().y();
475  double lpz2 = hit2.localPosition().z();
476  if (fabs(lpx1 - lpx2) > 1e-3)
477  return false;
478  // printf("Match lpx...\n");
479  if (fabs(lpy1 - lpy2) > 1e-3)
480  return false;
481  // printf("Match lpy...\n");
482  if (fabs(lpz1 - lpz2) > 1e-3)
483  return false;
484  // printf("Match lpz...\n");
485 
486  return true;
487 }

◆ MatchTrackWithRecHits()

int ResidualRefitting::MatchTrackWithRecHits ( reco::TrackCollection::const_iterator  trackIt,
edm::Handle< reco::TrackCollection ref 
)

Definition at line 402 of file ResidualRefitting.cc.

References debug_, beamvalidation::exit(), and IsSameHit().

Referenced by NewTrackMeasurements().

403  {
404  if (debug_)
405  printf("Matching a re-fitted track to the original track.\n");
406 
407  int TrackMatch = -1;
408 
409  for (auto const& rec : trackIt->recHits()) {
410  bool foundMatch = false;
411  for (reco::TrackCollection::const_iterator refIt = ref->begin(); refIt != ref->end(); refIt++) {
412  int iTrackMatch = refIt - ref->begin();
413  if (foundMatch && TrackMatch != iTrackMatch)
414  break;
415  for (auto const& recRef : refIt->recHits()) {
416  if (!IsSameHit(*rec, *recRef))
417  continue;
418 
419  foundMatch = true;
420  TrackMatch = iTrackMatch;
421  // printf("Rec hit match for original track %d\n", iTrackMatch);
422  }
423  }
424  if (!foundMatch) {
425  printf("SOMETHING WENT WRONG! Could not match Track with original track!");
426  exit(1);
427  }
428  }
429  if (debug_)
430  printf("Rec hit match for original track %d\n", TrackMatch);
431 
432  // reco::TrackRef trackref=reco::TrackRef(ref,TrackMatch);
433  return TrackMatch;
434 }
bool IsSameHit(TrackingRecHit const &hit1, TrackingRecHit const &hit2)
def exit(msg="")

◆ muonInfo()

void ResidualRefitting::muonInfo ( ResidualRefitting::storage_muon storeMuon,
reco::TrackRef  muon,
int  val 
)

Definition at line 585 of file ResidualRefitting.cc.

References ResidualRefitting::StorageMuon::charge_, ResidualRefitting::StorageMuon::chiSq_, ResidualRefitting::StorageMuon::chiSqOvrNdf_, ResidualRefitting::StorageMuon::eta_, ResidualRefitting::StorageMuon::ndf_, ResidualRefitting::StorageMuon::numRecHits_, ResidualRefitting::StorageMuon::p_, ResidualRefitting::StorageMuon::phi_, ResidualRefitting::StorageMuon::pt_, and heppy_batch::val.

Referenced by analyze().

585  {
586  storeMuon.pt_[val] = muon->pt();
587  storeMuon.p_[val] = muon->p();
588  storeMuon.eta_[val] = muon->eta();
589  storeMuon.phi_[val] = muon->phi();
590  storeMuon.charge_[val] = muon->charge();
591  storeMuon.numRecHits_[val] = muon->numberOfValidHits();
592  storeMuon.chiSq_[val] = muon->chi2();
593  storeMuon.ndf_[val] = muon->ndof();
594  storeMuon.chiSqOvrNdf_[val] = muon->normalizedChi2();
595 }
float chiSqOvrNdf_[N_MAX_STORED]

◆ NewTrackMeasurements()

void ResidualRefitting::NewTrackMeasurements ( const edm::Handle< reco::TrackCollection > &  trackCollOrig,
const edm::Handle< reco::TrackCollection > &  trackColl,
ResidualRefitting::storage_trackExtrap trackExtrap 
)

Definition at line 360 of file ResidualRefitting.cc.

References freeTrajStateMuon(), GlobalTrackingGeometry::idToDet(), IsSameHit(), MatchTrackWithRecHits(), ResidualRefitting::StorageTrackExtrap::n_, MuonTransientTrackingRecHit::specificBuild(), theService, pfDisplacedTrackerVertex_cfi::trackColl, MuonServiceProxy::trackingGeometry(), and trkExtrap().

Referenced by analyze().

362  {
363  int numTracks = 0;
364  int recCounter = 0;
365 
366  for (reco::TrackCollection::const_iterator muon = trackColl->begin(); muon != trackColl->end(); muon++) {
367  int iTrack = muon - trackColl->begin();
368 
369  reco::TrackRef trackref = reco::TrackRef(trackColl, iTrack);
371 
372  int iTrackLink = MatchTrackWithRecHits(muon, trackCollOrig);
373  reco::TrackRef ref = reco::TrackRef(trackCollOrig, iTrackLink);
374 
375  for (auto const& rec1 : ref->recHits()) {
376  bool unbiasedRec = true;
377 
378  for (auto const& rec2 : muon->recHits()) {
379  if (IsSameHit(*rec1, *rec2)) {
380  unbiasedRec = false;
381  break;
382  }
383  }
384  if (!unbiasedRec)
385  continue;
386 
387  DetId detid = rec1->geographicalId();
388 
390  theService->trackingGeometry()->idToDet(rec1->geographicalId()), rec1);
391 
392  trkExtrap(detid, numTracks, iTrackLink, recCounter, recoStart, rec1->localPosition(), trackExtrap);
393  numTracks++;
394  }
395  }
396 
397  trackExtrap.n_ = numTracks;
398 }
edm::ESHandle< GlobalTrackingGeometry > trackingGeometry() const
get the tracking geometry
bool IsSameHit(TrackingRecHit const &hit1, TrackingRecHit const &hit2)
const GeomDet * idToDet(DetId) const override
void trkExtrap(const DetId &detid, int iTrkLink, int iTrk, int iRec, const FreeTrajectoryState &freeTrajState, const LocalPoint &recPoint, storage_trackExtrap &storeTemp)
int MatchTrackWithRecHits(reco::TrackCollection::const_iterator trackIt, edm::Handle< reco::TrackCollection > ref)
MuonServiceProxy * theService
FreeTrajectoryState freeTrajStateMuon(reco::TrackRef muon)
Definition: DetId.h:17
edm::Ref< TrackCollection > TrackRef
persistent reference to a Track
Definition: TrackFwd.h:20
static MuonRecHitPointer specificBuild(const GeomDet *geom, const TrackingRecHit *rh)

◆ omitStation()

void ResidualRefitting::omitStation ( edm::Handle< reco::MuonCollection funcMuons,
edm::Handle< reco::TrackCollection ,
ResidualRefitting::storage_muon storeGmr,
ResidualRefitting::storage_muon storeSam,
ResidualRefitting::storage_trackExtrap storeExtrap,
int  omitStation 
)

◆ omitTrackerSystem()

void ResidualRefitting::omitTrackerSystem ( edm::Handle< reco::MuonCollection trkMuons,
ResidualRefitting::storage_muon storeGmr,
ResidualRefitting::storage_muon storeTrk,
ResidualRefitting::storage_trackExtrap storeExtrap,
int  omitSystem 
)

◆ ReturnSector()

int ResidualRefitting::ReturnSector ( DetId  detid)

Definition at line 699 of file ResidualRefitting.cc.

References DetId::det(), MuonSubdetId::DT, l1ctLayer2EG_cff::id, DetId::Muon, DetId::rawId(), nano_mu_digi_cff::sector, and DetId::subdetId().

Referenced by trkExtrap().

699  {
700  int sector = -999;
701 
702  if (detid.det() == DetId::Muon) {
703  int systemMuon = detid.subdetId(); // 1 DT; 2 CSC; 3 RPC
704  if (systemMuon == MuonSubdetId::DT) {
705  DTWireId id(detid.rawId());
706  sector = id.sector();
707  }
708  }
709 
710  return sector;
711 }
constexpr Detector det() const
get the detector field from this detid
Definition: DetId.h:46
constexpr int subdetId() const
get the contents of the subdetector field (not cast into any detector&#39;s numbering enum) ...
Definition: DetId.h:48
constexpr uint32_t rawId() const
get the raw id
Definition: DetId.h:57
static constexpr int DT
Definition: MuonSubdetId.h:11

◆ ReturnStation()

int ResidualRefitting::ReturnStation ( DetId  detid)

Definition at line 675 of file ResidualRefitting.cc.

References MuonSubdetId::CSC, DetId::det(), MuonSubdetId::DT, l1ctLayer2EG_cff::id, DetId::Muon, DetId::rawId(), MuonSubdetId::RPC, relativeConstraints::station, and DetId::subdetId().

Referenced by trkExtrap().

675  {
676  int station = -999;
677 
678  if (detid.det() == DetId::Muon) {
679  int systemMuon = detid.subdetId(); // 1 DT; 2 CSC; 3 RPC
680  if (systemMuon == MuonSubdetId::CSC) {
681  CSCDetId id(detid.rawId());
682  station = id.station();
683 
684  } else if (systemMuon == MuonSubdetId::DT) {
685  DTWireId id(detid.rawId());
686  station = id.station();
687 
688  } else if (systemMuon == MuonSubdetId::RPC) {
689  RPCDetId id(detid.rawId());
690  station = id.station();
691  }
692  }
693 
694  return station;
695 }
constexpr Detector det() const
get the detector field from this detid
Definition: DetId.h:46
constexpr int subdetId() const
get the contents of the subdetector field (not cast into any detector&#39;s numbering enum) ...
Definition: DetId.h:48
constexpr uint32_t rawId() const
get the raw id
Definition: DetId.h:57
static constexpr int RPC
Definition: MuonSubdetId.h:13
static constexpr int DT
Definition: MuonSubdetId.h:11
static constexpr int CSC
Definition: MuonSubdetId.h:12

◆ StoreTrackerRecHits()

void ResidualRefitting::StoreTrackerRecHits ( DetId  detid,
const TrackerTopology tTopo,
int  iTrack,
int  iRec 
)

Definition at line 492 of file ResidualRefitting.cc.

References ResidualRefitting::StorageTrackHit::blade_, debug_, DetId::det(), hgcalTestNeighbor_cfi::detector, ResidualRefitting::StorageTrackHit::detector_, ResidualRefitting::StorageTrackHit::disk_, PVValHelper::ladder, ResidualRefitting::StorageTrackHit::ladder_, nano_mu_digi_cff::layer, ResidualRefitting::StorageTrackHit::layer_, callgraph::module, ResidualRefitting::StorageTrackHit::module_, ResidualRefitting::StorageTrackHit::muonLink_, ResidualRefitting::StorageTrackHit::panel_, PXB, TrackerTopology::pxbLadder(), TrackerTopology::pxbLayer(), TrackerTopology::pxbModule(), PXF, TrackerTopology::pxfBlade(), TrackerTopology::pxfDisk(), TrackerTopology::pxfModule(), TrackerTopology::pxfPanel(), TrackerTopology::pxfSide(), DetId::rawId(), relativeConstraints::ring, ResidualRefitting::StorageTrackHit::ring_, ALPAKA_ACCELERATOR_NAMESPACE::ecal::reconstruction::internal::barrel::side(), ResidualRefitting::StorageTrackHit::side_, storageTrackHit_, subdetector, ResidualRefitting::StorageTrackHit::subdetector_, DetId::subdetId(), TEC, TrackerTopology::tecModule(), TrackerTopology::tecRing(), TIB, TrackerTopology::tibLayer(), TrackerTopology::tibModule(), TID, TrackerTopology::tidRing(), TrackerTopology::tidSide(), TrackerTopology::tidWheel(), TOB, TrackerTopology::tobLayer(), TrackerTopology::tobModule(), DetId::Tracker, makeMuonMisalignmentScenario::wheel, and ResidualRefitting::StorageTrackHit::wheel_.

Referenced by CollectTrackHits().

492  {
493  int detector = -1;
494  int subdetector = -1;
495  int blade = -1;
496  int disk = -1;
497  int ladder = -1;
498  int layer = -1;
499  int module = -1;
500  int panel = -1;
501  int ring = -1;
502  int side = -1;
503  int wheel = -1;
504 
505  //Detector Info
506 
507  detector = detid.det();
508  subdetector = detid.subdetId();
509 
510  if (detector != DetId::Tracker) {
511  edm::LogVerbatim("ResidualRefitting") << "OMFG NOT THE TRACKER\n";
512  return;
513  }
514 
515  if (debug_)
516  edm::LogVerbatim("ResidualRefitting") << "Tracker:: ";
518  layer = tTopo->pxbLayer(detid.rawId());
519  ladder = tTopo->pxbLadder(detid.rawId());
520  module = tTopo->pxbModule(detid.rawId());
521  if (debug_)
522  edm::LogVerbatim("ResidualRefitting")
523  << "PXB"
524  << "\tlayer = " << layer << "\tladder = " << ladder << "\tmodule = " << module;
525 
526  } else if (subdetector == ResidualRefitting::PXF) {
527  side = tTopo->pxfSide(detid.rawId());
528  disk = tTopo->pxfDisk(detid.rawId());
529  blade = tTopo->pxfBlade(detid.rawId());
530  panel = tTopo->pxfPanel(detid.rawId());
531  module = tTopo->pxfModule(detid.rawId());
532  if (debug_)
533  edm::LogVerbatim("ResidualRefitting") << "PXF"
534  << "\tside = " << side << "\tdisk = " << disk << "\tblade = " << blade
535  << "\tpanel = " << panel << "\tmodule = " << module;
536 
537  } else if (subdetector == ResidualRefitting::TIB) {
538  layer = tTopo->tibLayer(detid.rawId());
539  module = tTopo->tibModule(detid.rawId());
540  if (debug_)
541  edm::LogVerbatim("ResidualRefitting") << "TIB"
542  << "\tlayer = " << layer << "\tmodule = " << module;
543  } else if (subdetector == ResidualRefitting::TID) {
544  side = tTopo->tidSide(detid.rawId());
545  wheel = tTopo->tidWheel(detid.rawId());
546  ring = tTopo->tidRing(detid.rawId());
547  if (debug_)
548  edm::LogVerbatim("ResidualRefitting") << "TID"
549  << "\tside = " << side << "\twheel = " << wheel << "\tring = " << ring;
550 
551  } else if (subdetector == ResidualRefitting::TOB) {
552  layer = tTopo->tobLayer(detid.rawId());
553  module = tTopo->tobModule(detid.rawId());
554  if (debug_)
555  edm::LogVerbatim("ResidualRefitting") << "TOB"
556  << "\tlayer = " << layer << "\tmodule = " << module;
557 
558  } else if (subdetector == ResidualRefitting::TEC) {
559  ring = tTopo->tecRing(detid.rawId());
560  module = tTopo->tecModule(detid.rawId());
561  if (debug_)
562  edm::LogVerbatim("ResidualRefitting") << "TEC"
563  << "\tring = " << ring << "\tmodule = " << module;
564  }
565 
566  //Do Storage
567 
568  storageTrackHit_.muonLink_[iRec] = iTrack;
571  storageTrackHit_.blade_[iRec] = blade;
572  storageTrackHit_.disk_[iRec] = disk;
574  storageTrackHit_.layer_[iRec] = layer;
576  storageTrackHit_.panel_[iRec] = panel;
577  storageTrackHit_.ring_[iRec] = ring;
578  storageTrackHit_.side_[iRec] = side;
579  storageTrackHit_.wheel_[iRec] = wheel;
580 }
Log< level::Info, true > LogVerbatim
static const int TIB
unsigned int tobLayer(const DetId &id) const
unsigned int pxbLayer(const DetId &id) const
unsigned int pxfBlade(const DetId &id) const
unsigned int tibModule(const DetId &id) const
unsigned int tidSide(const DetId &id) const
TString subdetector
unsigned int pxfModule(const DetId &id) const
static const int PXB
ResidualRefitting::storage_trackHit storageTrackHit_
unsigned int tidWheel(const DetId &id) const
static const int TOB
unsigned int pxbLadder(const DetId &id) const
constexpr Detector det() const
get the detector field from this detid
Definition: DetId.h:46
unsigned int tecRing(const DetId &id) const
ring id
static const int TEC
static const int TID
unsigned int tecModule(const DetId &id) const
unsigned int pxfDisk(const DetId &id) const
constexpr int subdetId() const
get the contents of the subdetector field (not cast into any detector&#39;s numbering enum) ...
Definition: DetId.h:48
unsigned int pxfPanel(const DetId &id) const
unsigned int pxfSide(const DetId &id) const
constexpr uint32_t rawId() const
get the raw id
Definition: DetId.h:57
static const int PXF
unsigned int tidRing(const DetId &id) const
unsigned int tibLayer(const DetId &id) const
unsigned int tobModule(const DetId &id) const
unsigned int pxbModule(const DetId &id) const

◆ trkExtrap()

void ResidualRefitting::trkExtrap ( const DetId detid,
int  iTrkLink,
int  iTrk,
int  iRec,
const FreeTrajectoryState freeTrajState,
const LocalPoint recPoint,
storage_trackExtrap storeTemp 
)

Definition at line 599 of file ResidualRefitting.cc.

References debug_, DetId::det(), PV3DBase< T, PVType, FrameType >::eta(), TrajectoryStateOnSurface::globalPosition(), ResidualRefitting::StorageTrackExtrap::gpEta_, ResidualRefitting::StorageTrackExtrap::gpPhi_, ResidualRefitting::StorageTrackExtrap::gpX_, ResidualRefitting::StorageTrackExtrap::gpY_, ResidualRefitting::StorageTrackExtrap::gpZ_, GlobalTrackingGeometry::idToDet(), TrajectoryStateOnSurface::isValid(), TrajectoryStateOnSurface::localPosition(), ResidualRefitting::StorageTrackExtrap::lpX_, ResidualRefitting::StorageTrackExtrap::lpY_, ResidualRefitting::StorageTrackExtrap::lpZ_, DetId::Muon, ResidualRefitting::StorageTrackExtrap::muonLink_, PV3DBase< T, PVType, FrameType >::phi(), Propagator::propagate(), ResidualRefitting::StorageTrackExtrap::recLink_, ResidualRefitting::StorageTrackExtrap::resX_, ResidualRefitting::StorageTrackExtrap::resY_, ResidualRefitting::StorageTrackExtrap::resZ_, ReturnSector(), ReturnStation(), GeomDet::surface(), thePropagator, theService, DetId::Tracker, MuonServiceProxy::trackingGeometry(), PV3DBase< T, PVType, FrameType >::x(), PV3DBase< T, PVType, FrameType >::y(), and PV3DBase< T, PVType, FrameType >::z().

Referenced by CollectTrackHits(), and NewTrackMeasurements().

605  {
606  bool dump_ = debug_;
607 
608  if (dump_)
609  edm::LogVerbatim("ResidualRefitting") << "In the trkExtrap function";
610 
611  float gpExtrapX = -99999;
612  float gpExtrapY = -99999;
613  float gpExtrapZ = -99999;
614  float gpExtrapEta = -99999;
615  float gpExtrapPhi = -99999;
616 
617  float lpX = -99999;
618  float lpY = -99999;
619  float lpZ = -99999;
620 
621  //
622  // Get the local positions for the recHits
623  //
624 
625  float recLpX = recPoint.x();
626  float recLpY = recPoint.y();
627  float recLpZ = recPoint.z();
628 
629  float resX = -9999;
630  float resY = -9999;
631  float resZ = -9999;
632 
633  const GeomDet* gdet = theService->trackingGeometry()->idToDet(detid);
634 
635  // TrajectoryStateOnSurface surfTest = prop.propagate(freeTrajState, gdet->surface());
636  TrajectoryStateOnSurface surfTest = thePropagator->propagate(freeTrajState, gdet->surface());
637 
638  if (surfTest.isValid()) {
639  GlobalPoint globTest = surfTest.globalPosition();
640  gpExtrapX = globTest.x();
641  gpExtrapY = globTest.y();
642  gpExtrapZ = globTest.z();
643  gpExtrapEta = globTest.eta();
644  gpExtrapPhi = globTest.phi();
645  LocalPoint loc = surfTest.localPosition();
646  if (detid.det() == DetId::Muon || detid.det() == DetId::Tracker) {
647  lpX = loc.x();
648  lpY = loc.y();
649  lpZ = loc.z();
650 
651  resX = lpX - recLpX;
652  resY = lpY - recLpY;
653  resZ = lpZ - recLpZ;
654  }
655  }
656  storeTemp.muonLink_[iTrk] = iTrkLink;
657  storeTemp.recLink_[iTrk] = iRec;
658  storeTemp.gpX_[iTrk] = gpExtrapX;
659  storeTemp.gpY_[iTrk] = gpExtrapY;
660  storeTemp.gpZ_[iTrk] = gpExtrapZ;
661  storeTemp.gpEta_[iTrk] = gpExtrapEta;
662  storeTemp.gpPhi_[iTrk] = gpExtrapPhi;
663  storeTemp.lpX_[iTrk] = lpX;
664  storeTemp.lpY_[iTrk] = lpY;
665  storeTemp.lpZ_[iTrk] = lpZ;
666  storeTemp.resX_[iTrk] = resX;
667  storeTemp.resY_[iTrk] = resY;
668  storeTemp.resZ_[iTrk] = resZ;
669 
670  printf("station: %d\tsector: %d\tresX storage: %4.2f\n", ReturnStation(detid), ReturnSector(detid), resX);
671 }
Log< level::Info, true > LogVerbatim
edm::ESHandle< GlobalTrackingGeometry > trackingGeometry() const
get the tracking geometry
int ReturnStation(DetId detid)
T z() const
Definition: PV3DBase.h:61
Geom::Phi< T > phi() const
Definition: PV3DBase.h:66
int ReturnSector(DetId detid)
T eta() const
Definition: PV3DBase.h:73
TrajectoryStateOnSurface propagate(STA const &state, SUR const &surface) const
Definition: Propagator.h:50
const GeomDet * idToDet(DetId) const override
constexpr Detector det() const
get the detector field from this detid
Definition: DetId.h:46
T x() const
Definition: PV3DBase.h:59
T y() const
Definition: PV3DBase.h:60
GlobalPoint globalPosition() const
MuonServiceProxy * theService
const Plane & surface() const
The nominal surface of the GeomDet.
Definition: GeomDet.h:37
edm::ESHandle< Propagator > thePropagator

◆ zero_muon()

void ResidualRefitting::zero_muon ( ResidualRefitting::storage_muon str)

Definition at line 864 of file ResidualRefitting.cc.

References mps_fire::i, N_MAX_STORED, and str.

Referenced by zero_storage().

864  {
865  str->n_ = 0;
866 
867  for (int i = 0; i < ResidualRefitting::N_MAX_STORED; i++) {
868  str->pt_[i] = -9999;
869  str->eta_[i] = -9999;
870  str->p_[i] = -9999;
871  str->phi_[i] = -9999;
872  str->numRecHits_[i] = -9999;
873  str->chiSq_[i] = -9999;
874  str->ndf_[i] = -9999;
875  str->chiSqOvrNdf_[i] = -9999;
876  }
877 }
static const int N_MAX_STORED
#define str(s)

◆ zero_storage()

void ResidualRefitting::zero_storage ( )

Definition at line 764 of file ResidualRefitting.cc.

References debug_, ResidualRefitting::StorageHit::n_, ResidualRefitting::StorageTrackHit::n_, samExtrap120_, storageGmrNew_, storageGmrNoPXBLayer1, storageGmrNoPXBLayer2, storageGmrNoPXBLayer3, storageGmrNoPXF, storageGmrNoSt1_, storageGmrNoSt2_, storageGmrNoSt3_, storageGmrNoSt4_, storageGmrNoTEC, storageGmrNoTIBLayer1, storageGmrNoTIBLayer2, storageGmrNoTIBLayer3, storageGmrNoTIBLayer4, storageGmrNoTID, storageGmrNoTOBLayer1, storageGmrNoTOBLayer2, storageGmrNoTOBLayer3, storageGmrNoTOBLayer4, storageGmrNoTOBLayer5, storageGmrNoTOBLayer6, storageGmrOld_, storageRecMuon_, storageSamNew_, storageSamNoSt1_, storageSamNoSt2_, storageSamNoSt3_, storageSamNoSt4_, storageTrackExtrapRec_, storageTrackExtrapRecNoSt1_, storageTrackExtrapRecNoSt2_, storageTrackExtrapRecNoSt3_, storageTrackExtrapRecNoSt4_, storageTrackExtrapTracker_, storageTrackHit_, storageTrackNoPXBLayer1, storageTrackNoPXBLayer2, storageTrackNoPXBLayer3, storageTrackNoPXF, storageTrackNoTEC, storageTrackNoTIBLayer1, storageTrackNoTIBLayer2, storageTrackNoTIBLayer3, storageTrackNoTIBLayer4, storageTrackNoTID, storageTrackNoTOBLayer1, storageTrackNoTOBLayer2, storageTrackNoTOBLayer3, storageTrackNoTOBLayer4, storageTrackNoTOBLayer5, storageTrackNoTOBLayer6, storageTrkNew_, storageTrkNoPXBLayer1, storageTrkNoPXBLayer2, storageTrkNoPXBLayer3, storageTrkNoPXF, storageTrkNoTEC, storageTrkNoTIBLayer1, storageTrkNoTIBLayer2, storageTrkNoTIBLayer3, storageTrkNoTIBLayer4, storageTrkNoTID, storageTrkNoTOBLayer1, storageTrkNoTOBLayer2, storageTrkNoTOBLayer3, storageTrkNoTOBLayer4, storageTrkNoTOBLayer5, storageTrkNoTOBLayer6, trackExtrap120_, zero_muon(), and zero_trackExtrap().

Referenced by analyze().

764  {
765  if (debug_)
766  printf("zero_storage\n");
767 
780  //zero out the tracker
784 
786 
791 
793 
800 
802 
806 
808 
813 
815 
822 
824 
831 
833 
835 
839 
841 
846 
853 
855 
857 
858  storageRecMuon_.n_ = 0;
859  storageTrackHit_.n_ = 0;
860 }
ResidualRefitting::storage_muon storageGmrNoTIBLayer4
ResidualRefitting::storage_muon storageTrkNoTOBLayer4
void zero_muon(ResidualRefitting::storage_muon *str)
ResidualRefitting::storage_muon storageGmrNoTOBLayer1
ResidualRefitting::storage_trackExtrap storageTrackNoTEC
ResidualRefitting::storage_muon storageGmrNoPXBLayer1
ResidualRefitting::storage_trackExtrap storageTrackNoPXBLayer1
ResidualRefitting::storage_muon storageGmrNoTID
ResidualRefitting::storage_muon storageTrkNoTOBLayer6
ResidualRefitting::storage_muon storageGmrNoTIBLayer1
ResidualRefitting::storage_trackHit storageTrackHit_
void zero_trackExtrap(ResidualRefitting::storage_trackExtrap *str)
ResidualRefitting::storage_trackExtrap storageTrackExtrapRecNoSt3_
ResidualRefitting::storage_muon storageTrkNoTOBLayer5
ResidualRefitting::storage_trackExtrap storageTrackNoTIBLayer2
ResidualRefitting::storage_trackExtrap storageTrackNoTIBLayer4
ResidualRefitting::storage_muon storageTrkNoTIBLayer2
ResidualRefitting::storage_muon storageGmrNoTOBLayer2
ResidualRefitting::storage_muon storageGmrNoSt1_
ResidualRefitting::storage_trackExtrap storageTrackNoTOBLayer6
ResidualRefitting::storage_trackExtrap storageTrackExtrapRecNoSt1_
ResidualRefitting::storage_muon storageGmrNoTOBLayer6
ResidualRefitting::storage_muon storageSamNew_
ResidualRefitting::storage_trackExtrap storageTrackNoTOBLayer4
ResidualRefitting::storage_muon storageTrkNoTID
ResidualRefitting::storage_trackExtrap storageTrackExtrapTracker_
ResidualRefitting::storage_trackExtrap storageTrackExtrapRec_
ResidualRefitting::storage_muon storageGmrNoTOBLayer4
ResidualRefitting::storage_muon storageGmrNoSt4_
ResidualRefitting::storage_trackExtrap storageTrackExtrapRecNoSt4_
ResidualRefitting::storage_trackExtrap storageTrackNoTOBLayer2
ResidualRefitting::storage_muon storageSamNoSt4_
ResidualRefitting::storage_trackExtrap storageTrackExtrapRecNoSt2_
ResidualRefitting::storage_muon storageTrkNoPXBLayer2
ResidualRefitting::storage_muon storageGmrNoSt2_
ResidualRefitting::storage_muon storageGmrNoSt3_
ResidualRefitting::storage_muon storageGmrNoPXBLayer2
ResidualRefitting::storage_muon storageGmrOld_
ResidualRefitting::storage_muon storageTrkNoPXF
ResidualRefitting::storage_muon storageGmrNoTEC
ResidualRefitting::storage_trackExtrap trackExtrap120_
ResidualRefitting::storage_muon storageGmrNoTIBLayer3
ResidualRefitting::storage_muon storageGmrNew_
ResidualRefitting::storage_muon storageGmrNoTIBLayer2
ResidualRefitting::storage_muon storageTrkNoTIBLayer3
ResidualRefitting::storage_trackExtrap storageTrackNoTID
ResidualRefitting::storage_muon storageTrkNoTOBLayer2
ResidualRefitting::storage_trackExtrap storageTrackNoPXBLayer3
ResidualRefitting::storage_trackExtrap storageTrackNoTOBLayer5
ResidualRefitting::storage_muon storageSamNoSt2_
ResidualRefitting::storage_trackExtrap storageTrackNoTOBLayer3
ResidualRefitting::storage_muon storageTrkNoTOBLayer1
ResidualRefitting::storage_muon storageGmrNoPXBLayer3
ResidualRefitting::storage_muon storageTrkNoTEC
ResidualRefitting::storage_muon storageSamNoSt3_
ResidualRefitting::storage_muon storageTrkNoPXBLayer1
ResidualRefitting::storage_muon storageTrkNoTIBLayer1
ResidualRefitting::storage_muon storageGmrNoTOBLayer3
ResidualRefitting::storage_trackExtrap storageTrackNoTIBLayer1
ResidualRefitting::storage_hit storageRecMuon_
ResidualRefitting::storage_muon storageTrkNoTOBLayer3
ResidualRefitting::storage_muon storageTrkNew_
ResidualRefitting::storage_trackExtrap storageTrackNoPXF
ResidualRefitting::storage_muon storageSamNoSt1_
ResidualRefitting::storage_muon storageGmrNoTOBLayer5
ResidualRefitting::storage_trackExtrap storageTrackNoTIBLayer3
ResidualRefitting::storage_trackExtrap storageTrackNoTOBLayer1
ResidualRefitting::storage_muon storageGmrNoPXF
ResidualRefitting::storage_trackExtrap storageTrackNoPXBLayer2
ResidualRefitting::storage_muon storageTrkNoPXBLayer3
ResidualRefitting::storage_muon storageTrkNoTIBLayer4
ResidualRefitting::storage_trackExtrap samExtrap120_

◆ zero_trackExtrap()

void ResidualRefitting::zero_trackExtrap ( ResidualRefitting::storage_trackExtrap str)

Definition at line 881 of file ResidualRefitting.cc.

References mps_fire::i, N_MAX_STORED_HIT, and str.

Referenced by zero_storage().

881  {
882  str->n_ = 0;
883  for (int i = 0; i < ResidualRefitting::N_MAX_STORED_HIT; i++) {
884  str->muonLink_[i] = -9999;
885  str->recLink_[i] = -9999;
886  str->gpX_[i] = -9999;
887  str->gpY_[i] = -9999;
888  str->gpZ_[i] = -9999;
889  str->gpEta_[i] = -9999;
890  str->gpPhi_[i] = -9999;
891  str->lpX_[i] = -9999;
892  str->lpY_[i] = -9999;
893  str->lpZ_[i] = -9999;
894  str->resX_[i] = -9999;
895  str->resY_[i] = -9999;
896  str->resZ_[i] = -9999;
897  }
898 }
static const int N_MAX_STORED_HIT
#define str(s)

Member Data Documentation

◆ debug_

const bool ResidualRefitting::debug_

◆ eventInfo_

ResidualRefitting::storage_event ResidualRefitting::eventInfo_

Definition at line 53 of file ResidualRefitting.h.

Referenced by analyze(), beginJob(), and ResidualRefitting().

◆ magFieldToken_

const edm::ESGetToken<MagneticField, IdealMagneticFieldRecord> ResidualRefitting::magFieldToken_

Definition at line 319 of file ResidualRefitting.h.

Referenced by analyze().

◆ muons_

const edm::InputTag ResidualRefitting::muons_

Definition at line 330 of file ResidualRefitting.h.

◆ muonsNoSt1Token_

const edm::EDGetTokenT<reco::TrackCollection> ResidualRefitting::muonsNoSt1Token_

Definition at line 336 of file ResidualRefitting.h.

Referenced by analyze().

◆ muonsNoSt2Token_

const edm::EDGetTokenT<reco::TrackCollection> ResidualRefitting::muonsNoSt2Token_

Definition at line 337 of file ResidualRefitting.h.

Referenced by analyze().

◆ muonsNoSt3Token_

const edm::EDGetTokenT<reco::TrackCollection> ResidualRefitting::muonsNoSt3Token_

Definition at line 338 of file ResidualRefitting.h.

Referenced by analyze().

◆ muonsNoSt4Token_

const edm::EDGetTokenT<reco::TrackCollection> ResidualRefitting::muonsNoSt4Token_

Definition at line 339 of file ResidualRefitting.h.

Referenced by analyze().

◆ muonsNoStation1_

const edm::InputTag ResidualRefitting::muonsNoStation1_

Definition at line 330 of file ResidualRefitting.h.

◆ muonsNoStation2_

const edm::InputTag ResidualRefitting::muonsNoStation2_

Definition at line 330 of file ResidualRefitting.h.

◆ muonsNoStation3_

const edm::InputTag ResidualRefitting::muonsNoStation3_

Definition at line 330 of file ResidualRefitting.h.

◆ muonsNoStation4_

const edm::InputTag ResidualRefitting::muonsNoStation4_

Definition at line 330 of file ResidualRefitting.h.

◆ muonsRemake_

const edm::InputTag ResidualRefitting::muonsRemake_

Definition at line 330 of file ResidualRefitting.h.

◆ muonsToken_

const edm::EDGetTokenT<reco::MuonCollection> ResidualRefitting::muonsToken_

Definition at line 334 of file ResidualRefitting.h.

Referenced by analyze().

◆ muonTracksToken_

const edm::EDGetTokenT<reco::TrackCollection> ResidualRefitting::muonTracksToken_

Definition at line 335 of file ResidualRefitting.h.

Referenced by analyze().

◆ N_MAX_STORED

const int ResidualRefitting::N_MAX_STORED = 10
staticprivate

◆ N_MAX_STORED_HIT

const int ResidualRefitting::N_MAX_STORED_HIT = 1000
staticprivate

◆ outputBranch_

TBranch* ResidualRefitting::outputBranch_

Definition at line 345 of file ResidualRefitting.h.

Referenced by analyze(), beginJob(), branchMuon(), and branchTrackExtrap().

◆ outputFile_

TFile* ResidualRefitting::outputFile_

Definition at line 342 of file ResidualRefitting.h.

Referenced by beginJob(), endJob(), and ~ResidualRefitting().

◆ outputFileName_

std::string ResidualRefitting::outputFileName_

Definition at line 325 of file ResidualRefitting.h.

Referenced by beginJob().

◆ outputTree_

TTree* ResidualRefitting::outputTree_

Definition at line 344 of file ResidualRefitting.h.

Referenced by analyze(), beginJob(), branchMuon(), and branchTrackExtrap().

◆ PropagatorSource_

std::string ResidualRefitting::PropagatorSource_

Definition at line 327 of file ResidualRefitting.h.

◆ propagatorToken_

const edm::ESGetToken<Propagator, TrackingComponentsRecord> ResidualRefitting::propagatorToken_

Definition at line 322 of file ResidualRefitting.h.

Referenced by analyze().

◆ PXB

const int ResidualRefitting::PXB = 1
staticprivate

Definition at line 37 of file ResidualRefitting.h.

Referenced by StoreTrackerRecHits().

◆ PXF

const int ResidualRefitting::PXF = 2
staticprivate

Definition at line 38 of file ResidualRefitting.h.

Referenced by StoreTrackerRecHits().

◆ samExtrap120_

ResidualRefitting::storage_trackExtrap ResidualRefitting::samExtrap120_

Definition at line 242 of file ResidualRefitting.h.

Referenced by analyze(), beginJob(), and zero_storage().

◆ storageGmrNew_

ResidualRefitting::storage_muon ResidualRefitting::storageGmrNew_

Definition at line 218 of file ResidualRefitting.h.

Referenced by analyze(), beginJob(), and zero_storage().

◆ storageGmrNoPXBLayer1

ResidualRefitting::storage_muon ResidualRefitting::storageGmrNoPXBLayer1

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageGmrNoPXBLayer2

ResidualRefitting::storage_muon ResidualRefitting::storageGmrNoPXBLayer2

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageGmrNoPXBLayer3

ResidualRefitting::storage_muon ResidualRefitting::storageGmrNoPXBLayer3

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageGmrNoPXF

ResidualRefitting::storage_muon ResidualRefitting::storageGmrNoPXF

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageGmrNoSt1_

ResidualRefitting::storage_muon ResidualRefitting::storageGmrNoSt1_

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageGmrNoSt2_

ResidualRefitting::storage_muon ResidualRefitting::storageGmrNoSt2_

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageGmrNoSt3_

ResidualRefitting::storage_muon ResidualRefitting::storageGmrNoSt3_

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageGmrNoSt4_

ResidualRefitting::storage_muon ResidualRefitting::storageGmrNoSt4_

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageGmrNoTEC

ResidualRefitting::storage_muon ResidualRefitting::storageGmrNoTEC

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageGmrNoTIBLayer1

ResidualRefitting::storage_muon ResidualRefitting::storageGmrNoTIBLayer1

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageGmrNoTIBLayer2

ResidualRefitting::storage_muon ResidualRefitting::storageGmrNoTIBLayer2

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageGmrNoTIBLayer3

ResidualRefitting::storage_muon ResidualRefitting::storageGmrNoTIBLayer3

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageGmrNoTIBLayer4

ResidualRefitting::storage_muon ResidualRefitting::storageGmrNoTIBLayer4

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageGmrNoTID

ResidualRefitting::storage_muon ResidualRefitting::storageGmrNoTID

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageGmrNoTOBLayer1

ResidualRefitting::storage_muon ResidualRefitting::storageGmrNoTOBLayer1

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageGmrNoTOBLayer2

ResidualRefitting::storage_muon ResidualRefitting::storageGmrNoTOBLayer2

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageGmrNoTOBLayer3

ResidualRefitting::storage_muon ResidualRefitting::storageGmrNoTOBLayer3

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageGmrNoTOBLayer4

ResidualRefitting::storage_muon ResidualRefitting::storageGmrNoTOBLayer4

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageGmrNoTOBLayer5

ResidualRefitting::storage_muon ResidualRefitting::storageGmrNoTOBLayer5

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageGmrNoTOBLayer6

ResidualRefitting::storage_muon ResidualRefitting::storageGmrNoTOBLayer6

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageGmrOld_

ResidualRefitting::storage_muon ResidualRefitting::storageGmrOld_

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageRecMuon_

ResidualRefitting::storage_hit ResidualRefitting::storageRecMuon_

Definition at line 234 of file ResidualRefitting.h.

Referenced by beginJob(), CollectTrackHits(), and zero_storage().

◆ storageSamNew_

ResidualRefitting::storage_muon ResidualRefitting::storageSamNew_

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageSamNoSt1_

ResidualRefitting::storage_muon ResidualRefitting::storageSamNoSt1_

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageSamNoSt2_

ResidualRefitting::storage_muon ResidualRefitting::storageSamNoSt2_

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageSamNoSt3_

ResidualRefitting::storage_muon ResidualRefitting::storageSamNoSt3_

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageSamNoSt4_

ResidualRefitting::storage_muon ResidualRefitting::storageSamNoSt4_

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrackExtrapRec_

ResidualRefitting::storage_trackExtrap ResidualRefitting::storageTrackExtrapRec_

Definition at line 238 of file ResidualRefitting.h.

Referenced by analyze(), beginJob(), and zero_storage().

◆ storageTrackExtrapRecNoSt1_

ResidualRefitting::storage_trackExtrap ResidualRefitting::storageTrackExtrapRecNoSt1_

Definition at line 238 of file ResidualRefitting.h.

Referenced by analyze(), beginJob(), and zero_storage().

◆ storageTrackExtrapRecNoSt2_

ResidualRefitting::storage_trackExtrap ResidualRefitting::storageTrackExtrapRecNoSt2_

Definition at line 238 of file ResidualRefitting.h.

Referenced by analyze(), beginJob(), and zero_storage().

◆ storageTrackExtrapRecNoSt3_

ResidualRefitting::storage_trackExtrap ResidualRefitting::storageTrackExtrapRecNoSt3_

Definition at line 238 of file ResidualRefitting.h.

Referenced by analyze(), beginJob(), and zero_storage().

◆ storageTrackExtrapRecNoSt4_

ResidualRefitting::storage_trackExtrap ResidualRefitting::storageTrackExtrapRecNoSt4_

Definition at line 238 of file ResidualRefitting.h.

Referenced by analyze(), beginJob(), and zero_storage().

◆ storageTrackExtrapTracker_

ResidualRefitting::storage_trackExtrap ResidualRefitting::storageTrackExtrapTracker_

Definition at line 245 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrackHit_

ResidualRefitting::storage_trackHit ResidualRefitting::storageTrackHit_

Definition at line 235 of file ResidualRefitting.h.

Referenced by beginJob(), CollectTrackHits(), StoreTrackerRecHits(), and zero_storage().

◆ storageTrackNoPXBLayer1

ResidualRefitting::storage_trackExtrap ResidualRefitting::storageTrackNoPXBLayer1

Definition at line 245 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrackNoPXBLayer2

ResidualRefitting::storage_trackExtrap ResidualRefitting::storageTrackNoPXBLayer2

Definition at line 245 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrackNoPXBLayer3

ResidualRefitting::storage_trackExtrap ResidualRefitting::storageTrackNoPXBLayer3

Definition at line 245 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrackNoPXF

ResidualRefitting::storage_trackExtrap ResidualRefitting::storageTrackNoPXF

Definition at line 245 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrackNoTEC

ResidualRefitting::storage_trackExtrap ResidualRefitting::storageTrackNoTEC

Definition at line 245 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrackNoTIBLayer1

ResidualRefitting::storage_trackExtrap ResidualRefitting::storageTrackNoTIBLayer1

Definition at line 245 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrackNoTIBLayer2

ResidualRefitting::storage_trackExtrap ResidualRefitting::storageTrackNoTIBLayer2

Definition at line 245 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrackNoTIBLayer3

ResidualRefitting::storage_trackExtrap ResidualRefitting::storageTrackNoTIBLayer3

Definition at line 245 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrackNoTIBLayer4

ResidualRefitting::storage_trackExtrap ResidualRefitting::storageTrackNoTIBLayer4

Definition at line 245 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrackNoTID

ResidualRefitting::storage_trackExtrap ResidualRefitting::storageTrackNoTID

Definition at line 245 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrackNoTOBLayer1

ResidualRefitting::storage_trackExtrap ResidualRefitting::storageTrackNoTOBLayer1

Definition at line 245 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrackNoTOBLayer2

ResidualRefitting::storage_trackExtrap ResidualRefitting::storageTrackNoTOBLayer2

Definition at line 245 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrackNoTOBLayer3

ResidualRefitting::storage_trackExtrap ResidualRefitting::storageTrackNoTOBLayer3

Definition at line 245 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrackNoTOBLayer4

ResidualRefitting::storage_trackExtrap ResidualRefitting::storageTrackNoTOBLayer4

Definition at line 245 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrackNoTOBLayer5

ResidualRefitting::storage_trackExtrap ResidualRefitting::storageTrackNoTOBLayer5

Definition at line 245 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrackNoTOBLayer6

ResidualRefitting::storage_trackExtrap ResidualRefitting::storageTrackNoTOBLayer6

Definition at line 245 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrkNew_

ResidualRefitting::storage_muon ResidualRefitting::storageTrkNew_

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrkNoPXBLayer1

ResidualRefitting::storage_muon ResidualRefitting::storageTrkNoPXBLayer1

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrkNoPXBLayer2

ResidualRefitting::storage_muon ResidualRefitting::storageTrkNoPXBLayer2

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrkNoPXBLayer3

ResidualRefitting::storage_muon ResidualRefitting::storageTrkNoPXBLayer3

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrkNoPXF

ResidualRefitting::storage_muon ResidualRefitting::storageTrkNoPXF

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrkNoTEC

ResidualRefitting::storage_muon ResidualRefitting::storageTrkNoTEC

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrkNoTIBLayer1

ResidualRefitting::storage_muon ResidualRefitting::storageTrkNoTIBLayer1

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrkNoTIBLayer2

ResidualRefitting::storage_muon ResidualRefitting::storageTrkNoTIBLayer2

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrkNoTIBLayer3

ResidualRefitting::storage_muon ResidualRefitting::storageTrkNoTIBLayer3

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrkNoTIBLayer4

ResidualRefitting::storage_muon ResidualRefitting::storageTrkNoTIBLayer4

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrkNoTID

ResidualRefitting::storage_muon ResidualRefitting::storageTrkNoTID

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrkNoTOBLayer1

ResidualRefitting::storage_muon ResidualRefitting::storageTrkNoTOBLayer1

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrkNoTOBLayer2

ResidualRefitting::storage_muon ResidualRefitting::storageTrkNoTOBLayer2

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrkNoTOBLayer3

ResidualRefitting::storage_muon ResidualRefitting::storageTrkNoTOBLayer3

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrkNoTOBLayer4

ResidualRefitting::storage_muon ResidualRefitting::storageTrkNoTOBLayer4

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrkNoTOBLayer5

ResidualRefitting::storage_muon ResidualRefitting::storageTrkNoTOBLayer5

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ storageTrkNoTOBLayer6

ResidualRefitting::storage_muon ResidualRefitting::storageTrkNoTOBLayer6

Definition at line 218 of file ResidualRefitting.h.

Referenced by beginJob(), and zero_storage().

◆ TEC

const int ResidualRefitting::TEC = 6
staticprivate

Definition at line 42 of file ResidualRefitting.h.

Referenced by StoreTrackerRecHits().

◆ theField

const MagneticField* ResidualRefitting::theField

Definition at line 349 of file ResidualRefitting.h.

Referenced by analyze(), and freeTrajStateMuon().

◆ thePropagator

edm::ESHandle<Propagator> ResidualRefitting::thePropagator

Definition at line 352 of file ResidualRefitting.h.

Referenced by analyze(), cylExtrapTrkSam(), and trkExtrap().

◆ theService

MuonServiceProxy* ResidualRefitting::theService

◆ TIB

const int ResidualRefitting::TIB = 3
staticprivate

Definition at line 39 of file ResidualRefitting.h.

Referenced by StoreTrackerRecHits().

◆ TID

const int ResidualRefitting::TID = 4
staticprivate

Definition at line 40 of file ResidualRefitting.h.

Referenced by StoreTrackerRecHits().

◆ TOB

const int ResidualRefitting::TOB = 5
staticprivate

Definition at line 41 of file ResidualRefitting.h.

Referenced by StoreTrackerRecHits().

◆ topoToken_

const edm::ESGetToken<TrackerTopology, TrackerTopologyRcd> ResidualRefitting::topoToken_

Definition at line 320 of file ResidualRefitting.h.

Referenced by CollectTrackHits().

◆ trackExtrap120_

ResidualRefitting::storage_trackExtrap ResidualRefitting::trackExtrap120_

Definition at line 242 of file ResidualRefitting.h.

Referenced by analyze(), beginJob(), and zero_storage().

◆ trackingGeometry

const edm::ESHandle<GlobalTrackingGeometry> ResidualRefitting::trackingGeometry

Definition at line 350 of file ResidualRefitting.h.

◆ trackingGeometryToken_

const edm::ESGetToken<GlobalTrackingGeometry, GlobalTrackingGeometryRecord> ResidualRefitting::trackingGeometryToken_

Definition at line 321 of file ResidualRefitting.h.

Referenced by analyze().

◆ tracks_

const edm::InputTag ResidualRefitting::tracks_

Definition at line 330 of file ResidualRefitting.h.