Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-11-15 23:40:41

0001 //-------------------------------------------------
0002 //
0003 //   Class: L1MuBMTFConfig
0004 //
0005 //   Description: L1TMuonBarrelTrackProducer parameters for L1MuBMTrackFinder
0006 //
0007 //
0008 //
0009 //   Author :
0010 //   N. Neumeister            CERN EP
0011 //   J. Troconiz              UAM Madrid
0012 //
0013 //--------------------------------------------------
0014 
0015 //-----------------------
0016 // This Class's Header --
0017 //-----------------------
0018 
0019 #include "L1Trigger/L1TMuonBarrel/interface/L1MuBMTFConfig.h"
0020 
0021 #include "CondFormats/L1TObjects/interface/L1TMuonBarrelParams.h"
0022 
0023 //---------------
0024 // C++ Headers --
0025 //---------------
0026 
0027 #include <iostream>
0028 #include <string>
0029 
0030 //-------------------------------
0031 // Collaborating Class Headers --
0032 //-------------------------------
0033 
0034 using namespace std;
0035 
0036 // --------------------------------
0037 //       class L1MuBMTFConfig
0038 //---------------------------------
0039 
0040 //----------------
0041 // Constructors --
0042 //----------------
0043 
0044 L1MuBMTFConfig::L1MuBMTFConfig(const edm::ParameterSet& ps) { setDefaults(ps); }
0045 
0046 //--------------
0047 // Operations --
0048 //--------------
0049 
0050 void L1MuBMTFConfig::setDefaults(const edm::ParameterSet& ps) {
0051   m_BMDigiInputTag = ps.getParameter<edm::InputTag>("DTDigi_Source");
0052   m_BMThetaDigiInputTag = ps.getParameter<edm::InputTag>("DTDigi_Theta_Source");
0053 
0054   m_debug = true;
0055   m_dbgLevel = ps.getUntrackedParameter<int>("Debug", 0);
0056 
0057   if (Debug(1))
0058     cout << endl;
0059   if (Debug(1))
0060     cout << "*******************************************" << endl;
0061   if (Debug(1))
0062     cout << "**** L1 barrel Track Finder settings : ****" << endl;
0063   if (Debug(1))
0064     cout << "*******************************************" << endl;
0065   if (Debug(1))
0066     cout << endl;
0067 
0068   if (Debug(1))
0069     cout << "L1 barrel Track Finder : BM Digi Source:  " << m_BMDigiInputTag << endl;
0070   if (Debug(1))
0071     cout << "L1 barrel Track Finder : BM Digi Source:  " << m_BMThetaDigiInputTag << endl;
0072   if (Debug(1))
0073     cout << endl;
0074 
0075   if (Debug(1))
0076     cout << "L1 barrel Track Finder : debug level: " << m_dbgLevel << endl;
0077 }
0078 
0079 void L1MuBMTFConfig::setDefaultsES(const L1TMuonBarrelParams& bmtfParams) {
0080   // set min and max bunch crossing
0081   m_BxMin = bmtfParams.get_BX_min();
0082   m_BxMax = bmtfParams.get_BX_max();
0083 
0084   // set Filter for Extrapolator
0085   m_extTSFilter = bmtfParams.get_Extrapolation_Filter();
0086 
0087   // set switch for open LUTs usage
0088   m_openLUTs = bmtfParams.get_Open_LUTs();
0089 
0090   // set switch for EX21 usage
0091   m_useEX21 = bmtfParams.get_Extrapolation_21();
0092 
0093   // set switch for eta track finder usage
0094   m_etaTF = bmtfParams.get_EtaTrackFinder();
0095 
0096   // set Filter for Out-of-time Track Segments
0097   m_TSOutOfTimeFilter = bmtfParams.get_OutOfTime_Filter();
0098   m_TSOutOfTimeWindow = bmtfParams.get_OutOfTime_Filter_Window();
0099 
0100   // set precision for extrapolation
0101   m_NbitsExtPhi = bmtfParams.get_Extrapolation_nbits_Phi();
0102   m_NbitsExtPhib = bmtfParams.get_Extrapolation_nbits_PhiB();
0103 
0104   // set precision for pt-assignment
0105   m_NbitsPtaPhi = bmtfParams.get_PT_Assignment_nbits_Phi();
0106   m_NbitsPtaPhib = bmtfParams.get_PT_Assignment_nbits_PhiB();
0107 
0108   // set precision for phi-assignment look-up tables
0109   m_NbitsPhiPhi = bmtfParams.get_PHI_Assignment_nbits_Phi();
0110   m_NbitsExtPhib = bmtfParams.get_PHI_Assignment_nbits_PhiB();
0111 
0112   if (Debug(1))
0113     cout << "L1 barrel Track Finder : minimal bunch-crossing : " << m_BxMin << endl;
0114   if (Debug(1))
0115     cout << "L1 barrel Track Finder : maximal bunch-crossing : " << m_BxMax << endl;
0116 
0117   if (Debug(1))
0118     cout << "L1 barrel Track Finder : Extrapolation Filter : " << m_extTSFilter << endl;
0119 
0120   if (Debug(1) && m_openLUTs) {
0121     cout << "L1 barrel Track Finder : use open LUTs : on" << endl;
0122   }
0123   if (Debug(1) && !m_openLUTs) {
0124     cout << "L1 barrel Track Finder : use open LUTs : off" << endl;
0125   }
0126 
0127   if (Debug(1) && m_useEX21) {
0128     cout << "L1 barrel Track Finder : use EX21 extrapolations : on" << endl;
0129   }
0130   if (Debug(1) && !m_useEX21) {
0131     cout << "L1 barrel Track Finder : use EX21 extrapolations : off" << endl;
0132   }
0133 
0134   if (Debug(1) && m_etaTF) {
0135     cout << "L1 barrel Track Finder : Eta Track Finder : on" << endl;
0136   }
0137   if (Debug(1) && !m_etaTF) {
0138     cout << "L1 barrel Track Finder : Eta Track Finder : off" << endl;
0139   }
0140 
0141   if (Debug(1) && m_TSOutOfTimeFilter) {
0142     cout << "L1 barrel Track Finder : out-of-time TS filter : on" << endl;
0143     cout << "L1 barrel Track Finder : out-of-time TS filter window : " << m_TSOutOfTimeWindow << endl;
0144   }
0145   if (Debug(1) && !m_TSOutOfTimeFilter) {
0146     cout << "L1 barrel Track Finder : out-of-time TS filter : off" << endl;
0147   }
0148 
0149   if (Debug(1))
0150     cout << "L1 barrel Track Finder : # of bits used for phi  (extrapolation)  : " << m_NbitsExtPhi << endl;
0151   if (Debug(1))
0152     cout << "L1 barrel Track Finder : # of bits used for phib (extrapolation)  : " << m_NbitsExtPhib << endl;
0153   if (Debug(1))
0154     cout << "L1 barrel Track Finder : # of bits used for phi  (pt-assignment)  : " << m_NbitsPtaPhi << endl;
0155   if (Debug(1))
0156     cout << "L1 barrel Track Finder : # of bits used for phib (pt-assignment)  : " << m_NbitsPtaPhib << endl;
0157   if (Debug(1))
0158     cout << "L1 barrel Track Finder : # of bits used for phi  (phi-assignment) : " << m_NbitsPhiPhi << endl;
0159   if (Debug(1))
0160     cout << "L1 barrel Track Finder : # of bits used for phib (phi-assignment) : " << m_NbitsPhiPhib << endl;
0161 }