diff --git a/Trigger/TrigAlgorithms/TrigmuComb/TrigmuComb/ATLAS_CHECK_THREAD_SAFETY b/Trigger/TrigAlgorithms/TrigmuComb/ATLAS_CHECK_THREAD_SAFETY similarity index 100% rename from Trigger/TrigAlgorithms/TrigmuComb/TrigmuComb/ATLAS_CHECK_THREAD_SAFETY rename to Trigger/TrigAlgorithms/TrigmuComb/ATLAS_CHECK_THREAD_SAFETY diff --git a/Trigger/TrigAlgorithms/TrigmuComb/CMakeLists.txt b/Trigger/TrigAlgorithms/TrigmuComb/CMakeLists.txt index ac70437532a1ca143f2e31f288879a2e133076ba..fbd9987f92e48df15dd4f89fc055d83cd6a020ad 100644 --- a/Trigger/TrigAlgorithms/TrigmuComb/CMakeLists.txt +++ b/Trigger/TrigAlgorithms/TrigmuComb/CMakeLists.txt @@ -1,43 +1,13 @@ -################################################################################ -# Package: TrigmuComb -################################################################################ +# Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration # Declare the package name: atlas_subdir( TrigmuComb ) -# Declare the package's dependencies: -atlas_depends_on_subdirs( PUBLIC - Event/ByteStreamCnvSvcBase - Event/xAOD/xAODTracking - Event/xAOD/xAODTrigMuon - GaudiKernel - MagneticField/MagFieldInterfaces - Tracking/TrkExtrapolation/TrkExInterfaces - Trigger/TrigEvent/TrigInDetEvent - Trigger/TrigEvent/TrigMuonEvent - Trigger/TrigSteer/TrigInterfaces - Trigger/TrigTools/TrigTimeAlgs - PRIVATE - Control/AthenaKernel - Control/CxxUtils - Control/StoreGate - Tools/PathResolver - Trigger/TrigConfiguration/TrigConfHLTData - Trigger/TrigT1/TrigT1Interfaces - Trigger/TrigTools/TrigSiSpacePointTool ) - -# External dependencies: -find_package( CLHEP ) - # Component(s) in the package: atlas_add_component( TrigmuComb src/*.cxx src/components/*.cxx - INCLUDE_DIRS ${CLHEP_INCLUDE_DIRS} - LINK_LIBRARIES ${CLHEP_LIBRARIES} ByteStreamCnvSvcBaseLib xAODTracking xAODTrigMuon GaudiKernel MagFieldInterfaces TrkExInterfaces TrigInDetEvent TrigMuonEvent TrigInterfacesLib TrigTimeAlgsLib AthenaKernel StoreGateLib SGtests PathResolver TrigConfHLTData TrigT1Interfaces ) + LINK_LIBRARIES AthenaBaseComps AthenaKernel AthenaMonitoringKernelLib CxxUtils GaudiKernel MagFieldInterfaces PathResolver StoreGateLib TrigConfHLTData TrigInDetEvent TrigInterfacesLib TrigMuonEvent TrigT1Interfaces TrigTimeAlgsLib TrkExInterfaces xAODTracking xAODTrigMuon ) # Install files from the package: -atlas_install_headers( TrigmuComb ) -atlas_install_python_modules( python/*.py ) -atlas_install_joboptions( share/*.py ) - +atlas_install_python_modules( python/*.py POST_BUILD_CMD ${ATLAS_FLAKE8} ) diff --git a/Trigger/TrigAlgorithms/TrigmuComb/python/TrigmuCombConfig.py b/Trigger/TrigAlgorithms/TrigmuComb/python/TrigmuCombConfig.py index d4db9d3d766f2ece783ac905d06a439769a42093..add1ee152020a2672ef1321ec1daddafea059d09 100755 --- a/Trigger/TrigAlgorithms/TrigmuComb/python/TrigmuCombConfig.py +++ b/Trigger/TrigAlgorithms/TrigmuComb/python/TrigmuCombConfig.py @@ -1,13 +1,10 @@ # Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration -from TrigmuComb.TrigmuCombConf import * -from TrigmuComb.TrigmuCombMonitoring import * +from TrigmuComb.TrigmuCombConf import muComb +from TrigmuComb.TrigmuCombMonitoring import TrigmuCombValidationMonitoring, TrigmuCombOnlineMonitoring, TrigmuCombCosmicMonitoring from TriggerJobOpts.TriggerFlags import TriggerFlags from AthenaCommon.GlobalFlags import globalflags -from AthenaCommon.AppMgr import ServiceMgr from TrigTimeMonitor.TrigTimeHistToolConfig import TrigTimeHistToolConfig -from MuonByteStream.MuonByteStreamFlags import muonByteStreamFlags -from AthenaCommon.AppMgr import ToolSvc class TrigmuCombConfig (muComb): diff --git a/Trigger/TrigAlgorithms/TrigmuComb/python/TrigmuCombMTConfig.py b/Trigger/TrigAlgorithms/TrigmuComb/python/TrigmuCombMTConfig.py index 7cb0abda0a3b3a207599d64a55955be76df23471..b5b8c30002b60817029e77d9b42f078f5ef863b4 100755 --- a/Trigger/TrigAlgorithms/TrigmuComb/python/TrigmuCombMTConfig.py +++ b/Trigger/TrigAlgorithms/TrigmuComb/python/TrigmuCombMTConfig.py @@ -1,4 +1,4 @@ -# Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration +# Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration ############################## # L2 muCombMT Fex Algorithm Configuration: @@ -10,10 +10,6 @@ from TrigmuComb.TrigmuCombConf import muCombMT from AthenaCommon.SystemOfUnits import GeV from TriggerJobOpts.TriggerFlags import TriggerFlags from AthenaCommon.GlobalFlags import globalflags -from MuonByteStream.MuonByteStreamFlags import muonByteStreamFlags -from AthenaCommon.AppMgr import ServiceMgr -from AthenaCommon.AppMgr import ToolSvc -from AthenaMonitoringKernel.GenericMonitoringTool import GenericMonitoringTool,defineHistogram from TrigmuComb.TrigmuCombMonitoring import TrigMuCombMonitoring class TrigmuCombMTConfig (muCombMT): diff --git a/Trigger/TrigAlgorithms/TrigmuComb/share/HLTsequenceMuonOnly.xml b/Trigger/TrigAlgorithms/TrigmuComb/share/HLTsequenceMuonOnly.xml deleted file mode 100755 index ff606f1e720786d7b9f4db1e0a43dad130670f39..0000000000000000000000000000000000000000 --- a/Trigger/TrigAlgorithms/TrigmuComb/share/HLTsequenceMuonOnly.xml +++ /dev/null @@ -1,22 +0,0 @@ -<?xml version="1.0" encoding="UTF-8" standalone="no" ?> - -<!DOCTYPE SEQUENCE_LIST SYSTEM "sequencelist.dtd"> - -<SEQUENCE_LIST> - -<SEQUENCE level="L2" input="MUONROI" -algorithm=" -muFast/muFast/1 -" -output="MuonFeature" /> - -<SEQUENCE level="L2" input="MuonFeature" -algorithm=" -muComb/muComb/1 -" -output="LVL2out" /> - - - -</SEQUENCE_LIST> - diff --git a/Trigger/TrigAlgorithms/TrigmuComb/share/HLTsignatureMuonOnly.xml b/Trigger/TrigAlgorithms/TrigmuComb/share/HLTsignatureMuonOnly.xml deleted file mode 100755 index 71c705c5fcb6393d10bc082694216805b8b733c5..0000000000000000000000000000000000000000 --- a/Trigger/TrigAlgorithms/TrigmuComb/share/HLTsignatureMuonOnly.xml +++ /dev/null @@ -1,11 +0,0 @@ -<?xml version="1.0" encoding="UTF-8" standalone="no" ?> - -<!DOCTYPE SIGNATURE_LIST SYSTEM "signaturelist.dtd"> - -<SIGNATURE_LIST> - -<SIGNATURE signature_id="LVL2out" prescale="1" forced_accept="0"> - <TRIGGERELEMENT te_name="LVL2out" /> -</SIGNATURE> - -</SIGNATURE_LIST> diff --git a/Trigger/TrigAlgorithms/TrigmuComb/share/TriggerConfig_TrigmuComb.py b/Trigger/TrigAlgorithms/TrigmuComb/share/TriggerConfig_TrigmuComb.py deleted file mode 100755 index 758940b75bc4b7d9d0ccf16a72ddfcd2029d2af3..0000000000000000000000000000000000000000 --- a/Trigger/TrigAlgorithms/TrigmuComb/share/TriggerConfig_TrigmuComb.py +++ /dev/null @@ -1,52 +0,0 @@ -include.block("TrigmuComb/TriggerConfig_TrigmuComb.py") -# -# Configure a suitable TrigmuComb Algorithm instance -# -# Constructor arguments: -# level, type, threshold, isIsolated -# -# e.g. level=L2, type=muon, threshold=30, isIsolated=None -# level=EF, type=egamma, threshold=20, isIsolated=isolated -# -# Methods: -# instanceName() : returns name of algorithm instance -# classAndInstanceName() : returns a list of strings to be entered in the sequence file. This string -# defines the class and instance name - -class TriggerConfig_TrigmuComb: - - def __init__(self, level, type = None, threshold = None, isIsolated = None): - - # **temp the only instance name possible at present is muFast_1_L2 - - if type == "muon": - self.__instname__ = "muComb_Muon_" - self.__sequence__ = "muComb/muComb/Muon" - if type == "900GeV": - self.__instname__ = "muComb_900GeV_" - self.__sequence__ = "muComb/muComb/900GeV" - - self.__instname__ += level - - - def instanceName(self): - return self.__instname__ - - def classAndInstanceName(self): - return [ self.__sequence__ ] - - -theApp.Dlls += [ "TrigmuComb" ] - - -if TriggerFlags.MuonSlice.testFlag("doSITRACK"): - Algorithm("muComb_Muon_L2").IDalgo="SITRACK" - Algorithm("muComb_900GeV_L2").IDalgo="SITRACK" - - -#configure the loose algorithm -Algorithm("muComb_900GeV_L2").WinDeta = 0.065*2. -Algorithm("muComb_900GeV_L2").WinDphi = 0.081*2. -Algorithm("muComb_900GeV_L2").WinDzeta = 29.*2. - - diff --git a/Trigger/TrigAlgorithms/TrigmuComb/share/muCombJobOptions.py b/Trigger/TrigAlgorithms/TrigmuComb/share/muCombJobOptions.py deleted file mode 100755 index a70f21da8cc8e326c09f97a1b48acab2ab3a820e..0000000000000000000000000000000000000000 --- a/Trigger/TrigAlgorithms/TrigmuComb/share/muCombJobOptions.py +++ /dev/null @@ -1,27 +0,0 @@ -############################################################### -# -# Job options file for running muComb algorithm -# -#============================================================== -#load the libraries for the Timing Service -theApp.Dlls +=["TrigTimeAlgs" ] -theApp.ExtSvc += [ "TrigTimerSvc" ] -# include the MDT cabling service -#include( "MDTcablingJobOptions.py" ) - -# include the Roi Reconstruction Services -#include( "TrigT1RPCRecRoiSvcJobOptions.py" ) - -#include( "TrigT1TGCRecRoiSvcJobOptions.py" ) - -#theApp.Dlls += [ "TrigT1TGC" ] -#load the libraries for the muComb algorithm -theApp.Dlls += [ "TrigmuComb" ] -#theApp.ExtSvc += [ "MuRoadsSvc", "MuLUTSvc" ] - - -#-------------------------------------------------------------- -# Configuration of the Timer Service -#-------------------------------------------------------------- -TrigTimerSvc = Service( "TrigTimerSvc" ) -TrigTimerSvc.OutputLevel = 3 diff --git a/Trigger/TrigAlgorithms/TrigmuComb/src/components/TrigmuComb_entries.cxx b/Trigger/TrigAlgorithms/TrigmuComb/src/components/TrigmuComb_entries.cxx index 20d2a61905eb95594007c22ff3272846c5863110..82e4a02d78447c58cdd53ee286c7bbc442a5d507 100644 --- a/Trigger/TrigAlgorithms/TrigmuComb/src/components/TrigmuComb_entries.cxx +++ b/Trigger/TrigAlgorithms/TrigmuComb/src/components/TrigmuComb_entries.cxx @@ -1,5 +1,5 @@ -#include "TrigmuComb/muComb.h" -#include "TrigmuComb/muCombMT.h" +#include "../muComb.h" +#include "../muCombMT.h" DECLARE_COMPONENT( muComb ) DECLARE_COMPONENT( muCombMT ) diff --git a/Trigger/TrigAlgorithms/TrigmuComb/src/muComb.cxx b/Trigger/TrigAlgorithms/TrigmuComb/src/muComb.cxx index c74f43027c95402d2d6e07016fe0b7b3aa5e5f67..d3554b5c6db16e734b49476952976f0df3c99844 100755 --- a/Trigger/TrigAlgorithms/TrigmuComb/src/muComb.cxx +++ b/Trigger/TrigAlgorithms/TrigmuComb/src/muComb.cxx @@ -1,5 +1,5 @@ /* - Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration + Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration */ // ******************************************************************** @@ -14,8 +14,8 @@ #include <sstream> #include <math.h> -#include "TrigmuComb/muComb.h" -#include "TrigmuComb/muCombUtil.h" +#include "muComb.h" +#include "muCombUtil.h" #include "PathResolver/PathResolver.h" #include "TrigT1Interfaces/RecMuonRoI.h" #include "TrigConfHLTData/HLTTriggerElement.h" @@ -26,7 +26,6 @@ #include "xAODTrigMuon/L2CombinedMuonAuxContainer.h" //#include "xAODTracking/TrackParticle.h" #include "xAODTracking/TrackParticleContainer.h" -#include "TrigSiSpacePointTool/ISpacePointProvider.h" #include "StoreGate/StoreGateSvc.h" #include "StoreGate/DataHandle.h" #include "AthenaKernel/Timeout.h" @@ -35,7 +34,7 @@ #include "TrigMuonEvent/CombinedMuonFeature.h" #include "TrigInDetEvent/TrigInDetTrackCollection.h" -#include "CLHEP/Units/SystemOfUnits.h" +#include "GaudiKernel/SystemOfUnits.h" ATLAS_NO_CHECK_FILE_THREAD_SAFETY; // legacy trigger code @@ -211,7 +210,7 @@ HLT::ErrorCode muComb::hltFinalize() int muComb::drptMatch(const xAOD::L2StandAloneMuon* feature, double id_pt, double id_eta, double id_phi, int algo, double& combPtInv, double& combPtRes, double& deta, double& dphi, double& dr) { - double pt = feature->pt() * CLHEP::GeV; + double pt = feature->pt() * Gaudi::Units::GeV; double phi = feature->phiMS(); double eta = feature->etaMS(); return muComb::drptMatch(pt, eta, phi, id_pt, id_eta, id_phi, algo, combPtInv, combPtRes, deta, dphi, dr); @@ -236,7 +235,7 @@ int muComb::drptMatch(double pt, double eta, double phi, double id_pt, double id //muFast parameters (in MeV!) //double phi = feature->phiMS(); //double eta = feature->etaMS(); - //double pt = feature->pt() * CLHEP::GeV; + //double pt = feature->pt() * Gaudi::Units::GeV; combPtRes = 0.0; if (algo == 1) combPtInv = ((1. / pt) + (1. / id_pt)) * 0.5; @@ -265,7 +264,7 @@ int muComb::drptMatch(double pt, double eta, double phi, double id_pt, double id << " / " << (passDR ? "true" : "false")); if (algo == 1 && winPt > 0) { - double tmp_dpt = fabs(fabs(pt) - fabs(id_pt)) / CLHEP::GeV; //don't use charge info + double tmp_dpt = fabs(fabs(pt) - fabs(id_pt)) / Gaudi::Units::GeV; //don't use charge info if (tmp_dpt > winPt) passPt = false; ATH_MSG_DEBUG(m_test_string << " REGTEST MU-ID match / dpt (GeV) / threshold (GeV) / result:" @@ -294,7 +293,7 @@ int muComb::g4Match(const xAOD::L2StandAloneMuon* feature, double theta = 2.*atan(exp(-feature->etaMS())); double p = 0.0; if (sin(theta) != 0) { - p = (feature->pt() * CLHEP::GeV) / sin(theta); + p = (feature->pt() * Gaudi::Units::GeV) / sin(theta); } else { return 1; //No match if muon angle is zero } @@ -306,9 +305,9 @@ int muComb::g4Match(const xAOD::L2StandAloneMuon* feature, } else { return 1; //No match if muon Pt is zero } - double pt = feature->pt() * CLHEP::GeV; + double pt = feature->pt() * Gaudi::Units::GeV; //double ptinv = 1/pt; - double eptinv = feature->deltaPt() * CLHEP::GeV / pt / pt; + double eptinv = feature->deltaPt() * Gaudi::Units::GeV / pt / pt; bool isBarrel = ((feature->sAddress() != -1) ? true : false); double etaShift = (isBarrel ? 0 : charge * 0.01); @@ -454,16 +453,16 @@ int muComb::g4Match(const xAOD::L2StandAloneMuon* feature, ATH_MSG_DEBUG(m_test_string << " REGTEST Resolution / OLDIdRes / IdRes / muFastRes / combRes:" - << " / " << std::setw(11) << id_eptinv_OLD / CLHEP::GeV - << " / " << std::setw(11) << id_eptinv / CLHEP::GeV - << " / " << std::setw(11) << extr_eptinv / CLHEP::GeV - << " / " << std::setw(11) << combPtRes / CLHEP::GeV); + << " / " << std::setw(11) << id_eptinv_OLD / Gaudi::Units::GeV + << " / " << std::setw(11) << id_eptinv / Gaudi::Units::GeV + << " / " << std::setw(11) << extr_eptinv / Gaudi::Units::GeV + << " / " << std::setw(11) << combPtRes / Gaudi::Units::GeV); ATH_MSG_DEBUG(m_test_string << " REGTEST Momentum / IdPt / muFastPt / CombPt :" - << " / " << std::setw(11) << 1. / id_ptinv / CLHEP::GeV - << " / " << std::setw(11) << 1. / extr_ptinv / CLHEP::GeV - << " / " << std::setw(11) << 1. / combPtInv / CLHEP::GeV); + << " / " << std::setw(11) << 1. / id_ptinv / Gaudi::Units::GeV + << " / " << std::setw(11) << 1. / extr_ptinv / Gaudi::Units::GeV + << " / " << std::setw(11) << 1. / combPtInv / Gaudi::Units::GeV); ATH_MSG_DEBUG(m_test_string << " REGTEST Chi2 / ndof // Chi2OLD / ndofOLD :" @@ -513,7 +512,7 @@ int muComb::mfMatch(const xAOD::L2StandAloneMuon* feature, ndof = 0; //muFast parameters - double pt = feature->pt() * CLHEP::GeV; + double pt = feature->pt() * Gaudi::Units::GeV; if (pt == 0.) { return 1; //No match if muFast Pt is zero } @@ -523,7 +522,7 @@ int muComb::mfMatch(const xAOD::L2StandAloneMuon* feature, double charge = pt / fabs(pt); double ptinv = 1. / pt; - double eptinv = feature->deltaPt() * CLHEP::GeV / pt / pt; + double eptinv = feature->deltaPt() * Gaudi::Units::GeV / pt / pt; //ID parameters double id_eptinv = muCombUtil::getIDSCANRes(m_IDSCANRes_barrel, m_IDSCANRes_endcap1, m_IDSCANRes_endcap2, @@ -570,15 +569,15 @@ int muComb::mfMatch(const xAOD::L2StandAloneMuon* feature, ATH_MSG_DEBUG(m_test_string << " REGTEST Resolution / IdRes / muFastRes / combRes:" - << " / " << std::setw(11) << id_eptinv / CLHEP::GeV - << " / " << std::setw(11) << extr_eptinv / CLHEP::GeV - << " / " << std::setw(11) << combPtRes / CLHEP::GeV); + << " / " << std::setw(11) << id_eptinv / Gaudi::Units::GeV + << " / " << std::setw(11) << extr_eptinv / Gaudi::Units::GeV + << " / " << std::setw(11) << combPtRes / Gaudi::Units::GeV); ATH_MSG_DEBUG(m_test_string << " REGTEST Momentum / IdPt / muFastPt / CombPt :" - << " / " << std::setw(11) << 1. / id_ptinv / CLHEP::GeV - << " / " << std::setw(11) << 1. / ptinv / CLHEP::GeV - << " / " << std::setw(11) << 1. / combPtInv / CLHEP::GeV); + << " / " << std::setw(11) << 1. / id_ptinv / Gaudi::Units::GeV + << " / " << std::setw(11) << 1. / ptinv / Gaudi::Units::GeV + << " / " << std::setw(11) << 1. / combPtInv / Gaudi::Units::GeV); ATH_MSG_DEBUG(m_test_string << " REGTEST Chi2 / ndof :" @@ -868,7 +867,7 @@ HLT::ErrorCode muComb::hltExecute(const HLT::TriggerElement* inputTE, if (sin(theta_id) != 0) e_qoverpt_id /= fabs(sin(theta_id)); //approximate ATH_MSG_DEBUG("Found track: " - << " with pt (GeV) = " << pt_id / CLHEP::GeV + << " with pt (GeV) = " << pt_id / Gaudi::Units::GeV << ", q = " << q_id << ", eta = " << eta_id << ", phi = " << phi_id @@ -881,7 +880,7 @@ HLT::ErrorCode muComb::hltExecute(const HLT::TriggerElement* inputTE, << ", eipt = " << e_qoverpt_id); if (usealgo != 3) { - if ((fabs(pt_id) / CLHEP::GeV) < m_PtMinTrk) continue; + if ((fabs(pt_id) / Gaudi::Units::GeV) < m_PtMinTrk) continue; } if (fabs(eta_id) > m_EtaMaxTrk) continue; @@ -979,11 +978,11 @@ HLT::ErrorCode muComb::hltExecute(const HLT::TriggerElement* inputTE, m_phiFL = -9999.; if (usealgo == 0 && fabs(pt) >= 6.) { m_efficiency = 1; - m_ptID = pt_id / CLHEP::GeV; //in GeV/c + m_ptID = pt_id / Gaudi::Units::GeV; //in GeV/c m_etaID = eta_id; m_phiID = phi_id; m_zetaID = zPos_id; - m_ptMC = 1. / (ptinv_comb * CLHEP::GeV); //in GeV/c + m_ptMC = 1. / (ptinv_comb * Gaudi::Units::GeV); //in GeV/c m_dZeta = zeta_ms - zPos_id; m_dPhi = best_dphi; m_dEta = best_deta; @@ -999,7 +998,7 @@ HLT::ErrorCode muComb::hltExecute(const HLT::TriggerElement* inputTE, if (useL1) prt_pt = ptL1; ATH_MSG_DEBUG(m_test_string << " REGTEST Combination chosen: " << " usealgo / IdPt (GeV) / muonPt (GeV) / CombPt (GeV) / chi2 / ndof: " - << " / " << usealgo << " / " << pt_id*q_id / CLHEP::GeV << " / " << prt_pt << " / " << 1. / ptinv_comb / CLHEP::GeV << " / " << chi2_comb << " / " << ndof_comb); + << " / " << usealgo << " / " << pt_id*q_id / Gaudi::Units::GeV << " / " << prt_pt << " / " << 1. / ptinv_comb / Gaudi::Units::GeV << " / " << chi2_comb << " / " << ndof_comb); muonCB->setPt(fabs(1. / ptinv_comb)); muonCB->setEta(eta_id); @@ -1011,7 +1010,7 @@ HLT::ErrorCode muComb::hltExecute(const HLT::TriggerElement* inputTE, muonCB->setCharge(mcq); float mcresu = fabs(ptres_comb / (ptinv_comb * ptinv_comb)); - ATH_MSG_DEBUG(" SigmaPt (GeV) is: " << mcresu / CLHEP::GeV); + ATH_MSG_DEBUG(" SigmaPt (GeV) is: " << mcresu / Gaudi::Units::GeV); muonCB->setSigmaPt(mcresu); muonCB->setErrorFlag(m_ErrorFlagMC); diff --git a/Trigger/TrigAlgorithms/TrigmuComb/TrigmuComb/muComb.h b/Trigger/TrigAlgorithms/TrigmuComb/src/muComb.h old mode 100755 new mode 100644 similarity index 100% rename from Trigger/TrigAlgorithms/TrigmuComb/TrigmuComb/muComb.h rename to Trigger/TrigAlgorithms/TrigmuComb/src/muComb.h diff --git a/Trigger/TrigAlgorithms/TrigmuComb/src/muCombMT.cxx b/Trigger/TrigAlgorithms/TrigmuComb/src/muCombMT.cxx index f19fb8208749973cb90b830dfca154872b767ac7..07424d65b7c6072ea342a2214fb7691e5deac06c 100644 --- a/Trigger/TrigAlgorithms/TrigmuComb/src/muCombMT.cxx +++ b/Trigger/TrigAlgorithms/TrigmuComb/src/muCombMT.cxx @@ -1,5 +1,5 @@ /* - Copyright (C) 2002-2018 CERN for the benefit of the ATLAS collaboration + Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration */ // ******************************************************************** @@ -14,8 +14,8 @@ #include <sstream> #include <math.h> -#include "TrigmuComb/muCombMT.h" -#include "TrigmuComb/muCombUtil.h" +#include "muCombMT.h" +#include "muCombUtil.h" #include "PathResolver/PathResolver.h" #include "TrigConfHLTData/HLTTriggerElement.h" #include "xAODTrigMuon/TrigMuonDefs.h" @@ -23,10 +23,8 @@ #include "xAODTrigMuon/L2StandAloneMuonAuxContainer.h" #include "xAODTrigMuon/L2CombinedMuonAuxContainer.h" #include "xAODTracking/TrackParticleContainer.h" -#include "TrigSiSpacePointTool/ISpacePointProvider.h" #include "AthenaMonitoringKernel/Monitored.h" -#include "CLHEP/Units/SystemOfUnits.h" class ISvcLocator; muCombMT::muCombMT(const std::string& name, ISvcLocator* pSvcLocator): @@ -79,7 +77,7 @@ StatusCode muCombMT::finalize() int muCombMT::drptMatch(const xAOD::L2StandAloneMuon* feature, double id_pt, double id_eta, double id_phi, int algo, double& combPtInv, double& combPtRes, double& deta, double& dphi, double& dr) { - double pt = feature->pt() * CLHEP::GeV; + double pt = feature->pt() * Gaudi::Units::GeV; double phi = feature->phiMS(); double eta = feature->etaMS(); return muCombMT::drptMatch(pt, eta, phi, id_pt, id_eta, id_phi, algo, combPtInv, combPtRes, deta, dphi, dr); @@ -127,7 +125,7 @@ int muCombMT::drptMatch(double pt, double eta, double phi, double id_pt, double << " / " << (passDR ? "true" : "false")); if (algo == 1 && winPt > 0) { - double tmp_dpt = fabs(fabs(pt) - fabs(id_pt)) / CLHEP::GeV; //don't use charge info + double tmp_dpt = fabs(fabs(pt) - fabs(id_pt)) / Gaudi::Units::GeV; //don't use charge info if (tmp_dpt > winPt) passPt = false; ATH_MSG_DEBUG( " REGTEST MU-ID match / dpt (GeV) / threshold (GeV) / result:" << " / " << tmp_dpt @@ -155,7 +153,7 @@ int muCombMT::g4Match(const xAOD::L2StandAloneMuon* feature, double theta = 2.*atan(exp(-feature->etaMS())); double p = 0.0; if (sin(theta) != 0) { - p = (feature->pt() * CLHEP::GeV) / sin(theta); + p = (feature->pt() * Gaudi::Units::GeV) / sin(theta); } else { return 2; //No match if muon angle is zero } @@ -167,9 +165,9 @@ int muCombMT::g4Match(const xAOD::L2StandAloneMuon* feature, } else { return 1; //No match if muon Pt is zero } - double pt = feature->pt() * CLHEP::GeV; + double pt = feature->pt() * Gaudi::Units::GeV; //double ptinv = 1/pt; - double eptinv = feature->deltaPt() * CLHEP::GeV / pt / pt; + double eptinv = feature->deltaPt() * Gaudi::Units::GeV / pt / pt; bool isBarrel = ((feature->sAddress() != -1) ? true : false); double etaShift = (isBarrel ? 0 : charge * 0.01); @@ -293,15 +291,15 @@ int muCombMT::g4Match(const xAOD::L2StandAloneMuon* feature, ATH_MSG_DEBUG(" REGTEST Resolution / OLDIdRes / IdRes / muFastRes / combRes:" - << " / " << std::setw(11) << id_eptinv_OLD / CLHEP::GeV - << " / " << std::setw(11) << id_eptinv / CLHEP::GeV - << " / " << std::setw(11) << extr_eptinv / CLHEP::GeV - << " / " << std::setw(11) << combPtRes / CLHEP::GeV ); + << " / " << std::setw(11) << id_eptinv_OLD / Gaudi::Units::GeV + << " / " << std::setw(11) << id_eptinv / Gaudi::Units::GeV + << " / " << std::setw(11) << extr_eptinv / Gaudi::Units::GeV + << " / " << std::setw(11) << combPtRes / Gaudi::Units::GeV ); ATH_MSG_DEBUG(" REGTEST Momentum / IdPt / muFastPt / CombPt :" - << " / " << std::setw(11) << 1. / id_ptinv / CLHEP::GeV - << " / " << std::setw(11) << 1. / extr_ptinv / CLHEP::GeV - << " / " << std::setw(11) << 1. / combPtInv / CLHEP::GeV ); + << " / " << std::setw(11) << 1. / id_ptinv / Gaudi::Units::GeV + << " / " << std::setw(11) << 1. / extr_ptinv / Gaudi::Units::GeV + << " / " << std::setw(11) << 1. / combPtInv / Gaudi::Units::GeV ); ATH_MSG_DEBUG(" REGTEST Chi2 / ndof // Chi2OLD / ndofOLD :" << " / " << std::setw(11) << chi2 @@ -349,7 +347,7 @@ int muCombMT::mfMatch(const xAOD::L2StandAloneMuon* feature, ndof = 0; //muFast parameters - double pt = feature->pt() * CLHEP::GeV; + double pt = feature->pt() * Gaudi::Units::GeV; if (pt == 0.) { return 1; //No match if muFast Pt is zero } @@ -359,7 +357,7 @@ int muCombMT::mfMatch(const xAOD::L2StandAloneMuon* feature, double charge = pt / fabs(pt); double ptinv = 1. / pt; - double eptinv = feature->deltaPt() * CLHEP::GeV / pt / pt; + double eptinv = feature->deltaPt() * Gaudi::Units::GeV / pt / pt; //ID parameters double id_eptinv = muCombUtil::getIDSCANRes(m_IDSCANRes_barrel, m_IDSCANRes_endcap1, m_IDSCANRes_endcap2, @@ -405,14 +403,14 @@ int muCombMT::mfMatch(const xAOD::L2StandAloneMuon* feature, ATH_MSG_DEBUG(" REGTEST Resolution / IdRes / muFastRes / combRes:" - << " / " << std::setw(11) << id_eptinv / CLHEP::GeV - << " / " << std::setw(11) << extr_eptinv / CLHEP::GeV - << " / " << std::setw(11) << combPtRes / CLHEP::GeV ); + << " / " << std::setw(11) << id_eptinv / Gaudi::Units::GeV + << " / " << std::setw(11) << extr_eptinv / Gaudi::Units::GeV + << " / " << std::setw(11) << combPtRes / Gaudi::Units::GeV ); ATH_MSG_DEBUG(" REGTEST Momentum / IdPt / muFastPt / CombPt :" - << " / " << std::setw(11) << 1. / id_ptinv / CLHEP::GeV - << " / " << std::setw(11) << 1. / ptinv / CLHEP::GeV - << " / " << std::setw(11) << 1. / combPtInv / CLHEP::GeV ); + << " / " << std::setw(11) << 1. / id_ptinv / Gaudi::Units::GeV + << " / " << std::setw(11) << 1. / ptinv / Gaudi::Units::GeV + << " / " << std::setw(11) << 1. / combPtInv / Gaudi::Units::GeV ); ATH_MSG_DEBUG(" REGTEST Chi2 / ndof :" << " / " << std::setw(11) << chi2 @@ -712,7 +710,7 @@ StatusCode muCombMT::execute() if (sin(theta_id) != 0) e_qoverpt_id /= fabs(sin(theta_id)); //approximate ATH_MSG_DEBUG( " Found track: " - << " with pt (GeV) = " << pt_id / CLHEP::GeV + << " with pt (GeV) = " << pt_id / Gaudi::Units::GeV << ", q = " << q_id << ", eta = " << eta_id << ", phi = " << phi_id @@ -725,7 +723,7 @@ StatusCode muCombMT::execute() << ", eipt = " << e_qoverpt_id ); if (usealgo != 3) { - if ((fabs(pt_id) / CLHEP::GeV) < m_PtMinTrk) continue; + if ((fabs(pt_id) / Gaudi::Units::GeV) < m_PtMinTrk) continue; } if (fabs(eta_id) > m_EtaMaxTrk) continue; @@ -816,11 +814,11 @@ StatusCode muCombMT::execute() phiFL = -9999.; if (usealgo == 0 && fabs(pt) >= 6.) { efficiency = 1; - ptID = pt_id / CLHEP::GeV; //in GeV/c + ptID = pt_id / Gaudi::Units::GeV; //in GeV/c etaID = eta_id; phiID = phi_id; zetaID = zPos_id; - ptMC = 1. / (ptinv_comb * CLHEP::GeV); //in GeV/c + ptMC = 1. / (ptinv_comb * Gaudi::Units::GeV); //in GeV/c dZeta = zeta_ms - zPos_id; dPhi = best_dphi; dEta = best_deta; @@ -837,7 +835,7 @@ StatusCode muCombMT::execute() //if (useL1) prt_pt = ptL1; ATH_MSG_DEBUG( " REGTEST Combination chosen: " << " usealgo / IdPt (GeV) / muonPt (GeV) / CombPt (GeV) / chi2 / ndof: " - << " / " << usealgo << " / " << pt_id*q_id / CLHEP::GeV << " / " << prt_pt << " / " << 1. / ptinv_comb / CLHEP::GeV << " / " << chi2_comb << " / " << ndof_comb ); + << " / " << usealgo << " / " << pt_id*q_id / Gaudi::Units::GeV << " / " << prt_pt << " / " << 1. / ptinv_comb / Gaudi::Units::GeV << " / " << chi2_comb << " / " << ndof_comb ); muonCB->setPt(fabs(1. / ptinv_comb)); muonCB->setEta(eta_id); @@ -849,7 +847,7 @@ StatusCode muCombMT::execute() muonCB->setCharge(mcq); float mcresu = fabs(ptres_comb / (ptinv_comb * ptinv_comb)); - ATH_MSG_DEBUG( " SigmaPt (GeV) is: " << mcresu / CLHEP::GeV ); + ATH_MSG_DEBUG( " SigmaPt (GeV) is: " << mcresu / Gaudi::Units::GeV ); muonCB->setSigmaPt(mcresu); muonCB->setErrorFlag(ErrorFlagMC); diff --git a/Trigger/TrigAlgorithms/TrigmuComb/TrigmuComb/muCombMT.h b/Trigger/TrigAlgorithms/TrigmuComb/src/muCombMT.h similarity index 97% rename from Trigger/TrigAlgorithms/TrigmuComb/TrigmuComb/muCombMT.h rename to Trigger/TrigAlgorithms/TrigmuComb/src/muCombMT.h index 59d8d67df8d0b99c806d401585fda8e0d21d20fb..05707f2b82b0bcccf0028b21115492e5a4f4d1ed 100644 --- a/Trigger/TrigAlgorithms/TrigmuComb/TrigmuComb/muCombMT.h +++ b/Trigger/TrigAlgorithms/TrigmuComb/src/muCombMT.h @@ -1,5 +1,5 @@ /* - Copyright (C) 2002-2018 CERN for the benefit of the ATLAS collaboration + Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration */ // ******************************************************************** @@ -25,6 +25,7 @@ //Gaudi #include "GaudiKernel/ToolHandle.h" #include "GaudiKernel/ServiceHandle.h" +#include "GaudiKernel/SystemOfUnits.h" // Base class #include "AthenaBaseComps/AthAlgorithm.h" @@ -42,7 +43,6 @@ //#include "TrigT1Interfaces/RecMuonRoI.h" #include "AthenaMonitoringKernel/GenericMonitoringTool.h" -#include "CLHEP/Units/SystemOfUnits.h" /** Main LVL2 Algorithm. Sided by a xAOD::L2StandaloneMuon, match the muon spectrometer track with an ID track, and produces a xAOD::L2CombinedMuon. */ class muCombMT : public AthAlgorithm @@ -138,7 +138,7 @@ class muCombMT : public AthAlgorithm Gaudi::Property<std::string> m_ID_algo_to_use {this, "IDalgo", "InDetTrigTrackingxAODCnv_Muon_FTF","ID trk xAOD collection to use"}; /** Min Pt to select the ID track for matching */ - Gaudi::Property<double> m_PtMinTrk {this, "MinPtTRK", 1.*CLHEP::GeV, "ID track minimum pT"}; //GeV/c + Gaudi::Property<double> m_PtMinTrk {this, "MinPtTRK", 1.*Gaudi::Units::GeV, "ID track minimum pT"}; //GeV/c /** Max abs(eta) to select the ID track for matching */ Gaudi::Property<double> m_EtaMaxTrk {this, "MaxAbsEtaTRK", 2.5, "ID tracks max |eta|"}; @@ -201,7 +201,7 @@ class muCombMT : public AthAlgorithm // Simplified DeltaR(/Pt) based match /** max deltaPt for simpified matching */ - Gaudi::Property<double> m_winPt {this, "WinPt", -1.0*CLHEP::GeV, "matching parameter (simplifed): pT windows in geV (disabled if < 0)"}; + Gaudi::Property<double> m_winPt {this, "WinPt", -1.0*Gaudi::Units::GeV, "matching parameter (simplifed): pT windows in geV (disabled if < 0)"}; /** max deltaR for simplified matching */ Gaudi::Property<double> m_winDR {this, "WinDelta", 0.2, "matching parameter (simplifed): strategy dependent"}; diff --git a/Trigger/TrigAlgorithms/TrigmuComb/src/muCombUtil.cxx b/Trigger/TrigAlgorithms/TrigmuComb/src/muCombUtil.cxx index 8a71c0c4f86b096cece18862848fc903adfa4b41..4ceab564c217624828ce60a0493401ef28a984dc 100644 --- a/Trigger/TrigAlgorithms/TrigmuComb/src/muCombUtil.cxx +++ b/Trigger/TrigAlgorithms/TrigmuComb/src/muCombUtil.cxx @@ -14,7 +14,7 @@ #include <iostream> #include <math.h> -#include "TrigmuComb/muCombUtil.h" +#include "muCombUtil.h" #include "TrigMuonEvent/MuonFeature.h" #include "TrigInDetEvent/TrigInDetTrack.h" diff --git a/Trigger/TrigAlgorithms/TrigmuComb/TrigmuComb/muCombUtil.h b/Trigger/TrigAlgorithms/TrigmuComb/src/muCombUtil.h similarity index 100% rename from Trigger/TrigAlgorithms/TrigmuComb/TrigmuComb/muCombUtil.h rename to Trigger/TrigAlgorithms/TrigmuComb/src/muCombUtil.h diff --git a/Trigger/TrigTools/TrigSiSpacePointTool/CMakeLists.txt b/Trigger/TrigTools/TrigSiSpacePointTool/CMakeLists.txt deleted file mode 100644 index 97eeb39682b78210e10a9219726e18d779814fdd..0000000000000000000000000000000000000000 --- a/Trigger/TrigTools/TrigSiSpacePointTool/CMakeLists.txt +++ /dev/null @@ -1,15 +0,0 @@ -################################################################################ -# Package: TrigSiSpacePointTool -################################################################################ - -# Declare the package name: -atlas_subdir( TrigSiSpacePointTool ) - -# Declare the package's dependencies: -atlas_depends_on_subdirs( PUBLIC - GaudiKernel - Trigger/TrigEvent/TrigInDetEvent ) - -# Install files from the package: -atlas_install_headers( TrigSiSpacePointTool ) - diff --git a/Trigger/TrigTools/TrigSiSpacePointTool/TrigSiSpacePointTool/ATLAS_CHECK_THREAD_SAFETY b/Trigger/TrigTools/TrigSiSpacePointTool/TrigSiSpacePointTool/ATLAS_CHECK_THREAD_SAFETY deleted file mode 100644 index 2578942da461745f7b84a79dccf222590feacae4..0000000000000000000000000000000000000000 --- a/Trigger/TrigTools/TrigSiSpacePointTool/TrigSiSpacePointTool/ATLAS_CHECK_THREAD_SAFETY +++ /dev/null @@ -1 +0,0 @@ -Trigger/TrigTools/TrigSiSpacePointTool diff --git a/Trigger/TrigTools/TrigSiSpacePointTool/TrigSiSpacePointTool/ISpacePointProvider.h b/Trigger/TrigTools/TrigSiSpacePointTool/TrigSiSpacePointTool/ISpacePointProvider.h deleted file mode 100755 index 112cc92d86c313203570ffbb1512964f1e89ad3b..0000000000000000000000000000000000000000 --- a/Trigger/TrigTools/TrigSiSpacePointTool/TrigSiSpacePointTool/ISpacePointProvider.h +++ /dev/null @@ -1,46 +0,0 @@ -/* - Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration -*/ - -#ifndef ISPACPOINTPROVIDER_H -#define ISPACPOINTPROVIDER_H - -#include <vector> -#include "GaudiKernel/IAlgTool.h" - -class TrigSiSpacePoint; -class IRoiDescriptor; - -typedef std::vector< const TrigSiSpacePoint* > spacePointVec; - -static const InterfaceID IID_ISpacePointProvider("ISpacePointProvider", 1 , 0); - - -class ISpacePointProvider: virtual public IAlgTool -{ - public: - - /// Retrieve interface ID - static const InterfaceID& interfaceID() { - return IID_ISpacePointProvider; - } - - virtual spacePointVec getSpacePoints(bool getPixeSP=true, bool getSctSP=true) = 0; - - virtual StatusCode fillCollections(const IRoiDescriptor&, bool,bool, - std::vector<int>&, std::vector<int>&) = 0; - virtual StatusCode fillCollections(bool,bool, - std::vector<int>&, std::vector<int>&) = 0; - - virtual const std::vector<int>* fillPixelDataErrors() = 0; - virtual const std::vector<int>* fillSCT_DataErrors() = 0; - - virtual double getBStoClustersTimingPixel() const= 0; - virtual double getBStoClustersTimingSCT() const = 0; - virtual double getSPformationTimingPixel() const = 0; - virtual double getSPformationTimingSCT() const = 0; - virtual double getRegSelTiming() const = 0; - virtual double getTotalTiming() const = 0; -}; - -#endif // ISPACPOINTPROVIDER_H diff --git a/Trigger/TrigTools/TrigSiSpacePointTool/doc/packagedoc.h b/Trigger/TrigTools/TrigSiSpacePointTool/doc/packagedoc.h deleted file mode 100644 index 6636b86885a53170411dc196f6767539e3f17149..0000000000000000000000000000000000000000 --- a/Trigger/TrigTools/TrigSiSpacePointTool/doc/packagedoc.h +++ /dev/null @@ -1,48 +0,0 @@ -/* - Copyright (C) 2002-2018 CERN for the benefit of the ATLAS collaboration -*/ -/* - Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration -*/ - -/** -@page TrigSiSpacePointTool_page TrigSiSpacePointTool Package - -This package contains an interface class ISpacePointProvider - -@author D.Emeliyanov AT rlDOTacDOTuk - -@section TrigSiSpacePointTool_TrigSiSpacePointToolIntro Introduction - -This package defines an abstract interface for the LVL2 Silicon -data providers (TrigOnlineSpacePointTool, TrigOfflineSpacePointTool and -LazySpacePointProviderTool) - -The interface defines the following methods - -|code - - virtual spacePointVec getSpacePoints( double roiEtaMin, double roiEtaMax, - double roiPhiMin, double roiPhiMax, - bool getPixeSP=true, bool getSctSP=true) = 0; - - virtual spacePointVec getSpacePoints(bool getPixeSP=true, bool getSctSP=true) = 0; - - - virtual StatusCode fillCollections(double, double, double,double,double,double,bool,bool, - std::vector<int>&, std::vector<int>&) = 0; - virtual StatusCode fillCollections(double,double,double,double,bool,bool, - std::vector<int>&, std::vector<int>&) = 0; - virtual StatusCode fillCollections(bool,bool, - std::vector<int>&, std::vector<int>&) = 0; - - virtual const std::vector<int>* fillPixelDataErrors() = 0; - virtual const std::vector<int>* fillSCT_DataErrors() = 0; - -|endcode - -Note that getSpacePoints methods are obsolete and must not be used. - - - -*/