CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
L1TMuonBarrelKalmanRegionModule Class Reference

#include <L1TMuonBarrelKalmanRegionModule.h>

Public Member Functions

 L1TMuonBarrelKalmanRegionModule (const edm::ParameterSet &, int wheel, int sector)
 
L1MuKBMTrackCollection process (L1TMuonBarrelKalmanAlgo *, const L1MuKBMTCombinedStubRefVector &stubs, int bx)
 
 ~L1TMuonBarrelKalmanRegionModule ()
 

Private Attributes

int nextSector_
 
int nextWheel_
 
int previousSector_
 
int sector_
 
int verbose_
 
int wheel_
 

Detailed Description

Definition at line 8 of file L1TMuonBarrelKalmanRegionModule.h.

Constructor & Destructor Documentation

L1TMuonBarrelKalmanRegionModule::L1TMuonBarrelKalmanRegionModule ( const edm::ParameterSet iConfig,
int  wheel,
int  sector 
)

Definition at line 5 of file L1TMuonBarrelKalmanRegionModule.cc.

References nextSector_, nextWheel_, and previousSector_.

5  :
6  verbose_(iConfig.getParameter<int>("verbose")),
7  sector_(sector),
9 {
10 
11  if (sector==11) {
12  nextSector_=0;
13  previousSector_ = 10;
14  }
15  else if (sector==0) {
16  nextSector_=1;
17  previousSector_ = 11;
18  }
19  else {
20  nextSector_= sector+1;
21  previousSector_ = sector-1;
22  }
23 
24  switch(wheel) {
25 
26  case -2:
27  nextWheel_=-1;
28  break;
29 
30  case -1:
31  nextWheel_=0;
32  break;
33 
34  case 0:
35  nextWheel_=999;
36  break;
37 
38  case 1:
39  nextWheel_=0;
40  break;
41 
42  case 2:
43  nextWheel_=1;
44  break;
45 
46  default:
47  nextWheel_=999;
48  break;
49  }
50 }
T getParameter(std::string const &) const
L1TMuonBarrelKalmanRegionModule::~L1TMuonBarrelKalmanRegionModule ( )

Definition at line 54 of file L1TMuonBarrelKalmanRegionModule.cc.

54 {}

Member Function Documentation

L1MuKBMTrackCollection L1TMuonBarrelKalmanRegionModule::process ( L1TMuonBarrelKalmanAlgo trackMaker,
const L1MuKBMTCombinedStubRefVector stubs,
int  bx 
)

Definition at line 56 of file L1TMuonBarrelKalmanRegionModule.cc.

References L1TMuonBarrelKalmanAlgo::chain(), L1TMuonBarrelKalmanAlgo::cleanAndSort(), createfilelist::int, nextSector_, nextWheel_, MillePedeFileConverter_cfg::out, previousSector_, sector_, SurveyInfoScenario_cff::seed, verbose_, and wheel_.

56  {
59  L1MuKBMTrackCollection pretracks;
60  for (const auto& stub : stubsAll) {
61  if (stub->bxNum()!=bx)
62  continue;
63 
64  if ((stub->scNum()==nextSector_ && stub->phi()>=-112)||(stub->scNum()==previousSector_ && stub->phi()<=111))
65  continue;
66 
67  if (stub->whNum()==wheel_ && stub->scNum()==sector_) {
68  seeds.push_back(stub);
69  stubs.push_back(stub);
70  }
71  else if (stub->whNum()==wheel_ && (stub->scNum()==nextSector_||stub->scNum()==previousSector_ )) {
72  stubs.push_back(stub);
73  }
74  else if (stub->whNum()==nextWheel_ && (stub->scNum()==nextSector_||stub->scNum()==previousSector_||stub->scNum()==sector_) ) {
75  stubs.push_back(stub);
76  }
77  }
78 
79  for (const auto seed : seeds) {
80  std::pair<bool,L1MuKBMTrack> trackInfo = trackMaker->chain(seed,stubs);
81  if (trackInfo.first)
82  pretracks.push_back(trackInfo.second);
83  }
84 
85  // trackMaker->resolveEtaUnit(pretracks);
86  L1MuKBMTrackCollection out =trackMaker->cleanAndSort(pretracks,2);
87  if (verbose_) {
88  printf(" -----Sector Processor Kalman Tracks-----\n");
89  for (const auto& track1 :out)
90  printf("Kalman Track charge=%d pt=%f eta=%f phi=%f curvature=%d curvature STA =%d stubs=%d chi2=%d pts=%f %f\n",track1.charge(),track1.pt(),track1.eta(),track1.phi(),track1.curvatureAtVertex(),track1.curvatureAtMuon(),int(track1.stubs().size()),track1.approxChi2(),track1.pt(),track1.ptUnconstrained());
91  }
92 
93 
94  return out;
95 }
std::vector< edm::Ref< L1MuKBMTCombinedStubCollection > > L1MuKBMTCombinedStubRefVector
std::pair< bool, L1MuKBMTrack > chain(const L1MuKBMTCombinedStubRef &, const L1MuKBMTCombinedStubRefVector &)
L1MuKBMTrackCollection cleanAndSort(const L1MuKBMTrackCollection &, uint)
std::vector< L1MuKBMTrack > L1MuKBMTrackCollection
Definition: L1MuKBMTrack.h:15

Member Data Documentation

int L1TMuonBarrelKalmanRegionModule::nextSector_
private

Definition at line 19 of file L1TMuonBarrelKalmanRegionModule.h.

Referenced by L1TMuonBarrelKalmanRegionModule(), and process().

int L1TMuonBarrelKalmanRegionModule::nextWheel_
private

Definition at line 21 of file L1TMuonBarrelKalmanRegionModule.h.

Referenced by L1TMuonBarrelKalmanRegionModule(), and process().

int L1TMuonBarrelKalmanRegionModule::previousSector_
private

Definition at line 20 of file L1TMuonBarrelKalmanRegionModule.h.

Referenced by L1TMuonBarrelKalmanRegionModule(), and process().

int L1TMuonBarrelKalmanRegionModule::sector_
private

Definition at line 17 of file L1TMuonBarrelKalmanRegionModule.h.

Referenced by process().

int L1TMuonBarrelKalmanRegionModule::verbose_
private

Definition at line 16 of file L1TMuonBarrelKalmanRegionModule.h.

Referenced by process().

int L1TMuonBarrelKalmanRegionModule::wheel_
private

Definition at line 18 of file L1TMuonBarrelKalmanRegionModule.h.

Referenced by process().