CMS 3D CMS Logo

List of all members | Public Types | Public Member Functions | Private Attributes
L1Analysis::L1AnalysisL1UpgradeTfMuon Class Reference

#include <L1AnalysisL1UpgradeTfMuon.h>

Public Types

enum  { TEST = 0 }
 

Public Member Functions

L1AnalysisL1UpgradeTfMuonDataFormatgetData ()
 
 L1AnalysisL1UpgradeTfMuon ()
 
void Reset ()
 
void SetRun3Muons ()
 
void SetTfMuon (const l1t::RegionalMuonCandBxCollection &muon, unsigned maxL1UpgradeTfMuon)
 
 ~L1AnalysisL1UpgradeTfMuon ()
 

Private Attributes

bool isRun3_ {false}
 
L1AnalysisL1UpgradeTfMuonDataFormat l1upgradetfmuon_
 

Detailed Description

Definition at line 9 of file L1AnalysisL1UpgradeTfMuon.h.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
Enumerator
TEST 

Definition at line 11 of file L1AnalysisL1UpgradeTfMuon.h.

Constructor & Destructor Documentation

◆ L1AnalysisL1UpgradeTfMuon()

L1Analysis::L1AnalysisL1UpgradeTfMuon::L1AnalysisL1UpgradeTfMuon ( )

Definition at line 3 of file L1AnalysisL1UpgradeTfMuon.cc.

3 {}

◆ ~L1AnalysisL1UpgradeTfMuon()

L1Analysis::L1AnalysisL1UpgradeTfMuon::~L1AnalysisL1UpgradeTfMuon ( )

Definition at line 5 of file L1AnalysisL1UpgradeTfMuon.cc.

5 {}

Member Function Documentation

◆ getData()

L1AnalysisL1UpgradeTfMuonDataFormat* L1Analysis::L1AnalysisL1UpgradeTfMuon::getData ( void  )
inline

Definition at line 20 of file L1AnalysisL1UpgradeTfMuon.h.

References l1upgradetfmuon_.

Referenced by L1UpgradeTfMuonTreeProducer::L1UpgradeTfMuonTreeProducer().

20 { return &l1upgradetfmuon_; }
L1AnalysisL1UpgradeTfMuonDataFormat l1upgradetfmuon_

◆ Reset()

void L1Analysis::L1AnalysisL1UpgradeTfMuon::Reset ( )
inline

◆ SetRun3Muons()

void L1Analysis::L1AnalysisL1UpgradeTfMuon::SetRun3Muons ( )
inline

◆ SetTfMuon()

void L1Analysis::L1AnalysisL1UpgradeTfMuon::SetTfMuon ( const l1t::RegionalMuonCandBxCollection muon,
unsigned  maxL1UpgradeTfMuon 
)

Definition at line 7 of file L1AnalysisL1UpgradeTfMuon.cc.

References l1t::bmtf, l1t::MicroGMTConfiguration::calcGlobalPhi(), l1t::emtf_neg, l1t::emtf_pos, l1t::RegionalMuonRawDigiTranslator::generateRawTrkAddress(), ALPAKA_ACCELERATOR_NAMESPACE::vertexFinder::it, l1t::RegionalMuonCand::kBX, l1t::RegionalMuonCand::kLayers, l1t::RegionalMuonCand::kME1Ch, l1t::RegionalMuonCand::kME1Seg, l1t::RegionalMuonCand::kME2Ch, l1t::RegionalMuonCand::kME2Seg, l1t::RegionalMuonCand::kME3Ch, l1t::RegionalMuonCand::kME3Seg, l1t::RegionalMuonCand::kME4Ch, l1t::RegionalMuonCand::kME4Seg, l1t::RegionalMuonCand::kStat1, l1t::RegionalMuonCand::kStat2, l1t::RegionalMuonCand::kStat3, l1t::RegionalMuonCand::kStat4, l1t::RegionalMuonCand::kTrkNum, l1t::RegionalMuonCand::kWeight, l1t::RegionalMuonCand::kWheelNum, l1t::RegionalMuonCand::kWheelSide, l1UpgradeTfMuonTree_cfi::maxL1UpgradeTfMuon, l1t::omtf_neg, l1t::omtf_pos, funct::pow(), and makeMuonMisalignmentScenario::wheel.

Referenced by L1UpgradeTfMuonTreeProducer::analyze().

8  {
9  for (int ibx = muon.getFirstBX(); ibx <= muon.getLastBX(); ++ibx) {
12  ++it) {
13  if (it->hwPt() > 0) {
14  l1upgradetfmuon_.tfMuonHwPt.push_back(it->hwPt());
15  if (isRun3_) {
16  l1upgradetfmuon_.tfMuonHwPtUnconstrained.push_back(it->hwPtUnconstrained());
17  l1upgradetfmuon_.tfMuonHwDxy.push_back(it->hwDXY());
18  }
19  l1upgradetfmuon_.tfMuonHwEta.push_back(it->hwEta());
20  l1upgradetfmuon_.tfMuonHwPhi.push_back(it->hwPhi());
22  l1t::MicroGMTConfiguration::calcGlobalPhi(it->hwPhi(), it->trackFinderType(), it->processor()));
23  l1upgradetfmuon_.tfMuonHwSign.push_back(it->hwSign());
24  l1upgradetfmuon_.tfMuonHwSignValid.push_back(it->hwSignValid());
25  l1upgradetfmuon_.tfMuonHwQual.push_back(it->hwQual());
26  l1upgradetfmuon_.tfMuonLink.push_back(it->link());
27  l1upgradetfmuon_.tfMuonProcessor.push_back(it->processor());
28  l1upgradetfmuon_.tfMuonTrackFinderType.push_back(it->trackFinderType());
29  l1upgradetfmuon_.tfMuonHwHF.push_back(it->hwHF());
30  l1upgradetfmuon_.tfMuonBx.push_back(ibx);
31  std::map<std::string, int> decoded_track_address;
32  if (it->trackFinderType() == l1t::tftype::bmtf) {
33  int detSide = it->trackSubAddress(l1t::RegionalMuonCand::kWheelSide);
34  int wheelNum = it->trackSubAddress(l1t::RegionalMuonCand::kWheelNum);
35  int stat1 = it->trackSubAddress(l1t::RegionalMuonCand::kStat1);
36  int stat2 = it->trackSubAddress(l1t::RegionalMuonCand::kStat2);
37  int stat3 = it->trackSubAddress(l1t::RegionalMuonCand::kStat3);
38  int stat4 = it->trackSubAddress(l1t::RegionalMuonCand::kStat4);
39 
40  int wheel = pow(-1, detSide) * wheelNum;
41  l1upgradetfmuon_.tfMuonWh.push_back(wheel);
42  l1upgradetfmuon_.tfMuonTrAdd.push_back(stat1);
43  l1upgradetfmuon_.tfMuonTrAdd.push_back(stat2);
44  l1upgradetfmuon_.tfMuonTrAdd.push_back(stat3);
45  l1upgradetfmuon_.tfMuonTrAdd.push_back(stat4);
46  decoded_track_address["wheel"] = wheel;
47  decoded_track_address["station1"] = stat1;
48  decoded_track_address["station2"] = stat2;
49  decoded_track_address["station3"] = stat3;
50  decoded_track_address["station4"] = stat4;
51  } else if (it->trackFinderType() == l1t::omtf_neg || it->trackFinderType() == l1t::omtf_pos) {
52  decoded_track_address["kLayers"] = it->trackSubAddress(l1t::RegionalMuonCand::kLayers);
53  decoded_track_address["kWeight"] = it->trackSubAddress(l1t::RegionalMuonCand::kWeight);
54  } else if (it->trackFinderType() == l1t::emtf_neg || it->trackFinderType() == l1t::emtf_pos) {
55  decoded_track_address["kME1Seg"] = it->trackSubAddress(l1t::RegionalMuonCand::kME1Seg);
56  decoded_track_address["kME1Ch"] = it->trackSubAddress(l1t::RegionalMuonCand::kME1Ch);
57  decoded_track_address["kME2Seg"] = it->trackSubAddress(l1t::RegionalMuonCand::kME2Seg);
58  decoded_track_address["kME2Ch"] = it->trackSubAddress(l1t::RegionalMuonCand::kME2Ch);
59  decoded_track_address["kME3Seg"] = it->trackSubAddress(l1t::RegionalMuonCand::kME3Seg);
60  decoded_track_address["kME3Ch"] = it->trackSubAddress(l1t::RegionalMuonCand::kME3Ch);
61  decoded_track_address["kME4Seg"] = it->trackSubAddress(l1t::RegionalMuonCand::kME4Seg);
62  decoded_track_address["kME4Ch"] = it->trackSubAddress(l1t::RegionalMuonCand::kME4Ch);
63  decoded_track_address["kTrkNum"] = it->trackSubAddress(l1t::RegionalMuonCand::kTrkNum);
64  decoded_track_address["kBX"] = it->trackSubAddress(l1t::RegionalMuonCand::kBX);
65  }
66  l1upgradetfmuon_.tfMuonDecodedTrAdd.push_back(decoded_track_address);
70  }
71  }
72  }
73 }
L1AnalysisL1UpgradeTfMuonDataFormat l1upgradetfmuon_
std::vector< RegionalMuonCand >::const_iterator const_iterator
Definition: BXVector.h:18
static int calcGlobalPhi(int locPhi, tftype t, int proc)
static int generateRawTrkAddress(const RegionalMuonCand &, bool isKalman)
std::vector< std::map< std::string, int > > tfMuonDecodedTrAdd
Power< A, B >::type pow(const A &a, const B &b)
Definition: Power.h:29

Member Data Documentation

◆ isRun3_

bool L1Analysis::L1AnalysisL1UpgradeTfMuon::isRun3_ {false}
private

Definition at line 24 of file L1AnalysisL1UpgradeTfMuon.h.

Referenced by Reset(), and SetRun3Muons().

◆ l1upgradetfmuon_

L1AnalysisL1UpgradeTfMuonDataFormat L1Analysis::L1AnalysisL1UpgradeTfMuon::l1upgradetfmuon_
private

Definition at line 23 of file L1AnalysisL1UpgradeTfMuon.h.

Referenced by getData(), and Reset().