CMS 3D CMS Logo

L1MuGMTDebugBlock.h
Go to the documentation of this file.
1 //-------------------------------------------------
2 //
3 // \class L1MuGMTDebugBlock
11 //
12 //
13 // Author :
14 // H. Sakulin HEPHY Vienna
15 //
16 // Migrated to CMSSW:
17 // I. Mikulec
18 //
19 //--------------------------------------------------
20 #ifndef L1TriggerGlobalMuonTrigger_L1MuGMTDebugBlock_h
21 #define L1TriggerGlobalMuonTrigger_L1MuGMTDebugBlock_h
22 
23 //---------------
24 // C++ Headers --
25 //---------------
26 
27 #include <vector>
28 
29 //----------------------
30 // Base Class Headers --
31 //----------------------
32 
33 //------------------------------------
34 // Collaborating Class Declarations --
35 //------------------------------------
38 
40 
41 // ---------------------
42 // -- Class Interface --
43 // ---------------------
44 
46 public:
47  static const int NumMatrices = 6;
48 
50  L1MuGMTDebugBlock(int minbx = -10, int maxbx = 10);
51 
53  virtual ~L1MuGMTDebugBlock();
54 
56  void reset();
57 
59  void SetBX(int bx) {
60  if (bx < _minbx || bx > _maxbx)
61  edm::LogWarning("RangeViolation") << "L1MuGMTDebugBlock::SetBX(): bx out of range ";
62  else
63  _bx = bx;
64  };
65 
66  // index: (0..31: 16*isFWD + 8*isISO + 4* isRPC + nr )
67 
69  void SetPhi(int idx, float phi) { _prophi[_bx - _minbx][idx] = phi; };
70 
72  void SetEta(int idx, float eta) { _proeta[_bx - _minbx][idx] = eta; };
73 
75  void SetPhiSelBits(int idx, unsigned phisel) { _phisel[_bx - _minbx][idx] = phisel; };
76 
78  void SetEtaSelBits(int idx, unsigned etasel) { _etasel[_bx - _minbx][idx] = etasel; };
79 
81  void SetIsMIPISO(int idx, unsigned ismipiso) { _isMIPISO[_bx - _minbx][idx] = ismipiso; };
82 
85 
87  void SetMQMatrix(int idx, L1MuGMTMatrix<int> mqm) { _mqMatrices[_bx - _minbx][idx] = mqm; };
88 
90  void SetCancelBits(int idx, const std::vector<bool>& mine, const std::vector<bool>& others);
91 
94 
97 
99  float Phi(int bx, int idx) { return _prophi[bx - _minbx][idx]; };
100 
102  float Eta(int bx, int idx) { return _proeta[bx - _minbx][idx]; };
103 
105  unsigned PhiSel(int bx, int idx) { return _phisel[bx - _minbx][idx]; };
106 
108  unsigned EtaSel(int bx, int idx) { return _etasel[bx - _minbx][idx]; };
109 
111  unsigned IsMIPISO(int bx, int idx) { return _isMIPISO[bx - _minbx][idx]; };
112 
115 
118 
120  unsigned GetCancelBits(int bx, int idx) { return _cancelbits[bx - _minbx][idx]; };
121 
123  L1MuGMTExtendedCand const& GetBrlGMTCand(int bx, int idx) { return _brlmuons[bx - _minbx][idx]; }
124 
126  L1MuGMTExtendedCand const& GetFwdGMTCand(int bx, int idx) { return _fwdmuons[bx - _minbx][idx]; }
127 
129  float Phi(int bx, int isFWD, int isISO, int isRPC, int nr) {
130  return _prophi[bx - _minbx][16 * isFWD + 8 * isISO + 4 * isRPC + nr];
131  };
132 
134  float Eta(int bx, int isFWD, int isISO, int isRPC, int nr) {
135  return _proeta[bx - _minbx][16 * isFWD + 8 * isISO + 4 * isRPC + nr];
136  };
137 
138 private:
139  const int _minbx, _maxbx;
140  int _bx;
141  std::vector<std::vector<float> > _prophi;
142  std::vector<std::vector<float> > _proeta;
143  std::vector<std::vector<unsigned> > _phisel;
144  std::vector<std::vector<unsigned> > _etasel;
145  std::vector<std::vector<unsigned> > _isMIPISO;
146 
147  std::vector<std::vector<L1MuGMTMatrix<bool> > > _pairMatrices;
148  std::vector<std::vector<L1MuGMTMatrix<int> > > _mqMatrices;
149 
150  std::vector<std::vector<unsigned> > _cancelbits;
151  std::vector<std::vector<L1MuGMTExtendedCand> > _brlmuons;
152  std::vector<std::vector<L1MuGMTExtendedCand> > _fwdmuons;
153 };
154 
155 #endif
MessageLogger.h
L1MuGMTExtendedCand
Definition: L1MuGMTExtendedCand.h:46
L1MuGMTDebugBlock::_minbx
const int _minbx
Definition: L1MuGMTDebugBlock.h:136
L1MuGMTDebugBlock::_pairMatrices
std::vector< std::vector< L1MuGMTMatrix< bool > > > _pairMatrices
Definition: L1MuGMTDebugBlock.h:147
GeomDetEnumerators::isRPC
bool isRPC(GeomDetEnumerators::SubDetector m)
Definition: GeomDetEnumerators.cc:90
L1MuGMTDebugBlock::_fwdmuons
std::vector< std::vector< L1MuGMTExtendedCand > > _fwdmuons
Definition: L1MuGMTDebugBlock.h:152
l1GtPatternGenerator_cfi.bx
bx
Definition: l1GtPatternGenerator_cfi.py:18
L1MuGMTDebugBlock::_proeta
std::vector< std::vector< float > > _proeta
Definition: L1MuGMTDebugBlock.h:142
L1MuGMTDebugBlock::SetBrlGMTCands
void SetBrlGMTCands(int idx, L1MuGMTExtendedCand const &cand)
Set brl GMT Cands.
Definition: L1MuGMTDebugBlock.h:93
L1MuGMTDebugBlock::_phisel
std::vector< std::vector< unsigned > > _phisel
Definition: L1MuGMTDebugBlock.h:143
L1MuGMTDebugBlock::GetCancelBits
unsigned GetCancelBits(int bx, int idx)
Get Cancel Bits.
Definition: L1MuGMTDebugBlock.h:120
L1MuGMTDebugBlock::GetFwdGMTCand
L1MuGMTExtendedCand const & GetFwdGMTCand(int bx, int idx)
Get fwd Cands.
Definition: L1MuGMTDebugBlock.h:126
L1MuGMTDebugBlock
Definition: L1MuGMTDebugBlock.h:45
L1MuGMTDebugBlock::EtaSel
unsigned EtaSel(int bx, int idx)
Get stored eta select bits.
Definition: L1MuGMTDebugBlock.h:108
edm::LogWarning
Log< level::Warning, false > LogWarning
Definition: MessageLogger.h:122
L1MuGMTDebugBlock::SetPairMatrix
void SetPairMatrix(int idx, L1MuGMTMatrix< bool > pm)
Set pair matrices.
Definition: L1MuGMTDebugBlock.h:84
heavyIonCSV_trainingSettings.idx
idx
Definition: heavyIonCSV_trainingSettings.py:5
L1MuGMTDebugBlock::_cancelbits
std::vector< std::vector< unsigned > > _cancelbits
Definition: L1MuGMTDebugBlock.h:150
L1MuGMTMatrix.h
L1MuGMTDebugBlock::SetCancelBits
void SetCancelBits(int idx, const std::vector< bool > &mine, const std::vector< bool > &others)
Set cancel bits.
Definition: L1MuGMTDebugBlock.cc:81
L1MuGMTDebugBlock::Phi
float Phi(int bx, int idx)
Get stored phi position.
Definition: L1MuGMTDebugBlock.h:99
PVValHelper::eta
Definition: PVValidationHelpers.h:69
L1MuGMTDebugBlock::SetEta
void SetEta(int idx, float eta)
Set projected eta positions for current bx.
Definition: L1MuGMTDebugBlock.h:72
L1MuGMTDebugBlock::SetEtaSelBits
void SetEtaSelBits(int idx, unsigned etasel)
Set eta select bits for current bx.
Definition: L1MuGMTDebugBlock.h:78
L1MuGMTDebugBlock::_brlmuons
std::vector< std::vector< L1MuGMTExtendedCand > > _brlmuons
Definition: L1MuGMTDebugBlock.h:151
EgHLTOffHistBins_cfi.nr
nr
Definition: EgHLTOffHistBins_cfi.py:4
L1MuGMTDebugBlock::Eta
float Eta(int bx, int isFWD, int isISO, int isRPC, int nr)
Get stored eta position, four indices.
Definition: L1MuGMTDebugBlock.h:134
L1MuGMTDebugBlock::GetMQMatrix
L1MuGMTMatrix< int > GetMQMatrix(int bx, int idx)
Get match quality matrices.
Definition: L1MuGMTDebugBlock.h:117
L1MuGMTDebugBlock::_prophi
std::vector< std::vector< float > > _prophi
Definition: L1MuGMTDebugBlock.h:141
cand
Definition: decayParser.h:32
L1MuGMTDebugBlock::PhiSel
unsigned PhiSel(int bx, int idx)
Get stored phi select bits.
Definition: L1MuGMTDebugBlock.h:105
L1MuGMTDebugBlock::SetPhi
void SetPhi(int idx, float phi)
Set projected phi positions for current bx.
Definition: L1MuGMTDebugBlock.h:69
L1MuGMTDebugBlock::_isMIPISO
std::vector< std::vector< unsigned > > _isMIPISO
Definition: L1MuGMTDebugBlock.h:145
L1MuGMTDebugBlock::SetIsMIPISO
void SetIsMIPISO(int idx, unsigned ismipiso)
Set MIP/ISO bits for current bx.
Definition: L1MuGMTDebugBlock.h:81
L1MuGMTDebugBlock::IsMIPISO
unsigned IsMIPISO(int bx, int idx)
Get stored MIP/ISO select bits.
Definition: L1MuGMTDebugBlock.h:111
L1MuGMTDebugBlock::~L1MuGMTDebugBlock
virtual ~L1MuGMTDebugBlock()
destructor
Definition: L1MuGMTDebugBlock.cc:60
L1MuGMTDebugBlock::SetPhiSelBits
void SetPhiSelBits(int idx, unsigned phisel)
Set phi select bits for current bx.
Definition: L1MuGMTDebugBlock.h:75
L1MuGMTDebugBlock::SetMQMatrix
void SetMQMatrix(int idx, L1MuGMTMatrix< int > mqm)
Set match quality matrices.
Definition: L1MuGMTDebugBlock.h:87
DDAxes::phi
L1MuGMTDebugBlock::GetPairMatrix
L1MuGMTMatrix< bool > GetPairMatrix(int bx, int idx)
Get pair matrices.
Definition: L1MuGMTDebugBlock.h:114
L1MuGMTDebugBlock::GetBrlGMTCand
L1MuGMTExtendedCand const & GetBrlGMTCand(int bx, int idx)
Get brl Cands.
Definition: L1MuGMTDebugBlock.h:123
L1MuGMTDebugBlock::L1MuGMTDebugBlock
L1MuGMTDebugBlock(int minbx=-10, int maxbx=10)
constructor
Definition: L1MuGMTDebugBlock.cc:34
L1MuGMTDebugBlock::_bx
int _bx
Definition: L1MuGMTDebugBlock.h:140
L1MuGMTDebugBlock::reset
void reset()
Reset the debug block.
Definition: L1MuGMTDebugBlock.cc:102
L1MuGMTDebugBlock::_etasel
std::vector< std::vector< unsigned > > _etasel
Definition: L1MuGMTDebugBlock.h:144
L1MuGMTDebugBlock::NumMatrices
static const int NumMatrices
Definition: L1MuGMTDebugBlock.h:47
L1MuGMTDebugBlock::SetFwdGMTCands
void SetFwdGMTCands(int idx, L1MuGMTExtendedCand const &cand)
Set fwd GMT Cands.
Definition: L1MuGMTDebugBlock.h:96
L1MuGMTExtendedCand.h
L1MuGMTMatrix< bool >
L1MuGMTDebugBlock::_mqMatrices
std::vector< std::vector< L1MuGMTMatrix< int > > > _mqMatrices
Definition: L1MuGMTDebugBlock.h:148
L1MuGMTDebugBlock::SetBX
void SetBX(int bx)
Set the current bunch crossing.
Definition: L1MuGMTDebugBlock.h:59
L1MuGMTDebugBlock::Eta
float Eta(int bx, int idx)
Get stored eta position.
Definition: L1MuGMTDebugBlock.h:102
L1MuGMTDebugBlock::Phi
float Phi(int bx, int isFWD, int isISO, int isRPC, int nr)
Get stored phi position, four indices.
Definition: L1MuGMTDebugBlock.h:129
L1MuGMTDebugBlock::_maxbx
const int _maxbx
Definition: L1MuGMTDebugBlock.h:136