#include <L1MuGMTSortRankUnit.h>
Public Member Functions | |
L1MuGMTSortRankUnit () | |
constructor | |
virtual | ~L1MuGMTSortRankUnit () |
destructor | |
Static Public Member Functions | |
static unsigned | getVeryLowQualityLevel (const L1MuRegionalCand *) |
Very low quality bits. | |
static bool | isDisabled (const L1MuRegionalCand *) |
Diable bit. | |
static unsigned | sort_rank (const L1MuRegionalCand *) |
Sort Rank Table. |
L1 Global Muon Trigger Sort Rank Unit.
Return sort rank based on look-up-tables.
Definition at line 45 of file L1MuGMTSortRankUnit.h.
L1MuGMTSortRankUnit::L1MuGMTSortRankUnit | ( | ) |
constructor
virtual L1MuGMTSortRankUnit::~L1MuGMTSortRankUnit | ( | ) | [virtual] |
destructor
unsigned L1MuGMTSortRankUnit::getVeryLowQualityLevel | ( | const L1MuRegionalCand * | muon | ) | [static] |
Very low quality bits.
Definition at line 75 of file L1MuGMTSortRankUnit.cc.
References L1MuRegionalCand::empty(), eta, L1MuRegionalCand::eta_packed(), L1MuGMTConfig::getLFSortRankEtaQLUT(), lumiQueryAPI::q, L1MuRegionalCand::quality_packed(), L1MuGMTLFSortRankEtaQLUT::SpecificLookup_vlq(), and L1MuRegionalCand::type_idx().
Referenced by L1MuGMTMerger::createDTCSCCand(), and L1MuGMTMerger::createRPCCand().
{ if ( muon == 0 || muon->empty() ) return 0; unsigned lut_idx= muon->type_idx(); // obtain inputs as coded in HW unsigned eta = muon->eta_packed(); unsigned q = muon->quality_packed(); // lookup eta-q L1MuGMTLFSortRankEtaQLUT* etaq_lut = L1MuGMTConfig::getLFSortRankEtaQLUT(); return etaq_lut->SpecificLookup_vlq (lut_idx, eta, q); }
bool L1MuGMTSortRankUnit::isDisabled | ( | const L1MuRegionalCand * | muon | ) | [static] |
Diable bit.
Definition at line 90 of file L1MuGMTSortRankUnit.cc.
References L1MuRegionalCand::empty(), eta, L1MuRegionalCand::eta_packed(), L1MuGMTConfig::getLFSortRankEtaPhiLUT(), phi, L1MuRegionalCand::phi_packed(), L1MuGMTLFSortRankEtaPhiLUT::SpecificLookup_rank_etaphi(), and L1MuRegionalCand::type_idx().
Referenced by L1MuGMTMatcher::lookup_mq(), and L1MuGMTMerger::merge().
{ if ( muon == 0 || muon->empty() ) return 1; unsigned lut_idx= muon->type_idx(); // obtain inputs as coded in HW unsigned eta = muon->eta_packed(); unsigned phi = muon->phi_packed(); // lookup eta-q L1MuGMTLFSortRankEtaPhiLUT* etaphi_lut = L1MuGMTConfig::getLFSortRankEtaPhiLUT(); return etaphi_lut->SpecificLookup_rank_etaphi (lut_idx, eta, phi) == 3; }
unsigned L1MuGMTSortRankUnit::sort_rank | ( | const L1MuRegionalCand * | muon | ) | [static] |
Sort Rank Table.
Definition at line 44 of file L1MuGMTSortRankUnit.cc.
References L1MuRegionalCand::empty(), eta, L1MuRegionalCand::eta_packed(), L1MuGMTConfig::getLFSortRankCombineLUT(), L1MuGMTConfig::getLFSortRankEtaPhiLUT(), L1MuGMTConfig::getLFSortRankEtaQLUT(), L1MuGMTConfig::getLFSortRankPtQLUT(), phi, L1MuRegionalCand::phi_packed(), L1MuRegionalCand::pt_packed(), lumiQueryAPI::q, L1MuRegionalCand::quality_packed(), L1MuGMTLFSortRankEtaPhiLUT::SpecificLookup_rank_etaphi(), L1MuGMTLFSortRankEtaQLUT::SpecificLookup_rank_etaq(), L1MuGMTLFSortRankPtQLUT::SpecificLookup_rank_ptq(), L1MuGMTLFSortRankCombineLUT::SpecificLookup_sort_rank(), and L1MuRegionalCand::type_idx().
Referenced by L1MuGMTMerger::createDTCSCCand(), L1MuGMTMerger::createMergedCand(), and L1MuGMTMerger::createRPCCand().
{ if ( muon == 0 || muon->empty() ) return 0; unsigned lut_idx= muon->type_idx(); // obtain inputs as coded in HW unsigned eta = muon->eta_packed(); unsigned q = muon->quality_packed(); unsigned pt = muon->pt_packed(); unsigned phi = muon->phi_packed(); // lookup eta-q L1MuGMTLFSortRankEtaQLUT* etaq_lut = L1MuGMTConfig::getLFSortRankEtaQLUT(); unsigned rank_etaq = etaq_lut->SpecificLookup_rank_etaq (lut_idx, eta, q); // lookup pt-q L1MuGMTLFSortRankPtQLUT* ptq_lut = L1MuGMTConfig::getLFSortRankPtQLUT(); unsigned rank_ptq = ptq_lut->SpecificLookup_rank_ptq (lut_idx, q, pt); // lookup etaphi L1MuGMTLFSortRankEtaPhiLUT* etaphi_lut = L1MuGMTConfig::getLFSortRankEtaPhiLUT(); unsigned rank_etaphi = etaphi_lut->SpecificLookup_rank_etaphi (lut_idx, eta, phi); // combine L1MuGMTLFSortRankCombineLUT* combine_lut = L1MuGMTConfig::getLFSortRankCombineLUT(); unsigned rank = combine_lut->SpecificLookup_sort_rank (lut_idx, rank_etaq, rank_ptq, rank_etaphi); return rank; }