diff --git a/Event/xAOD/xAODForwardCnv/CMakeLists.txt b/Event/xAOD/xAODForwardCnv/CMakeLists.txt index a62cf0e569611a0e6511dce18ddf9442cca49266..73cfd283459e7659e197b05a52abcfc8fd684d39 100644 --- a/Event/xAOD/xAODForwardCnv/CMakeLists.txt +++ b/Event/xAOD/xAODForwardCnv/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration +# Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration # Declare the package name: atlas_subdir( xAODForwardCnv ) @@ -17,5 +17,3 @@ atlas_add_component( xAODForwardCnv # Install files from the package: atlas_install_python_modules( python/*.py POST_BUILD_CMD ${ATLAS_FLAKE8} ) -atlas_install_joboptions( share/*.py ) - diff --git a/Event/xAOD/xAODForwardCnv/share/xAODForwardCnv_jobOptions.py b/Event/xAOD/xAODForwardCnv/share/xAODForwardCnv_jobOptions.py deleted file mode 100644 index 07a22ffb93410b4ea57da36623bd15faa8c8f478..0000000000000000000000000000000000000000 --- a/Event/xAOD/xAODForwardCnv/share/xAODForwardCnv_jobOptions.py +++ /dev/null @@ -1,43 +0,0 @@ -# Enable xAOD making: -from RecExConfig.RecFlags import rec -rec.doWritexAOD = True -#FNAME="/afs/cern.ch/work/a/azemla/xAODDevelop/rel_2_test/test/MinBiasSliceAthenaTrigRDO/AOD.pool.root" -FNAME="AOD.pool.root" - -include( "AthenaPython/iread_file.py" ) - -# Access the algorithm sequence: -from AthenaCommon.AlgSequence import AlgSequence -theJob = AlgSequence() - -# Create a logger object: -from AthenaCommon.Logging import logging -logger = logging.getLogger( "xAODForwardCnv_jobOptions" ) - -# Create a POOL output file with the StoreGate contents: -from OutputStreamAthenaPool.MultipleStreamManager import MSMgr -xaodStream = MSMgr.NewPoolStream( "StreamAOD", "xAOD.pool.root" ) - -# Create some xAOD::TrigMinBias objects: -from xAODForwardCnv.xAODMBTSModuleCreator import xAODMBTSModuleCreator -xAODMBTSModuleCreator() - -from xAODForwardCnv.xAODForwardEventInfoCreator import xAODForwardEventInfoCreator -xAODForwardEventInfoCreator() - -# Check what happened to the stream: -xaodStream.Print() - -# Split all branches: -ServiceMgr.AthenaPoolCnvSvc.PoolAttributes += [ - "DEFAULT_SPLITLEVEL='1'" ] - -# Force POOL to just simply use the StoreGate keys as branch names: -ServiceMgr.AthenaPoolCnvSvc.SubLevelBranchName = "<key>" - -# Do some additional tweaking: -from AthenaCommon.AppMgr import theApp -theApp.EvtMax = 10 -ServiceMgr.MessageSvc.OutputLevel = VERBOSE -ServiceMgr.MessageSvc.defaultLimit = 1000 - diff --git a/Event/xAOD/xAODMuonCnv/CMakeLists.txt b/Event/xAOD/xAODMuonCnv/CMakeLists.txt index 9753a9a157ae0c65428f76a2959f3eea25c6beaf..1063ca068eeded93e48f63b4469b8b7fb8dbe2bd 100644 --- a/Event/xAOD/xAODMuonCnv/CMakeLists.txt +++ b/Event/xAOD/xAODMuonCnv/CMakeLists.txt @@ -1,6 +1,4 @@ -################################################################################ -# Package: xAODMuonCnv -################################################################################ +# Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration # Declare the package name: atlas_subdir( xAODMuonCnv ) @@ -16,5 +14,3 @@ atlas_add_component( xAODMuonCnv src/*.cxx src/components/*.cxx LINK_LIBRARIES xAODMuonCnvLib AthenaBaseComps AthenaKernel xAODPrimitives muonEvent Particle xAODTruth) - - diff --git a/Event/xAOD/xAODMuonCnv/share/xAODMuonCnv_jobOptions.py b/Event/xAOD/xAODMuonCnv/share/xAODMuonCnv_jobOptions.py deleted file mode 100755 index 4310cf46bc5e930cfa6e7a18d57d978ecb2ec49d..0000000000000000000000000000000000000000 --- a/Event/xAOD/xAODMuonCnv/share/xAODMuonCnv_jobOptions.py +++ /dev/null @@ -1,50 +0,0 @@ -# $Id: ClusterCreator_jobOptions.py 297184 2013-10-03 11:18:41Z krasznaa $ - -# Set up the reading of the input AOD: -FNAME = "root://eosatlas.cern.ch//eos/atlas/atlasdatadisk/rucio/valid1/36/d9/AOD.01447493._000116.pool.root.1" - -include( "AthenaPython/iread_file.py" ) -# from RecExConfig.RecFlags import rec -# from AthenaCommon.BeamFlags import jobproperties -# from AthenaCommon.AthenaCommonFlags import athenaCommonFlags -# from AthenaCommon.GlobalFlags import globalflags - -# Access the algorithm sequence: -from AthenaCommon.AlgSequence import AlgSequence -theJob = AlgSequence() - -# Create a POOL output file with the StoreGate contents: -from OutputStreamAthenaPool.MultipleStreamManager import MSMgr -xaodStream = MSMgr.NewPoolStream( "StreamAOD", "xAOD.pool.root" ) - -# Set up its contents: -# xaodStream.AddItem( "xAOD::CaloClusterContainer_v1#*" ) -# xaodStream.AddItem( "xAOD::CaloClusterAuxContainer_v1#*" ) - -xaodStream.AddItem( "xAOD::TruthParticleContainer#*") -xaodStream.AddItem( "xAOD::TruthParticleAuxContainer#*") -xaodStream.AddItem( "xAOD::TrackParticleContainer#*" ) -xaodStream.AddItem( "xAOD::TrackParticleAuxContainer#*" ) -xaodStream.AddItem( "xAOD::MuonContainer#*" ) -xaodStream.AddItem( "xAOD::MuonAuxContainer#*" ) -xaodStream.AddItem( "xAOD::MuonSegmentContainer#*") -xaodStream.AddItem( "xAOD::MuonSegmentAuxContainer#*") -xaodStream.AddItem( "xAOD::EventInfo#*" ) -xaodStream.AddItem( "xAOD::EventAuxInfo#*" ) -xaodStream.Print() - -# Split all branches: -ServiceMgr.AthenaPoolCnvSvc.PoolAttributes += [ - "DEFAULT_SPLITLEVEL='99'" ] - -# Force POOL to just simply use the StoreGate keys as branch names: -ServiceMgr.AthenaPoolCnvSvc.SubLevelBranchName = "<key>" - -# Do some additional tweaking: -from AthenaCommon.AppMgr import theApp -theApp.EvtMax = -1 -ServiceMgr.MessageSvc.OutputLevel = INFO -ServiceMgr.MessageSvc.defaultLimit = 1000000 - -#from VP1Algs.VP1AlgsConf import VP1Alg -#theJob += VP1Alg() diff --git a/Event/xAOD/xAODTauCnv/CMakeLists.txt b/Event/xAOD/xAODTauCnv/CMakeLists.txt index fa0f04ca4ef38044e886f224c15745729e06926f..7aa2ba580aa0a55afd4a35248ce5947d6c582d04 100644 --- a/Event/xAOD/xAODTauCnv/CMakeLists.txt +++ b/Event/xAOD/xAODTauCnv/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration +# Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration # Declare the package name: atlas_subdir( xAODTauCnv ) @@ -17,5 +17,3 @@ atlas_add_component( xAODTauCnv # Install files from the package: atlas_install_python_modules( python/*.py POST_BUILD_CMD ${ATLAS_FLAKE8} ) -atlas_install_joboptions( share/*.py ) - diff --git a/Event/xAOD/xAODTauCnv/share/xAODTauCnv_jobOptions.py b/Event/xAOD/xAODTauCnv/share/xAODTauCnv_jobOptions.py deleted file mode 100644 index 6b8f5e8ced7fda00b19d15e28391d358ba4229f4..0000000000000000000000000000000000000000 --- a/Event/xAOD/xAODTauCnv/share/xAODTauCnv_jobOptions.py +++ /dev/null @@ -1,46 +0,0 @@ - - -# $Id: xAODTauCnv_jobOptions.py 579532 2014-01-22 12:40:33Z janus $ - -# Turn off Tau reconstruction manually for now... -from RecExConfig.RecFlags import rec -#rec.doTau = False - -# Set up the reading of a file: -FNAME = "AOD.pool.root" -include( "AthenaPython/iread_file.py" ) - -# Access the algorithm sequence: -from AthenaCommon.AlgSequence import AlgSequence -theJob = AlgSequence() - -# Create a POOL output file with the StoreGate contents: -from OutputStreamAthenaPool.MultipleStreamManager import MSMgr -xaodStream = MSMgr.NewPoolStream( "StreamAOD", "xAOD.pool.root" ) - -# Create the xAOD taus: -from xAODTauCnv.xAODTauConverter import xAODTauConverter -xAODTauConverter() - - -# Check what happened to the stream: -xaodStream.Print() - -# Split all branches: -ServiceMgr.AthenaPoolCnvSvc.PoolAttributes += [ - "DEFAULT_SPLITLEVEL='1'" ] - -# Force POOL to just simply use the StoreGate keys as branch names: -ServiceMgr.AthenaPoolCnvSvc.SubLevelBranchName = "<key>" - -# Do some additional tweaking: -from AthenaCommon.AppMgr import theApp -theApp.EvtMax = 10 -ServiceMgr.MessageSvc.OutputLevel = INFO -ServiceMgr.MessageSvc.defaultLimit = 1000000 - - -#theJob.AntiKt4LCTopoJetsCnv.Enable = False -#theJob.AntiKt6LCTopoJetsCnv.Enable = False -#theJob.AntiKt4TopoEMJetsCnv.Enable = False -#theJob.AntiKt6TopoEMJetsCnv.Enable = False diff --git a/Event/xAOD/xAODTauCnv/share/xAODTauReader_jobOptions.py b/Event/xAOD/xAODTauCnv/share/xAODTauReader_jobOptions.py deleted file mode 100644 index a0cd5aba0996df84c88cd18d8ace75bc8e19de00..0000000000000000000000000000000000000000 --- a/Event/xAOD/xAODTauCnv/share/xAODTauReader_jobOptions.py +++ /dev/null @@ -1,24 +0,0 @@ -# $Id: xAODTauReader_jobOptions.py 632174 2014-11-29 15:23:36Z krasznaa $ - -# Set up the reading of a file: -import AthenaPoolCnvSvc.ReadAthenaPool -ServiceMgr.EventSelector.InputCollections = [ - "AOD.pool.root" - ] - -# Access the algorithm sequence: -from AthenaCommon.AlgSequence import AlgSequence -theJob = AlgSequence() - -# Add the test algorithm: -theJob += CfgMgr.xAODMaker__TauJetReaderAlg( "TauJetReaderAlg", - OutputLevel = DEBUG ) - -# Write out a file with the "new" tau objects: -from OutputStreamAthenaPool.MultipleStreamManager import MSMgr -xaodStream = MSMgr.NewPoolRootStream( "StreamAOD", "newAOD.pool.root" ) -xaodStream.AddItem( [ "xAOD::TauJetContainer#*", - "xAOD::TauJetAuxContainer#*" ] ) - -# Some additional settings: -theApp.EvtMax = 10 diff --git a/Event/xAOD/xAODTrigCaloCnv/CMakeLists.txt b/Event/xAOD/xAODTrigCaloCnv/CMakeLists.txt index 7022ee13570477bafddd9d06e1d6846e3e0ccd1f..bf5095779100a9e35f5cdddfb3cca2c08b0153e8 100644 --- a/Event/xAOD/xAODTrigCaloCnv/CMakeLists.txt +++ b/Event/xAOD/xAODTrigCaloCnv/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration +# Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration # Declare the package name: atlas_subdir( xAODTrigCaloCnv ) @@ -17,5 +17,3 @@ atlas_add_component( xAODTrigCaloCnv # Install files from the package: atlas_install_python_modules( python/*.py POST_BUILD_CMD ${ATLAS_FLAKE8} ) -atlas_install_joboptions( share/*.py ) - diff --git a/Event/xAOD/xAODTrigCaloCnv/share/xAODTrigCaloCnv_jobOptions.py b/Event/xAOD/xAODTrigCaloCnv/share/xAODTrigCaloCnv_jobOptions.py deleted file mode 100644 index d4fc97fe4579e66e3ef0be8e54d435073563b41c..0000000000000000000000000000000000000000 --- a/Event/xAOD/xAODTrigCaloCnv/share/xAODTrigCaloCnv_jobOptions.py +++ /dev/null @@ -1,55 +0,0 @@ -# $Id: xAODTrigCaloCnv_jobOptions.py 592334 2014-04-10 11:01:56Z krasznaa $ - -# Enable xAOD making: -from RecExConfig.RecFlags import rec -rec.doWritexAOD = True - -# Set up the reading of a file: -FNAME = "AOD.pool.root" -include( "AthenaPython/iread_file.py" ) - -# Access the algorithm sequence: -from AthenaCommon.AlgSequence import AlgSequence -theJob = AlgSequence() - -# Create a logger object: -from AthenaCommon.Logging import logging -logger = logging.getLogger( "xAODTrigCaloCnv_jobOptions" ) - -# Create a POOL output file with the StoreGate contents: -from OutputStreamAthenaPool.MultipleStreamManager import MSMgr -xaodStream = MSMgr.NewPoolStream( "StreamAOD", "xAOD.pool.root" ) - -# Create the xAOD trigger calorimeter cluster: -from xAODTrigCaloCnv.xAODTrigCaloClusterCreator import xAODTrigCaloClusterCreator -xAODTrigCaloClusterCreator() -alg = getattr( theJob, "xAODMaker::TrigCaloClusterCnvAlg" ) -alg.OutputLevel = DEBUG - -# Create the xAOD trigger EM cluster: -from xAODTrigCaloCnv.xAODTrigEMClusterCreator import xAODTrigEMClusterCreator -xAODTrigEMClusterCreator() -alg = getattr( theJob, "xAODMaker::TrigEMClusterCnvAlg" ) -alg.OutputLevel = DEBUG - -# Additional type(s) created automatically by RecExCommon: -xaodStream.AddItem( "xAOD::TrigCaloClusterContainer_v1#*" ) -xaodStream.AddItem( "xAOD::TrigCaloClusterAuxContainer_v1#*" ) -xaodStream.AddItem( "xAOD::TrigEMClusterContainer_v1#*" ) -xaodStream.AddItem( "xAOD::TrigEMClusterAuxContainer_v1#*" ) - -# Check what happened to the stream: -xaodStream.Print() - -# Split all branches: -ServiceMgr.AthenaPoolCnvSvc.PoolAttributes += [ - "DEFAULT_SPLITLEVEL='1'" ] - -# Force POOL to just simply use the StoreGate keys as branch names: -ServiceMgr.AthenaPoolCnvSvc.SubLevelBranchName = "<key>" - -# Do some additional tweaking: -from AthenaCommon.AppMgr import theApp -theApp.EvtMax = 100 -ServiceMgr.MessageSvc.OutputLevel = INFO -ServiceMgr.MessageSvc.defaultLimit = 1000 diff --git a/Event/xAOD/xAODTrigMinBiasCnv/CMakeLists.txt b/Event/xAOD/xAODTrigMinBiasCnv/CMakeLists.txt index 27a92ddd793a61da710fd74c5e33a93ee002f78c..e6b898a1d4198e4a3a9a814c7b1d2a44c0b31c84 100644 --- a/Event/xAOD/xAODTrigMinBiasCnv/CMakeLists.txt +++ b/Event/xAOD/xAODTrigMinBiasCnv/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration +# Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration # Declare the package name: atlas_subdir( xAODTrigMinBiasCnv ) @@ -17,5 +17,3 @@ atlas_add_component( xAODTrigMinBiasCnv # Install files from the package: atlas_install_python_modules( python/*.py POST_BUILD_CMD ${ATLAS_FLAKE8} ) -atlas_install_joboptions( share/*.py ) - diff --git a/Event/xAOD/xAODTrigMinBiasCnv/share/xAODTrigMinBiasCnv_jobOptions.py b/Event/xAOD/xAODTrigMinBiasCnv/share/xAODTrigMinBiasCnv_jobOptions.py deleted file mode 100755 index 3dd9a4911257dcd8910167f1852e924b42fd29fc..0000000000000000000000000000000000000000 --- a/Event/xAOD/xAODTrigMinBiasCnv/share/xAODTrigMinBiasCnv_jobOptions.py +++ /dev/null @@ -1,50 +0,0 @@ -# $Id: xAODTrigMinBiasCnv_jobOptions.py 592539 2014-04-11 10:17:29Z krasznaa $ - -# Enable xAOD making: -from RecExConfig.RecFlags import rec -rec.doWritexAOD = True -#FNAME="/afs/cern.ch/work/a/azemla/xAODDevelop/rel_2_test/test/MinBiasSliceAthenaTrigRDO/AOD.pool.root" -FNAME="/afs/cern.ch/user/a/azemla/workdir/xAODDevelop/DATA/mc11_7TeV.105200.T1_McAtNlo_Jimmy.merge.AOD.e835_s1272_s1274_r2730_r2780_tid541650_00/AOD.541650._000544.pool.root.1" - -include( "AthenaPython/iread_file.py" ) - -# Access the algorithm sequence: -from AthenaCommon.AlgSequence import AlgSequence -theJob = AlgSequence() - -# Create a logger object: -from AthenaCommon.Logging import logging -logger = logging.getLogger( "xAODTrigMinBiasCnv_jobOptions" ) - -# Create a POOL output file with the StoreGate contents: -from OutputStreamAthenaPool.MultipleStreamManager import MSMgr -xaodStream = MSMgr.NewPoolStream( "StreamAOD", "xAOD.pool.root" ) - -# Create some xAOD::TrigMinBias objects: -from xAODTrigMinBiasCnv.xAODTrigTrackCountsCreator import xAODTrigTrackCountsCreator -xAODTrigTrackCountsCreator() - -from xAODTrigMinBiasCnv.xAODTrigVertexCountsCreator import xAODTrigVertexCountsCreator -xAODTrigVertexCountsCreator() - -from xAODTrigMinBiasCnv.xAODTrigT2MbtsBitsCreator import xAODTrigT2MbtsBitsCreator -xAODTrigT2MbtsBitsCreator() - -from xAODTrigMinBiasCnv.xAODTrigSpacePointCountsCreator import xAODTrigSpacePointCountsCreator -xAODTrigSpacePointCountsCreator() - -# Check what happened to the stream: -xaodStream.Print() - -# Split all branches: -ServiceMgr.AthenaPoolCnvSvc.PoolAttributes += [ - "DEFAULT_SPLITLEVEL='1'" ] - -# Force POOL to just simply use the StoreGate keys as branch names: -ServiceMgr.AthenaPoolCnvSvc.SubLevelBranchName = "<key>" - -# Do some additional tweaking: -from AthenaCommon.AppMgr import theApp -theApp.EvtMax = 100 -ServiceMgr.MessageSvc.OutputLevel = VERBOSE -ServiceMgr.MessageSvc.defaultLimit = 1000 diff --git a/Event/xAOD/xAODTrigMissingETCnv/CMakeLists.txt b/Event/xAOD/xAODTrigMissingETCnv/CMakeLists.txt index d0ddf4145a5bc90321c2c0b7bf9538e319967e84..986db0138cff43f082e7afea75bcef6501b2a854 100644 --- a/Event/xAOD/xAODTrigMissingETCnv/CMakeLists.txt +++ b/Event/xAOD/xAODTrigMissingETCnv/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration +# Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration # Declare the package name: atlas_subdir( xAODTrigMissingETCnv ) @@ -17,5 +17,3 @@ atlas_add_component( xAODTrigMissingETCnv # Install files from the package: atlas_install_python_modules( python/*.py POST_BUILD_CMD ${ATLAS_FLAKE8} ) -atlas_install_joboptions( share/*.py ) - diff --git a/Event/xAOD/xAODTrigMissingETCnv/share/xAODTrigMissingETCnv_jobOptions.py b/Event/xAOD/xAODTrigMissingETCnv/share/xAODTrigMissingETCnv_jobOptions.py deleted file mode 100644 index e4f342a4251327209d511605efc222afc7a06588..0000000000000000000000000000000000000000 --- a/Event/xAOD/xAODTrigMissingETCnv/share/xAODTrigMissingETCnv_jobOptions.py +++ /dev/null @@ -1,42 +0,0 @@ -# $Id: xAODTrigMissingETCnv_jobOptions.py 592539 2014-04-11 10:17:29Z krasznaa $ - -# Enable xAOD making: -from RecExConfig.RecFlags import rec -rec.doWritexAOD = True - -# Set up the reading of a file: -FNAME = "AOD.pool.root" -include( "AthenaPython/iread_file.py" ) - -# Access the algorithm sequence: -from AthenaCommon.AlgSequence import AlgSequence -theJob = AlgSequence() - -# Create a logger object: -from AthenaCommon.Logging import logging -logger = logging.getLogger( "xAODTrigMissingETCnv_jobOptions" ) - -# Create a POOL output file with the StoreGate contents: -from OutputStreamAthenaPool.MultipleStreamManager import MSMgr -xaodStream = MSMgr.NewPoolStream( "StreamAOD", "xAOD.pool.root" ) - -# Create some xAOD::TrigMissingET objects: -from xAODTrigMissingETCnv.xAODTrigMissingETCreator import \ - xAODTrigMissingETCreator -xAODTrigMissingETCreator() - -# Check what happened to the stream: -xaodStream.Print() - -# Split all branches: -ServiceMgr.AthenaPoolCnvSvc.PoolAttributes += [ - "DEFAULT_SPLITLEVEL='1'" ] - -# Force POOL to just simply use the StoreGate keys as branch names: -ServiceMgr.AthenaPoolCnvSvc.SubLevelBranchName = "<key>" - -# Do some additional tweaking: -from AthenaCommon.AppMgr import theApp -theApp.EvtMax = 100 -ServiceMgr.MessageSvc.OutputLevel = INFO -ServiceMgr.MessageSvc.defaultLimit = 1000 diff --git a/Event/xAOD/xAODTriggerCnv/CMakeLists.txt b/Event/xAOD/xAODTriggerCnv/CMakeLists.txt index 1e5777204bba89e5c91b5d92d9025fc9b7738f26..279e033e4d59c4d71ef725bf0ae0da7af6acf0c0 100644 --- a/Event/xAOD/xAODTriggerCnv/CMakeLists.txt +++ b/Event/xAOD/xAODTriggerCnv/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration +# Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration # Declare the package name: atlas_subdir( xAODTriggerCnv ) @@ -67,4 +67,3 @@ endif() # Install files from the package: atlas_install_python_modules( python/*.py POST_BUILD_CMD ${ATLAS_FLAKE8} ) -atlas_install_joboptions( share/*.py ) diff --git a/Event/xAOD/xAODTriggerCnv/share/TriggerMenuMetaDataTool_jobOptions.py b/Event/xAOD/xAODTriggerCnv/share/TriggerMenuMetaDataTool_jobOptions.py deleted file mode 100644 index c232c63fb29168423f32f943bca3fe746342646b..0000000000000000000000000000000000000000 --- a/Event/xAOD/xAODTriggerCnv/share/TriggerMenuMetaDataTool_jobOptions.py +++ /dev/null @@ -1,42 +0,0 @@ -# $Id: TriggerMenuMetaDataTool_jobOptions.py 651874 2015-03-05 14:16:19Z krasznaa $ -# -# This is a simple test for xAODMaker::TriggerMenuMetaDataTool, testing if -# it does its job correctly during file processing. -# - -# Set up the reading of the input files using RecExCommon: -from AthenaCommon.AthenaCommonFlags import athenaCommonFlags -athenaCommonFlags.FilesInput = [ - "/afs/cern.ch/atlas/project/PAT/xAODs/r5787/" - "mc14_13TeV.110401.PowhegPythia_P2012_ttbar_nonallhad.merge.AOD." - "e2928_s1982_s2008_r5787_r5853_tid01597980_00/" - "AOD.01597980._000098.pool.root.1", - "/afs/cern.ch/atlas/project/PAT/xAODs/r5787/" - "mc14_13TeV.110401.PowhegPythia_P2012_ttbar_nonallhad.merge.AOD." - "e2928_s1982_s2008_r5787_r5853_tid01597980_00/" - "AOD.01597980._000420.pool.root.1" - ] -athenaCommonFlags.EvtMax = -1 - -# Include RecExCommon: -from RecExConfig.RecFlags import rec -rec.doCBNT.set_Value_and_Lock( False ) -rec.doWriteTAG.set_Value_and_Lock( False ) -rec.doAOD.set_Value_and_Lock( False ) -rec.doWriteAOD.set_Value_and_Lock( False ) -include( "RecExCommon/RecExCommon_topOptions.py" ) - -# Configure the metadata tool: -ToolSvc += CfgMgr.xAODMaker__TriggerMenuMetaDataTool( "TriggerMenuMetaDataTool", - OutputLevel = 1 ) -svcMgr.MetaDataSvc.MetaDataTools += [ ToolSvc.TriggerMenuMetaDataTool ] - -# Set up an output file: -from OutputStreamAthenaPool.MultipleStreamManager import MSMgr -output = MSMgr.NewPoolRootStream( "StreamAOD", "merged.pool.root" ) - -# Add some event and metadata items to the stream: -output.AddItem( [ "xAOD::EventInfo#EventInfo", - "xAOD::EventAuxInfo#EventInfoAux." ] ) -output.AddMetaDataItem( [ "xAOD::TriggerMenuContainer#TriggerMenu", - "xAOD::TriggerMenuAuxContainer#TriggerMenuAux." ] ) diff --git a/Event/xAOD/xAODTriggerCnv/share/decisionFix_preInclude.py b/Event/xAOD/xAODTriggerCnv/share/decisionFix_preInclude.py deleted file mode 100644 index 7b4bd990affa7018edd99754e71938fc72129165..0000000000000000000000000000000000000000 --- a/Event/xAOD/xAODTriggerCnv/share/decisionFix_preInclude.py +++ /dev/null @@ -1,16 +0,0 @@ - - -from AthenaCommon.AlgSequence import AlgSequence -topSequence=AlgSequence() - -#fix xAOD trigger object by scheduling cnv alg again - -include( "RecExCond/RecExCommon_flags.py" ) - -from xAODTriggerCnv.xAODTriggerCnvConf import xAODMaker__TrigDecisionCnvAlg -topSequence += xAODMaker__TrigDecisionCnvAlg("TrigDecisionCnvAlg") -topSequence.TrigDecisionCnvAlg.xAODKey = 'xTrigDecision' - -from TrigDecisionTool.TrigDecisionToolConf import Trig__TrigDecisionTool -ToolSvc += Trig__TrigDecisionTool( "TrigDecisionTool" ) - diff --git a/Event/xAOD/xAODTriggerCnv/share/xAODTriggerCnv_jobOptions.py b/Event/xAOD/xAODTriggerCnv/share/xAODTriggerCnv_jobOptions.py deleted file mode 100644 index fa025d4c6460b3dd96515f5bb59bc15f2a955329..0000000000000000000000000000000000000000 --- a/Event/xAOD/xAODTriggerCnv/share/xAODTriggerCnv_jobOptions.py +++ /dev/null @@ -1,63 +0,0 @@ -# $Id: xAODTriggerCnv_jobOptions.py 583381 2014-02-14 15:58:20Z krasznaa $ - -# Enable xAOD making: -from RecExConfig.RecFlags import rec -rec.doWritexAOD = True - -# Set up the reading of a file: -FNAME = "AOD.pool.root" -include( "AthenaPython/iread_file.py" ) - -# Access the algorithm sequence: -from AthenaCommon.AlgSequence import AlgSequence -theJob = AlgSequence() - -# Create a logger object: -from AthenaCommon.Logging import logging -logger = logging.getLogger( "xAODTriggerCnv_jobOptions" ) - -# Create a POOL output file with the StoreGate contents: -from OutputStreamAthenaPool.MultipleStreamManager import MSMgr -xaodStream = MSMgr.NewPoolStream( "StreamAOD", "xAOD.pool.root" ) - -# Create the xAOD RoIs: -from xAODTriggerCnv.xAODRoICreator import xAODRoICreator -xAODRoICreator() - -# Create the xAOD trigger decision: -from xAODTriggerCnv.xAODTrigDecisionCreator import xAODTrigDecisionCreator -xAODTrigDecisionCreator() - -# Add bunch configuration metadata to the file: -from xAODTriggerCnv.xAODBunchConfCreator import xAODBunchConfCreator -xAODBunchConfCreator() - -# Additional type(s) created automatically by RecExCommon: -xaodStream.AddItem( "xAOD::EventInfo_v1#EventInfo" ) -xaodStream.AddItem( "xAOD::EventAuxInfo_v1#EventInfoAux." ) -xaodStream.AddItem( "xAOD::CaloClusterContainer_v1#*" ) -xaodStream.AddItem( "xAOD::CaloClusterAuxContainer_v1#*" ) -xaodStream.AddItem( "xAOD::MuonContainer_v1#*" ) -xaodStream.AddItem( "xAOD::MuonAuxContainer_v1#*" ) -xaodStream.AddItem( "xAOD::TrackParticleContainer_v1#*" ) -xaodStream.AddItem( "xAOD::TrackParticleAuxContainer_v1#*" ) -xaodStream.AddItem( "xAOD::VertexContainer_v1#*" ) -xaodStream.AddItem( "xAOD::VertexAuxContainer_v1#*" ) -xaodStream.AddItem( "xAOD::TauJetContainer_v1#*" ) -xaodStream.AddItem( "xAOD::TauJetAuxContainer_v1#*" ) - -# Check what happened to the stream: -xaodStream.Print() - -# Split all branches: -ServiceMgr.AthenaPoolCnvSvc.PoolAttributes += [ - "DEFAULT_SPLITLEVEL='1'" ] - -# Force POOL to just simply use the StoreGate keys as branch names: -ServiceMgr.AthenaPoolCnvSvc.SubLevelBranchName = "<key>" - -# Do some additional tweaking: -from AthenaCommon.AppMgr import theApp -theApp.EvtMax = 100 -ServiceMgr.MessageSvc.OutputLevel = INFO -ServiceMgr.MessageSvc.defaultLimit = 1000 diff --git a/Trigger/TrigConfiguration/TrigConfData/TrigConfData/L1ThrExtraInfo.h b/Trigger/TrigConfiguration/TrigConfData/TrigConfData/L1ThrExtraInfo.h index 2edfbc62350e8d5ad618f08613e226a0c6c8d0e3..1a67a211a7e97b04433feb127890fb6afded9c75 100644 --- a/Trigger/TrigConfiguration/TrigConfData/TrigConfData/L1ThrExtraInfo.h +++ b/Trigger/TrigConfiguration/TrigConfData/TrigConfData/L1ThrExtraInfo.h @@ -352,16 +352,26 @@ namespace TrigConf { public: WorkingPoints_cTAU( const boost::property_tree::ptree & ); bool isDefined() const { return m_isDefined; } - int isolation_fw() const { return m_isolation_fw; } + unsigned int isolation_fw() const { return m_isolation_fw; } float isolation_d() const { return m_isolation_d; } - int isolation_jTAUCoreScale_fw() const { return m_isolation_jTAUCoreScale_fw; } + unsigned int isolation_jTAUCoreScale_fw() const { return m_isolation_jTAUCoreScale_fw; } float isolation_jTAUCoreScale_d() const { return m_isolation_jTAUCoreScale_d; } + float eTAU_rCoreMin_WP_d() const { return m_eTAU_rCoreMin_WP_d; } + unsigned int eTAU_rCoreMin_WP_fw() const { return m_eTAU_rCoreMin_WP_fw; } + Selection::WP eTAU_rCoreMin_WP() const { return static_cast<Selection::WP>(m_eTAU_rCoreMin_WP_fw); } + float eTAU_rHadMin_WP_d() const { return m_eTAU_rHadMin_WP_d; } + unsigned int eTAU_rHadMin_WP_fw() const { return m_eTAU_rHadMin_WP_fw; } + Selection::WP eTAU_rHadMin_WP() const { return static_cast<Selection::WP>(m_eTAU_rHadMin_WP_fw); } private: bool m_isDefined {false}; - int m_isolation_fw {0}; + unsigned int m_isolation_fw {0}; float m_isolation_d {0}; - int m_isolation_jTAUCoreScale_fw {0}; + unsigned int m_isolation_jTAUCoreScale_fw {0}; float m_isolation_jTAUCoreScale_d {0}; + float m_eTAU_rCoreMin_WP_d {0}; + unsigned int m_eTAU_rCoreMin_WP_fw {0}; + float m_eTAU_rHadMin_WP_d {0}; + unsigned int m_eTAU_rHadMin_WP_fw {0}; }; L1ThrExtraInfo_cTAU(const std::string & thrTypeName, const ptree & data) : L1ThrExtraInfoBase(thrTypeName, data) { load(); } diff --git a/Trigger/TrigConfiguration/TrigConfData/TrigConfData/L1Threshold.h b/Trigger/TrigConfiguration/TrigConfData/TrigConfData/L1Threshold.h index f2521425f6b4de9d827e00223ff3e19f26b71afd..8a85393d6c8c671b881b7960b5b1015eed440e90 100644 --- a/Trigger/TrigConfiguration/TrigConfData/TrigConfData/L1Threshold.h +++ b/Trigger/TrigConfiguration/TrigConfData/TrigConfData/L1Threshold.h @@ -230,6 +230,7 @@ namespace TrigConf { Selection::WP m_rHad { Selection::WP::NONE }; }; + class L1ThrExtraInfo_jTAU; class L1Threshold_jTAU final : public L1Threshold_Calo { public: L1Threshold_jTAU( const std::string & name, const std::string & type, std::weak_ptr<L1ThrExtraInfoBase> extraInfo, const ptree & data) : @@ -238,6 +239,7 @@ namespace TrigConf { virtual std::string className() const override { return "L1Threshold_jTAU"; } // access functions Selection::WP isolation() const { return m_isolation; } + const std::shared_ptr<L1ThrExtraInfo_jTAU> getExtraInfo() const; protected: virtual void update() override { L1Threshold_Calo::update(); @@ -249,6 +251,7 @@ namespace TrigConf { Selection::WP m_isolation { Selection::WP::NONE }; }; + class L1ThrExtraInfo_cTAU; class L1Threshold_cTAU final : public L1Threshold_Calo { public: L1Threshold_cTAU( const std::string & name, const std::string & type, std::weak_ptr<L1ThrExtraInfoBase> extraInfo, const ptree & data) : @@ -257,6 +260,7 @@ namespace TrigConf { virtual std::string className() const override { return "L1Threshold_cTAU"; } // access functions Selection::WP isolation() const { return m_isolation; } + const std::shared_ptr<L1ThrExtraInfo_cTAU> getExtraInfo() const; protected: virtual void update() override { L1Threshold_Calo::update(); diff --git a/Trigger/TrigConfiguration/TrigConfData/src/L1ThrExtraInfo.cxx b/Trigger/TrigConfiguration/TrigConfData/src/L1ThrExtraInfo.cxx index 8242744ddf346e4ee5b9ca5cc289f2068036e740..ee78637676dddff341d72a05f74a0726f69aac74 100644 --- a/Trigger/TrigConfiguration/TrigConfData/src/L1ThrExtraInfo.cxx +++ b/Trigger/TrigConfiguration/TrigConfData/src/L1ThrExtraInfo.cxx @@ -469,14 +469,19 @@ TrigConf::L1ThrExtraInfo_jTAU::load() TrigConf::L1ThrExtraInfo_cTAU::WorkingPoints_cTAU::WorkingPoints_cTAU( const boost::property_tree::ptree & pt ) { m_isDefined = true; m_isolation_d = pt.get_optional<float>("isolation").get_value_or(0); - m_isolation_fw = pt.get_optional<float>("isolation_fw").get_value_or(0); + m_isolation_fw = pt.get_optional<unsigned int>("isolation_fw").get_value_or(0); m_isolation_jTAUCoreScale_d = pt.get_optional<float>("isolation_jTAUCoreScale").get_value_or(0); - m_isolation_jTAUCoreScale_fw = pt.get_optional<float>("isolation_jTAUCoreScale_fw").get_value_or(0); + m_isolation_jTAUCoreScale_fw = pt.get_optional<unsigned int>("isolation_jTAUCoreScale_fw").get_value_or(0); + m_eTAU_rCoreMin_WP_d = pt.get_optional<float>("eTAU_rCoreMin").get_value_or(0); + m_eTAU_rCoreMin_WP_fw = pt.get_optional<unsigned int>("eTAU_rCoreMin_WP_fw").get_value_or(0); + m_eTAU_rHadMin_WP_d = pt.get_optional<float>("eTAU_rHadMin").get_value_or(0); + m_eTAU_rHadMin_WP_fw = pt.get_optional<unsigned int>("eTAU_rHadMin_WP_fw").get_value_or(0); } std::ostream & TrigConf::operator<<(std::ostream & os, const TrigConf::L1ThrExtraInfo_cTAU::WorkingPoints_cTAU & iso) { os << "isolation_fw=" << iso.isolation_fw() << ", isolation_jTAUCoreScale_fw=" << iso.isolation_jTAUCoreScale_fw(); + os << ", eTAU_rCoreMin_WP_fw=" << iso.eTAU_rCoreMin_WP_fw() << ", eTAU_rHadMin_WP_fw=" << iso.eTAU_rHadMin_WP_fw(); return os; } diff --git a/Trigger/TrigConfiguration/TrigConfData/src/L1Threshold.cxx b/Trigger/TrigConfiguration/TrigConfData/src/L1Threshold.cxx index 41d8618c57aa5c976fb95054239915ec50aa8aaf..c7a864748c17f816d1f1139929b8543038c7ef0a 100644 --- a/Trigger/TrigConfiguration/TrigConfData/src/L1Threshold.cxx +++ b/Trigger/TrigConfiguration/TrigConfData/src/L1Threshold.cxx @@ -168,6 +168,12 @@ TrigConf::L1Threshold_eTAU::load() m_etaDepThrValue.setOutsideRangeValue(getAttribute("maxValue", true, 14000000)); } +const std::shared_ptr<TrigConf::L1ThrExtraInfo_jTAU> +TrigConf::L1Threshold_jTAU::getExtraInfo() const +{ + return dynamic_pointer_cast<TrigConf::L1ThrExtraInfo_jTAU>(m_extraInfo.lock()); +} + void TrigConf::L1Threshold_jTAU::load() { @@ -178,6 +184,12 @@ TrigConf::L1Threshold_jTAU::load() m_etaDepThrValue.setOutsideRangeValue(getAttribute("maxValue", true, 14000000)); } +const std::shared_ptr<TrigConf::L1ThrExtraInfo_cTAU> +TrigConf::L1Threshold_cTAU::getExtraInfo() const +{ + return dynamic_pointer_cast<TrigConf::L1ThrExtraInfo_cTAU>(m_extraInfo.lock()); +} + void TrigConf::L1Threshold_cTAU::load() { diff --git a/Trigger/TrigConfiguration/TrigConfIO/src/JsonFileWriterL1.cxx b/Trigger/TrigConfiguration/TrigConfIO/src/JsonFileWriterL1.cxx index 61099912406b15f6ca3be9128bb7d350ce735c2b..c7ee5fc0d4ef2bfdc09a2b2b2371598708d1efa1 100644 --- a/Trigger/TrigConfiguration/TrigConfIO/src/JsonFileWriterL1.cxx +++ b/Trigger/TrigConfiguration/TrigConfIO/src/JsonFileWriterL1.cxx @@ -561,6 +561,14 @@ TrigConf::JsonFileWriterL1::writeJsonFile(const std::string & filename, const L1 stream << std::fixed << std::setprecision(3) << iso.value().isolation_jTAUCoreScale_d(); jWPIso["isolation_jTAUCoreScale"] = std::stod(stream.str()); jWPIso["isolation_jTAUCoreScale_fw"] = iso.value().isolation_jTAUCoreScale_fw(); + stream.str(""); + stream << std::fixed << std::setprecision(3) << iso.value().eTAU_rCoreMin_WP_d(); + jWPIso["eTAU_rCoreMin"] = std::stod(stream.str()); + jWPIso["eTAU_rCoreMin_WP_fw"] = iso.value().eTAU_rCoreMin_WP_fw(); + stream.str(""); + stream << std::fixed << std::setprecision(3) << iso.value().eTAU_rHadMin_WP_d(); + jWPIso["eTAU_rHadMin"] = std::stod(stream.str()); + jWPIso["eTAU_rHadMin_WP_fw"] = iso.value().eTAU_rHadMin_WP_fw(); jThrType["workingPoints"][wpstr] += jWPIso; } } diff --git a/Trigger/TrigSteer/DecisionHandling/src/RoRSeqFilter.cxx b/Trigger/TrigSteer/DecisionHandling/src/RoRSeqFilter.cxx index 83f1dcbd3bbf76449a71cb785197b6524acecd71..948b18c62245925f8ed2275be64283db29c6c9fd 100644 --- a/Trigger/TrigSteer/DecisionHandling/src/RoRSeqFilter.cxx +++ b/Trigger/TrigSteer/DecisionHandling/src/RoRSeqFilter.cxx @@ -50,9 +50,9 @@ StatusCode RoRSeqFilter::initialize() for ( size_t i = 0; i < m_ioMapping.size(); ++i ) { for ( unsigned inIndex: m_ioMapping[i] ) { - ATH_MSG_INFO("Input collection: " << m_inputKeys[inIndex] ); + ATH_MSG_DEBUG("Input collection: " << m_inputKeys[inIndex] ); } - ATH_MSG_INFO(" Routed to output collection " << m_outputKeys[i] ); + ATH_MSG_DEBUG(" Routed to output collection " << m_outputKeys[i] ); } // crosscheck mapping (also the default one) diff --git a/Trigger/TrigSteer/HLTSeeding/src/cTauRoIThresholdsTool.cxx b/Trigger/TrigSteer/HLTSeeding/src/cTauRoIThresholdsTool.cxx index 0d683b2cab4c2a5f8bdecc186db704ba84f2c7f2..b6f8bf3391a87ce8186c8befa350be230ac9f233 100644 --- a/Trigger/TrigSteer/HLTSeeding/src/cTauRoIThresholdsTool.cxx +++ b/Trigger/TrigSteer/HLTSeeding/src/cTauRoIThresholdsTool.cxx @@ -6,7 +6,6 @@ #include "StoreGate/exceptions.h" #include "GaudiKernel/ThreadLocalContext.h" #include "L1TopoAlgorithms/cTauMultiplicity.h" -#include "L1TopoCoreSim/TopoSteeringStructure.h" StatusCode cTauRoIThresholdsTool::initialize() { @@ -17,15 +16,7 @@ StatusCode cTauRoIThresholdsTool::initialize() { uint64_t cTauRoIThresholdsTool::getPattern(const xAOD::eFexTauRoI& eTau, const RoIThresholdsTool::ThrVec& menuThresholds, - const TrigConf::L1ThrExtraInfoBase& menuExtraInfo) const { - - std::map<std::string, int> isoFW_CTAU, isoFW_CTAU_jTAUCoreScale; - TCS::TopoSteeringStructure::setIsolationFW_CTAU(isoFW_CTAU, isoFW_CTAU_jTAUCoreScale, menuExtraInfo); - - unsigned int eFexEt{eTau.etTOB()}; // eTAU Et in units of 100 MeV - int eFexEta{eTau.iEta()}; - - unsigned int jFexCoreEt = 0, jFexIsoEt = 0; // jTAU core and isolation Et in units of 200 MeV + const TrigConf::L1ThrExtraInfoBase& /*menuExtraInfo*/) const { // Get the jTau matched to the eTau using jTauLink_t = ElementLink<xAOD::jFexTauRoIContainer>; @@ -40,15 +31,14 @@ uint64_t cTauRoIThresholdsTool::getPattern(const xAOD::eFexTauRoI& eTau, if (matched) { const xAOD::jFexTauRoI* jTau = *jTauLink; - jFexIsoEt = jTau->tobIso(); - jFexCoreEt = jTau->tobEt(); - ATH_MSG_DEBUG("eFex tau eta,phi = " << eTau.iEta() << ", " << eTau.iPhi() << ", jFex tau eta,phi = " << jTau->globalEta() << ", " << jTau->globalPhi() - << ", eFex et (100 MeV/counts) = " << eFexEt << ", jFex et (200 MeV/counts) = " << jTau->tobEt() << ", jFex iso (200 MeV/counts) = " << jTau->tobIso()); + << ", eFex et (100 MeV/counts) = " << eTau.etTOB() << ", jFex et (200 MeV/counts) = " << jTau->tobEt() << ", jFex iso (200 MeV/counts) = " << jTau->tobIso() + << ", eFex rCore/BDT = " << eTau.tauOneThresholds() << ", eFex rHad = " << eTau.tauTwoThresholds()); } else { ATH_MSG_DEBUG("eFex tau eta,phi = " << eTau.iEta() << ", " << eTau.iPhi() - << ", eFex et (100 MeV/counts) = " << eFexEt << ", no matching jTau found"); + << ", eFex et (100 MeV/counts) = " << eTau.etTOB() << ", no matching jTau found" + << ", eFex rCore/BDT = " << eTau.tauOneThresholds() << ", eFex rHad = " << eTau.tauTwoThresholds()); } @@ -60,13 +50,16 @@ uint64_t cTauRoIThresholdsTool::getPattern(const xAOD::eFexTauRoI& eTau, // Check isolation threshold - unmatched eTau treated as perfectly isolated, ATR-25927 // The core and isolation E_T values are multiplied by 2 to normalise to 100 MeV/counts units - bool passIso = matched ? TCS::cTauMultiplicity::checkIsolationWP(isoFW_CTAU, isoFW_CTAU_jTAUCoreScale, 2*static_cast<float>(jFexCoreEt), 2*static_cast<float>(jFexIsoEt), static_cast<float>(eFexEt), TrigConf::Selection::wpToString(thr->isolation())) : true; + bool passIso = matched ? TCS::cTauMultiplicity::checkIsolationWP(eTau, **jTauLink, *thr) : true; + + // Check eTAU rCore/BDT and rHad thresholds + bool passeTAUWP = TCS::cTauMultiplicity::checkeTAUWP(eTau, *thr); - // Check pt threshold - using iEta coordinate for the eFEX ensures a 0.1 granularity of the eta coordinate, + // Check et threshold - using iEta coordinate for the eFEX ensures a 0.1 granularity of the eta coordinate, // as expected from the menu method thrValue100MeV - bool passPt = eFexEt > thr->thrValue100MeV(eFexEta); + bool passEt = eTau.etTOB() > thr->thrValue100MeV(eTau.iEta()); - if ( passIso && passPt ) { + if (passIso && passeTAUWP && passEt) { thresholdMask |= (1<<thr->mapping()); } diff --git a/Trigger/TrigT1/Global/GlobalSimulation/src/GlobalL1TopoSimulation.cxx b/Trigger/TrigT1/Global/GlobalSimulation/src/GlobalL1TopoSimulation.cxx index 5960098f32c476c6152b729328baf8bd369e3539..03b911b28fe767833fc3923151d8e1d68d3b379b 100644 --- a/Trigger/TrigT1/Global/GlobalSimulation/src/GlobalL1TopoSimulation.cxx +++ b/Trigger/TrigT1/Global/GlobalSimulation/src/GlobalL1TopoSimulation.cxx @@ -88,10 +88,6 @@ namespace GlobalSim { const TrigConf::L1Menu*); uint32_t interpretGenericParam(const std::string&); - - std::map<std::string, int> isolationFW_CTAU(const TrigConf::L1Menu* l1menu); - std::map<std::string, int> isolationFW_CTAU_jTAUCoreScale(const TrigConf::L1Menu* l1menu); - std::map<std::string, int> isolationFW_JTAU(const TrigConf::L1Menu* l1menu); } namespace GlobalSim { @@ -605,10 +601,6 @@ namespace GlobalSim { throw std::runtime_error("Error down casting to CountingAlg"); } - pca->setIsolationFW_CTAU(isolationFW_CTAU(l1menu), isolationFW_CTAU_jTAUCoreScale(l1menu)); - pca->setIsolationFW_JTAU(isolationFW_JTAU(l1menu)); - - pca->setThreshold(l1thr); alg->setL1TopoHistSvc(histSvc); pca->initialize(); @@ -699,97 +691,5 @@ namespace GlobalSim { } } - std::map<std::string, int> isolationFW_CTAU(const TrigConf::L1Menu* l1menu){ - const TrigConf::L1ThrExtraInfo_cTAU& ctauExtraInfo = - l1menu->thrExtraInfo().cTAU(); - - int CTAU_iso_fw_loose = - static_cast<int>(ctauExtraInfo.isolation(TrigConf::Selection::WP::LOOSE, - 0).isolation_fw()); - - int CTAU_iso_fw_medium = - static_cast<int>(ctauExtraInfo.isolation(TrigConf::Selection::WP::MEDIUM, - 0).isolation_fw()); - - int CTAU_iso_fw_tight = - static_cast<int>(ctauExtraInfo.isolation(TrigConf::Selection::WP::TIGHT, - 0).isolation_fw()); - - auto isolationFW = std::map<std::string, int>(); - - isolationFW[TrigConf::Selection::wpToString(TrigConf::Selection::WP::LOOSE)] - = CTAU_iso_fw_loose; - - isolationFW[TrigConf::Selection::wpToString(TrigConf::Selection::WP::MEDIUM)] - = CTAU_iso_fw_medium; - - isolationFW[TrigConf::Selection::wpToString(TrigConf::Selection::WP::TIGHT)] - = CTAU_iso_fw_tight; - - return isolationFW; - } - - std::map<std::string, int> isolationFW_CTAU_jTAUCoreScale(const TrigConf::L1Menu* l1menu){ - const TrigConf::L1ThrExtraInfo_cTAU& ctauExtraInfo = - l1menu->thrExtraInfo().cTAU(); - - int CTAU_iso_fw_jTAUCoreScale_loose = - static_cast<int>(ctauExtraInfo.isolation(TrigConf::Selection::WP::LOOSE, - 0).isolation_jTAUCoreScale_fw()); - - int CTAU_iso_fw_jTAUCoreScale_medium = - static_cast<int>(ctauExtraInfo.isolation(TrigConf::Selection::WP::MEDIUM, - 0).isolation_jTAUCoreScale_fw()); - - int CTAU_iso_fw_jTAUCoreScale_tight = - static_cast<int>(ctauExtraInfo.isolation(TrigConf::Selection::WP::TIGHT, - 0).isolation_jTAUCoreScale_fw()); - - auto isolationFW_jTAUCoreScale = std::map<std::string, int>(); - - isolationFW_jTAUCoreScale[TrigConf::Selection::wpToString(TrigConf::Selection::WP::LOOSE)] - = CTAU_iso_fw_jTAUCoreScale_loose; - - isolationFW_jTAUCoreScale[TrigConf::Selection::wpToString(TrigConf::Selection::WP::MEDIUM)] - = CTAU_iso_fw_jTAUCoreScale_medium; - - isolationFW_jTAUCoreScale[TrigConf::Selection::wpToString(TrigConf::Selection::WP::TIGHT)] - = CTAU_iso_fw_jTAUCoreScale_tight; - - return isolationFW_jTAUCoreScale; - } - - std::map<std::string, int> isolationFW_JTAU(const TrigConf::L1Menu* l1menu){ - const TrigConf::L1ThrExtraInfo_jTAU& jtauExtraInfo = - l1menu->thrExtraInfo().jTAU(); - - int JTAU_iso_fw_loose = - static_cast<int>(jtauExtraInfo.isolation(TrigConf::Selection::WP::LOOSE, - 0).isolation_fw()); - - int JTAU_iso_fw_medium = - static_cast<int>(jtauExtraInfo.isolation(TrigConf::Selection::WP::MEDIUM, - 0).isolation_fw()); - - int JTAU_iso_fw_tight = - static_cast<int>(jtauExtraInfo.isolation(TrigConf::Selection::WP::TIGHT, - 0).isolation_fw()); - - auto isolationFW = std::map<std::string, int>(); - - isolationFW[TrigConf::Selection::wpToString(TrigConf::Selection::WP::LOOSE)] - = JTAU_iso_fw_loose; - - isolationFW[TrigConf::Selection::wpToString(TrigConf::Selection::WP::MEDIUM)] - = JTAU_iso_fw_medium; - - isolationFW[TrigConf::Selection::wpToString(TrigConf::Selection::WP::TIGHT)] - = JTAU_iso_fw_tight; - - return isolationFW; - } - - - } diff --git a/Trigger/TrigT1/L1Topo/L1TopoAlgorithms/L1TopoAlgorithms/cTauMultiplicity.h b/Trigger/TrigT1/L1Topo/L1TopoAlgorithms/L1TopoAlgorithms/cTauMultiplicity.h index bb032ee6cd4c15f418bbac2e031bcea0c082c439..a08e30831bcfd950d66d6da145dc8cb2545665b4 100644 --- a/Trigger/TrigT1/L1Topo/L1TopoAlgorithms/L1TopoAlgorithms/cTauMultiplicity.h +++ b/Trigger/TrigT1/L1Topo/L1TopoAlgorithms/L1TopoAlgorithms/cTauMultiplicity.h @@ -27,7 +27,6 @@ namespace TCS { class cTauMultiplicity : public CountingAlg { public: - cTauMultiplicity(const std::string & name); virtual ~cTauMultiplicity(); @@ -43,19 +42,18 @@ namespace TCS { static size_t cTauMatching(const xAOD::eFexTauRoI& eTau, const xAOD::jFexTauRoIContainer& jTauRoIs); // Returns true when a matching is found static bool cTauMatching(const xAOD::eFexTauRoI& eTau, const xAOD::jFexTauRoI& jTau); - // Converts the isolation score to bit to be used for the working point assignement - static bool checkIsolationWP(const std::map<std::string, int>& isoFW_CTAU, const std::map<std::string, int>& isoFW_CTAU_jTAUCoreScale, const float jTauCoreEt, const float jTauIsoEt, const float eTauEt, const std::string& isolation_wp); + // Check cTAU isolation + static bool checkIsolationWP(const xAOD::eFexTauRoI& eTau, const xAOD::jFexTauRoI& jTau, const TrigConf::L1Threshold_cTAU& thr); + // Check eTAU rCore/BDT and rHad WPs + static bool checkeTAUWP(const xAOD::eFexTauRoI& eTau, const TrigConf::L1Threshold_cTAU& thr); #endif private: - const TrigConf::L1Threshold_cTAU* m_threshold{nullptr}; - std::map<std::string, int> m_isoFW_CTAU; - std::map<std::string, int> m_isoFW_CTAU_jTAUCoreScale; + std::shared_ptr<TrigConf::L1ThrExtraInfo_cTAU> m_extraInfo; - // This function is used to map the ctau isolation working points into a common format with eFEX EM and taus. - // This allows us to use same functionalities from ConfigurableAlg (L1TopoInterfaces) to apply isolation cuts in multiplicity algorithms for all flavour of TOBS - bool checkIsolationWP(const TCS::cTauTOB* etauCand, const TCS::cTauTOB* jtauCand, const std::string& isolation_wp) const; + bool checkIsolationWP(const TCS::cTauTOB* etauCand, const TCS::cTauTOB* jtauCand) const; + bool checkeTAUWP(const TCS::cTauTOB* etauCand) const; // Matching function for L1Topo bool cTauMatching(const TCS::cTauTOB* etauCand, const TCS::cTauTOB* jtauCand) const; @@ -73,6 +71,8 @@ namespace TCS { std::vector<std::string> m_histcTauPartialIsoTight; std::vector<std::string> m_histcTauIsoMatchedPass; + using WP = TrigConf::Selection::WP; + }; } diff --git a/Trigger/TrigT1/L1Topo/L1TopoAlgorithms/L1TopoAlgorithms/jTauMultiplicity.h b/Trigger/TrigT1/L1Topo/L1TopoAlgorithms/L1TopoAlgorithms/jTauMultiplicity.h index 8befe1f07b877a16eecdd248f8cbfee926a3ede2..ac87c88e9db050ff5e1da31bf75627fe2ed9a190 100644 --- a/Trigger/TrigT1/L1Topo/L1TopoAlgorithms/L1TopoAlgorithms/jTauMultiplicity.h +++ b/Trigger/TrigT1/L1Topo/L1TopoAlgorithms/L1TopoAlgorithms/jTauMultiplicity.h @@ -31,14 +31,13 @@ namespace TCS { virtual StatusCode process( const TCS::InputTOBArray & input, Count & count ) override final ; - - private: - - TrigConf::L1Threshold const * m_threshold{nullptr}; - std::map<std::string, int> m_isoFW_JTAU; + TrigConf::L1Threshold_jTAU const * m_threshold{nullptr}; + std::shared_ptr<TrigConf::L1ThrExtraInfo_jTAU> m_extraInfo; + + bool checkIsolation( const TCS::jTauTOB* jtau ) const; - unsigned int convertIsoToBit( const TCS::jTauTOB * jtau ) const; + using WP = TrigConf::Selection::WP; }; } diff --git a/Trigger/TrigT1/L1Topo/L1TopoAlgorithms/L1TopoAlgorithms/jTauNoSort.h b/Trigger/TrigT1/L1Topo/L1TopoAlgorithms/L1TopoAlgorithms/jTauNoSort.h index f9c8ce1d9d5d6598706759870d2a2ca8443fc6ac..e272c8383318976c583f95848bdbe457d41e1102 100644 --- a/Trigger/TrigT1/L1Topo/L1TopoAlgorithms/L1TopoAlgorithms/jTauNoSort.h +++ b/Trigger/TrigT1/L1Topo/L1TopoAlgorithms/L1TopoAlgorithms/jTauNoSort.h @@ -30,10 +30,9 @@ namespace TCS { parType_t m_numberOfjTaus = { 0 }; parType_t m_iso = { 0 }; + parType_t m_passIsolation = { 0 }; - std::map<std::string, int> m_isoFW_JTAU; - - unsigned int convertIsoToBit( const TCS::jTauTOB * jtau ) const; + bool checkIsolation(const TCS::jTauTOB* jtau) const; }; diff --git a/Trigger/TrigT1/L1Topo/L1TopoAlgorithms/Root/cTauMultiplicity.cxx b/Trigger/TrigT1/L1Topo/L1TopoAlgorithms/Root/cTauMultiplicity.cxx index e3686885658361419972694f2a12fad306df97e5..9397590f2dbb47fd1e2d92c95abe052734decea7 100644 --- a/Trigger/TrigT1/L1Topo/L1TopoAlgorithms/Root/cTauMultiplicity.cxx +++ b/Trigger/TrigT1/L1Topo/L1TopoAlgorithms/Root/cTauMultiplicity.cxx @@ -13,7 +13,11 @@ #include "L1TopoEvent/TOBArray.h" #include "L1TopoEvent/cTauTOBArray.h" +#include "TrigConfData/L1ThrExtraInfo.h" + #include <cmath> + + REGISTER_ALG_TCS(cTauMultiplicity) TCS::cTauMultiplicity::cTauMultiplicity(const std::string & name) : CountingAlg(name) { @@ -31,15 +35,8 @@ TCS::StatusCode TCS::cTauMultiplicity::initialize() { return StatusCode::FAILURE; } - m_isoFW_CTAU = isolationFW_CTAU(); - m_isoFW_CTAU_jTAUCoreScale = isolationFW_CTAU_jTAUCoreScale(); - - TRG_MSG_DEBUG("Initializing cTauMultiplicity L1Topo Algorithm"); - for(const auto& [wp, iso] : m_isoFW_CTAU) { - TRG_MSG_DEBUG("WP \"" << wp << "\": R=" << iso << ", jTAUCoreScale=" << m_isoFW_CTAU_jTAUCoreScale[wp]); - } + m_extraInfo = m_threshold->getExtraInfo(); - // book histograms std::string hname_accept = "cTauMultiplicity_accept_EtaPt_"+m_threshold->name(); bookHistMult(m_histAccept, hname_accept, "Mult_"+m_threshold->name(), "#eta#times40", "E_{t} [GeV]", 200, -200, 200, 100, 0, 100); @@ -98,22 +95,27 @@ TCS::StatusCode TCS::cTauMultiplicity::process( const TCS::InputTOBArray & input if((*jtauCand)->tobType() != TCS::JTAU) continue; - isMatched = cTauMatching( *etauCand, *jtauCand ); + isMatched = cTauMatching(*etauCand, *jtauCand); if(isMatched) { + float etauCand_et = static_cast<float>((*etauCand)->Et()); + float etauCand_eta = static_cast<float>((*etauCand)->etaDouble()); + float jtauCand_et = static_cast<float>((*jtauCand)->Et()); + float jtauCand_etIso = static_cast<float>((*jtauCand)->EtIso()); // Updated isolation condition, WP-dependent (ATR-28641) // "Partial" isolation formula: I = (E_T^{jTAU Iso} + jTAUCoreScale * E_T^{jTAU Core}) / E_T^{eTAU} // This formula is missing the eTAU Core substraction from the numerator, grouped with the isolation cut value - isolation_partial_loose = (static_cast<float>((*jtauCand)->EtIso()) + m_isoFW_CTAU_jTAUCoreScale.at("Loose")/1024.0 * static_cast<float>((*jtauCand)->Et())) / static_cast<float>((*etauCand)->Et()); // Internal variable for monitoring - isolation_partial_loose = (static_cast<float>((*jtauCand)->EtIso()) + m_isoFW_CTAU_jTAUCoreScale.at("Medium")/1024.0 * static_cast<float>((*jtauCand)->Et())) / static_cast<float>((*etauCand)->Et()); // Internal variable for monitoring - isolation_partial_medium12 = (static_cast<float>((*jtauCand)->EtIso()) + m_isoFW_CTAU_jTAUCoreScale.at("Medium12")/1024.0 * static_cast<float>((*jtauCand)->Et())) / static_cast<float>((*etauCand)->Et()); // Internal variable for monitoring - isolation_partial_medium20 = (static_cast<float>((*jtauCand)->EtIso()) + m_isoFW_CTAU_jTAUCoreScale.at("Medium20")/1024.0 * static_cast<float>((*jtauCand)->Et())) / static_cast<float>((*etauCand)->Et()); // Internal variable for monitoring - isolation_partial_medium30 = (static_cast<float>((*jtauCand)->EtIso()) + m_isoFW_CTAU_jTAUCoreScale.at("Medium30")/1024.0 * static_cast<float>((*jtauCand)->Et())) / static_cast<float>((*etauCand)->Et()); // Internal variable for monitoring - isolation_partial_medium35 = (static_cast<float>((*jtauCand)->EtIso()) + m_isoFW_CTAU_jTAUCoreScale.at("Medium35")/1024.0 * static_cast<float>((*jtauCand)->Et())) / static_cast<float>((*etauCand)->Et()); // Internal variable for monitoring - isolation_partial_tight = (static_cast<float>((*jtauCand)->EtIso()) + m_isoFW_CTAU_jTAUCoreScale.at("Tight")/1024.0 * static_cast<float>((*jtauCand)->Et())) / static_cast<float>((*etauCand)->Et()); // Internal variable for monitoring + isolation_partial_loose = (jtauCand_etIso + m_extraInfo->isolation(WP::LOOSE, etauCand_eta).isolation_jTAUCoreScale_fw()/1024.0 * jtauCand_et) / etauCand_et; // Internal variable for monitoring + isolation_partial_loose = (jtauCand_etIso + m_extraInfo->isolation(WP::MEDIUM, etauCand_eta).isolation_jTAUCoreScale_fw()/1024.0 * jtauCand_et) / etauCand_et; // Internal variable for monitoring + isolation_partial_medium12 = (jtauCand_etIso + m_extraInfo->isolation(WP::MEDIUM12, etauCand_eta).isolation_jTAUCoreScale_fw()/1024.0 * jtauCand_et) / etauCand_et; // Internal variable for monitoring + isolation_partial_medium20 = (jtauCand_etIso + m_extraInfo->isolation(WP::MEDIUM20, etauCand_eta).isolation_jTAUCoreScale_fw()/1024.0 * jtauCand_et) / etauCand_et; // Internal variable for monitoring + isolation_partial_medium30 = (jtauCand_etIso + m_extraInfo->isolation(WP::MEDIUM30, etauCand_eta).isolation_jTAUCoreScale_fw()/1024.0 * jtauCand_et) / etauCand_et; // Internal variable for monitoring + isolation_partial_medium35 = (jtauCand_etIso + m_extraInfo->isolation(WP::MEDIUM35, etauCand_eta).isolation_jTAUCoreScale_fw()/1024.0 * jtauCand_et) / etauCand_et; // Internal variable for monitoring + isolation_partial_tight = (jtauCand_etIso + m_extraInfo->isolation(WP::TIGHT, etauCand_eta).isolation_jTAUCoreScale_fw()/1024.0 * jtauCand_et) / etauCand_et; // Internal variable for monitoring // Old isolation condition coded as in firmware: https://indico.cern.ch/event/1079697/contributions/4541419/attachments/2315137/3940824/cTAU_FirmwareAlgoProposal.pdf page 8 - isIsolated = checkIsolationWP(*etauCand, *jtauCand, TrigConf::Selection::wpToString(m_threshold->isolation())); + isIsolated = checkIsolationWP(*etauCand, *jtauCand); + break; // Break loop when a match is found } @@ -137,6 +139,8 @@ TCS::StatusCode TCS::cTauMultiplicity::process( const TCS::InputTOBArray & input if(isMatched && isIsolated) accept = true; // This is a good matched cTau if(!isMatched) accept = true; // This is a non-matched eTau + if(!checkeTAUWP(*etauCand)) accept = false; // Check eTAU rCore/BDT and rHad WP + // Menu threshold uses 0.1 eta granularity but eFex objects have 0.025 eta granularity // eFex eta is calculated as 4*eta_tower (0.1 gran.) + seed (0.025 gran.), eta from -25 to 24 int eta_thr; @@ -144,6 +148,7 @@ TCS::StatusCode TCS::cTauMultiplicity::process( const TCS::InputTOBArray & input else eta_thr = (*etauCand)->eta() - (*etauCand)->eta()%4 - 4; accept = accept && (*etauCand)->Et() > m_threshold->thrValue100MeV(eta_thr/4); // Convert eta_thr to units of 0.1 to pass as an argument + if(accept) { counting++; fillHist2D(m_histAccept[0], (*etauCand)->eta(), (*etauCand)->EtDouble()); @@ -162,10 +167,17 @@ TCS::StatusCode TCS::cTauMultiplicity::process( const TCS::InputTOBArray & input } -bool TCS::cTauMultiplicity::checkIsolationWP(const TCS::cTauTOB* etauCand, const TCS::cTauTOB* jtauCand, const std::string& isolation_wp) const { - if(isolation_wp == "None") return true; - if(jtauCand->EtIso()*1024 + jtauCand->Et()*m_isoFW_CTAU_jTAUCoreScale.at(isolation_wp) < etauCand->Et()*m_isoFW_CTAU.at(isolation_wp)) return true; - return false; +bool TCS::cTauMultiplicity::checkIsolationWP(const TCS::cTauTOB* etauCand, const TCS::cTauTOB* jtauCand) const { + if(m_threshold->isolation() == WP::NONE) return true; + auto iso_wp = m_extraInfo->isolation(m_threshold->isolation(), etauCand->etaDouble()); + return jtauCand->EtIso()*1024 + jtauCand->Et()*iso_wp.isolation_jTAUCoreScale_fw() < etauCand->Et()*iso_wp.isolation_fw(); +} + + +bool TCS::cTauMultiplicity::checkeTAUWP(const TCS::cTauTOB* etauCand) const { + if(m_threshold->isolation() == WP::NONE) return true; + auto iso_wp = m_extraInfo->isolation(m_threshold->isolation(), etauCand->etaDouble()); + return etauCand->RCore() >= iso_wp.eTAU_rCoreMin_WP_fw() && etauCand->RHad() >= iso_wp.eTAU_rHadMin_WP_fw(); } @@ -232,6 +244,7 @@ size_t TCS::cTauMultiplicity::cTauMatching(const xAOD::eFexTauRoI& eTau, const x } + bool TCS::cTauMultiplicity::cTauMatching(const xAOD::eFexTauRoI& eTau, const xAOD::jFexTauRoI& jTau) { // eFEX: etaTower = iEta, phiTower = iPhi @@ -254,11 +267,18 @@ bool TCS::cTauMultiplicity::cTauMatching(const xAOD::eFexTauRoI& eTau, const xAO } -bool -TCS::cTauMultiplicity::checkIsolationWP(const std::map<std::string, int>& isoFW_CTAU, const std::map<std::string, int>& isoFW_CTAU_jTAUCoreScale, const float jTauCoreEt, const float jTauIsoEt, const float eTauEt, const std::string& isolation_wp) { - if(isolation_wp == "None") return true; - if(jTauIsoEt*1024 + jTauCoreEt*isoFW_CTAU_jTAUCoreScale.at(isolation_wp) < eTauEt*isoFW_CTAU.at(isolation_wp)) return true; - return false; + +bool TCS::cTauMultiplicity::checkIsolationWP(const xAOD::eFexTauRoI& eTau, const xAOD::jFexTauRoI& jTau, const TrigConf::L1Threshold_cTAU& thr) { + if(thr.isolation() == WP::NONE) return true; + auto iso_wp = thr.getExtraInfo()->isolation(thr.isolation(), eTau.eta()); + return jTau.tobIso()*2*1024 + jTau.tobEt()*2*iso_wp.isolation_jTAUCoreScale_fw() < eTau.etTOB()*iso_wp.isolation_fw(); +} + + +bool TCS::cTauMultiplicity::checkeTAUWP(const xAOD::eFexTauRoI& eTau, const TrigConf::L1Threshold_cTAU& thr) { + if(thr.isolation() == WP::NONE) return true; + auto iso_wp = thr.getExtraInfo()->isolation(thr.isolation(), eTau.eta()); + return eTau.tauOneThresholds() >= iso_wp.eTAU_rCoreMin_WP_fw() && eTau.tauTwoThresholds() >= iso_wp.eTAU_rHadMin_WP_fw(); } #endif diff --git a/Trigger/TrigT1/L1Topo/L1TopoAlgorithms/Root/jTauMultiplicity.cxx b/Trigger/TrigT1/L1Topo/L1TopoAlgorithms/Root/jTauMultiplicity.cxx index c361972594f6708863b526006aaefb5fc20666ae..5631f2306f662ed2bf5904cc4fc64cc1063364da 100644 --- a/Trigger/TrigT1/L1Topo/L1TopoAlgorithms/Root/jTauMultiplicity.cxx +++ b/Trigger/TrigT1/L1Topo/L1TopoAlgorithms/Root/jTauMultiplicity.cxx @@ -21,6 +21,8 @@ #include "L1TopoEvent/TOBArray.h" #include "L1TopoEvent/jTauTOBArray.h" +#include "TrigConfData/L1ThrExtraInfo.h" + REGISTER_ALG_TCS(jTauMultiplicity) using namespace std; @@ -28,10 +30,7 @@ using namespace std; TCS::jTauMultiplicity::jTauMultiplicity(const std::string & name) : CountingAlg(name) { - - setNumberOutputBits(12); //To-Do: Make this flexible to addapt to the menu. Each counting requires more than one bit - } TCS::jTauMultiplicity::~jTauMultiplicity(){} @@ -39,9 +38,8 @@ TCS::jTauMultiplicity::~jTauMultiplicity(){} TCS::StatusCode TCS::jTauMultiplicity::initialize() { - - m_threshold = getThreshold(); - m_isoFW_JTAU = isolationFW_JTAU(); + m_threshold = dynamic_cast<const TrigConf::L1Threshold_jTAU*>(getThreshold()); + m_extraInfo = m_threshold->getExtraInfo(); // book histograms std::string hname_accept = "jTauMultiplicity_accept_EtaPt_"+m_threshold->name(); @@ -67,10 +65,6 @@ TCS::StatusCode TCS::jTauMultiplicity::process( const TCS::InputTOBArray & input, Count & count ) { - - // Grab the threshold and cast it into the right type - const auto& jTAUThr = dynamic_cast<const TrigConf::L1Threshold_jTAU &>(*m_threshold); - // Grab inputs const jTauTOBArray & jtaus = dynamic_cast<const jTauTOBArray&>(input); @@ -82,9 +76,9 @@ TCS::jTauMultiplicity::process( const TCS::InputTOBArray & input, ++jtau ) { // Dividing by 4 standing for converting eta from 0.025 to 0.1 granularity as it is defined in the menu as 0.1 gran. - bool passed = (*jtau)->Et() > jTAUThr.thrValue100MeV((*jtau)->eta()/4); + bool passed = (*jtau)->Et() > m_threshold->thrValue100MeV((*jtau)->eta()/4); - if ( !isocut(TrigConf::Selection::wpToString(jTAUThr.isolation()), convertIsoToBit(*jtau)) ) {continue;} + if (!checkIsolation(*jtau)) continue; if (passed) { counting++; @@ -102,15 +96,10 @@ TCS::jTauMultiplicity::process( const TCS::InputTOBArray & input, } -unsigned int -TCS::jTauMultiplicity::convertIsoToBit(const TCS::jTauTOB * jtau) const { - unsigned int bit = 0; - - // Assign the tightest accept WP as default bit - if( jtau->EtIso()*1024 < jtau->Et()*m_isoFW_JTAU.at("Loose") ) bit = 1; - if( jtau->EtIso()*1024 < jtau->Et()*m_isoFW_JTAU.at("Medium") ) bit = 2; - if( jtau->EtIso()*1024 < jtau->Et()*m_isoFW_JTAU.at("Tight") ) bit = 3; - - return bit; +bool +TCS::jTauMultiplicity::checkIsolation(const TCS::jTauTOB* jtau) const { + if(m_threshold->isolation() == WP::NONE) return true; + auto iso_wp = m_extraInfo->isolation(m_threshold->isolation(), jtau->etaDouble()); + return jtau->EtIso()*1024 < jtau->Et()*iso_wp.isolation_fw(); } diff --git a/Trigger/TrigT1/L1Topo/L1TopoAlgorithms/Root/jTauNoSort.cxx b/Trigger/TrigT1/L1Topo/L1TopoAlgorithms/Root/jTauNoSort.cxx index c71c0a59b5662a5cd10d51df0aa9724a551b9e61..b2d84bde9c986e90d20d1fb057f71cf6e9f61f0d 100644 --- a/Trigger/TrigT1/L1Topo/L1TopoAlgorithms/Root/jTauNoSort.cxx +++ b/Trigger/TrigT1/L1Topo/L1TopoAlgorithms/Root/jTauNoSort.cxx @@ -15,8 +15,10 @@ REGISTER_ALG_TCS(jTauNoSort) // constructor TCS::jTauNoSort::jTauNoSort(const std::string & name) : SortingAlg(name) { - defineParameter( "InputWidth", 120 ); // for fw - defineParameter( "OutputWidth", 120 ); + defineParameter("InputWidth", 120); // for fw + defineParameter("OutputWidth", 120); + defineParameter("Isolation", 1024); + defineParameter("passIsolation", false); } @@ -27,8 +29,7 @@ TCS::StatusCode TCS::jTauNoSort::initialize() { m_numberOfjTaus = parameter("OutputWidth").value(); m_iso = parameter("Isolation").value(); - - m_isoFW_JTAU = isolationFW_JTAU(); + m_passIsolation = parameter("passIsolation").value(); return TCS::StatusCode::SUCCESS; } @@ -42,7 +43,7 @@ TCS::jTauNoSort::sort(const InputTOBArray & input, TOBArray & output) { for(jTauTOBArray::const_iterator jtau = clusters.begin(); jtau!= clusters.end(); ++jtau ) { // Isolation cut - if ( !isocut(m_iso, convertIsoToBit(*jtau)) ) {continue;} + if(!checkIsolation(*jtau)) continue; const GenericTOB gtob(**jtau); output.push_back( gtob ); @@ -61,15 +62,9 @@ TCS::jTauNoSort::sort(const InputTOBArray & input, TOBArray & output) { } -unsigned int -TCS::jTauNoSort::convertIsoToBit(const TCS::jTauTOB * jtau) const { - unsigned int bit = 0; - - // Assign the tightest accept WP as default bit - if( jtau->EtIso()*1024 < jtau->Et()*m_isoFW_JTAU.at("Loose") ) bit = 1; - if( jtau->EtIso()*1024 < jtau->Et()*m_isoFW_JTAU.at("Medium") ) bit = 2; - if( jtau->EtIso()*1024 < jtau->Et()*m_isoFW_JTAU.at("Tight") ) bit = 3; - - return bit; +bool +TCS::jTauNoSort::checkIsolation(const TCS::jTauTOB* jtau) const { + if(m_passIsolation) return true; + return jtau->EtIso()*1024 < jtau->Et()*m_iso; } diff --git a/Trigger/TrigT1/L1Topo/L1TopoCoreSim/L1TopoCoreSim/TopoSteering.h b/Trigger/TrigT1/L1Topo/L1TopoCoreSim/L1TopoCoreSim/TopoSteering.h index 0bf19735fbdb386167bccf1e63e084e77b3edea8..e263cdd4e5d69800086a269aae4809437a8519e5 100644 --- a/Trigger/TrigT1/L1Topo/L1TopoCoreSim/L1TopoCoreSim/TopoSteering.h +++ b/Trigger/TrigT1/L1Topo/L1TopoCoreSim/L1TopoCoreSim/TopoSteering.h @@ -90,10 +90,6 @@ namespace TCS { void setLegacyMode(bool isLegacyTopo) {m_isLegacyTopo=isLegacyTopo;} - // l1menu isolation info - void setIsolationFW_CTAU( const std::map<std::string, int> & isolationFW_CTAU, const std::map<std::string, int> & isolationFW_CTAU_jTAUCoreScale ) { m_isolationFW_CTAU = isolationFW_CTAU; m_isolationFW_CTAU_jTAUCoreScale = isolationFW_CTAU_jTAUCoreScale; } - void setIsolationFW_JTAU( const std::map<std::string, int> & isolationFW_JTAU ) { m_isolationFW_JTAU = isolationFW_JTAU; } - /** * @brief enables the histogramming service */ @@ -155,10 +151,6 @@ namespace TCS { bool m_useBitwise{false}; // Using bitwise algorithms? Disabled by default. Needs a menu global flag. bool m_isLegacyTopo{false}; - - std::map<std::string, int> m_isolationFW_CTAU; // FW isolation WPs for cTau - std::map<std::string, int> m_isolationFW_CTAU_jTAUCoreScale; // FW isolation WPs for cTau (jTAUCore factor) - std::map<std::string, int> m_isolationFW_JTAU; // FW isolation WPs for jTau TopoInputEvent m_inputEvent; // the input event diff --git a/Trigger/TrigT1/L1Topo/L1TopoCoreSim/L1TopoCoreSim/TopoSteeringStructure.h b/Trigger/TrigT1/L1Topo/L1TopoCoreSim/L1TopoCoreSim/TopoSteeringStructure.h index b22950a50ae3352265ed0cfadb8d58af330cf008..d6bbbdeacf02b390218a16e0f7928acca2cebba7 100644 --- a/Trigger/TrigT1/L1Topo/L1TopoCoreSim/L1TopoCoreSim/TopoSteeringStructure.h +++ b/Trigger/TrigT1/L1Topo/L1TopoCoreSim/L1TopoCoreSim/TopoSteeringStructure.h @@ -55,21 +55,6 @@ namespace TCS { // resets the connectors (status, intermediate TOBs, and decision of algs) StatusCode reset(); - // l1menu isolation info - const std::map<std::string, int> & isolationFW_CTAU() const { return m_isolationFW_CTAU; } - const std::map<std::string, int> & isolationFW_CTAU_jTAUCoreScale() const { return m_isolationFW_CTAU_jTAUCoreScale; } - const std::map<std::string, int> & isolationFW_JTAU() const { return m_isolationFW_JTAU; } - - void setIsolationFW_CTAU(const TrigConf::L1Menu& l1menu); - void setIsolationFW_JTAU(const TrigConf::L1Menu& l1menu); - - // Functions used by HLT seeding - #ifndef TRIGCONF_STANDALONE - - static void setIsolationFW_CTAU( std::map<std::string, int>& isoFW_CTAU, std::map<std::string, int>& isoFW_CTAU_jTAUCoreScale, const TrigConf::L1ThrExtraInfoBase& menuExtraInfo ); - - #endif - // print void print(std::ostream & o) const; @@ -103,10 +88,6 @@ namespace TCS { std::map<std::string, TCS::InputConnector*> m_inputLookup; // input connectors (subset of m_connectors) by connector name - std::map<std::string, int> m_isolationFW_CTAU; // FW isolation WPs for cTau - std::map<std::string, int> m_isolationFW_CTAU_jTAUCoreScale; // FW isolation WPs for cTau (jTAUCore factor) - std::map<std::string, int> m_isolationFW_JTAU; // FW isolation WPs for jTau - std::vector<TCS::ParameterSpace*> m_parameters; }; diff --git a/Trigger/TrigT1/L1Topo/L1TopoCoreSim/Root/TopoSteering.cxx b/Trigger/TrigT1/L1Topo/L1TopoCoreSim/Root/TopoSteering.cxx index bf1524f635ea213db8d89de02a0ef87877697b85..762dccd46c24c8ad1a2657ebfc65aa69ae982209 100644 --- a/Trigger/TrigT1/L1Topo/L1TopoCoreSim/Root/TopoSteering.cxx +++ b/Trigger/TrigT1/L1Topo/L1TopoCoreSim/Root/TopoSteering.cxx @@ -100,8 +100,6 @@ TopoSteering::initializeAlgorithms() { alg->setL1TopoHistSvc(m_histSvc); } alg->setLegacyMode(m_isLegacyTopo); - alg->setIsolationFW_CTAU(structure().isolationFW_CTAU(), structure().isolationFW_CTAU_jTAUCoreScale()); - alg->setIsolationFW_JTAU(structure().isolationFW_JTAU()); alg->initialize(); } @@ -488,6 +486,7 @@ TopoSteering::setAlgMsgLevel( TrigConf::MSGTC::Level lvl ) { alg->msg().setLevel(lvl); } } + //---------------------------------------------------------- void TopoSteering::setHardwareBits(const std::bitset<numberOfL1TopoBits> &triggerBits, const std::bitset<numberOfL1TopoBits> &ovrflowBits) diff --git a/Trigger/TrigT1/L1Topo/L1TopoCoreSim/Root/TopoSteeringStructure.cxx b/Trigger/TrigT1/L1Topo/L1TopoCoreSim/Root/TopoSteeringStructure.cxx index f15675b3d3a0163115aec36f4d790972d21cd0c0..57b5858ec634a598d4924e65ac374ed7d9b4a81e 100644 --- a/Trigger/TrigT1/L1Topo/L1TopoCoreSim/Root/TopoSteeringStructure.cxx +++ b/Trigger/TrigT1/L1Topo/L1TopoCoreSim/Root/TopoSteeringStructure.cxx @@ -128,10 +128,6 @@ TCS::TopoSteeringStructure::setupFromMenu ATLAS_NOT_THREAD_SAFE (const TrigConf: << " L1Topo steering structure: configuring from L1 Topo Menu " << endl << "/***************************************************************************/" << endl; - // Fill cTau and jTau isolation information (to be used in multiplicity algorithms) - setIsolationFW_CTAU(l1menu); - setIsolationFW_JTAU(l1menu); - // set<TCS::inputTOBType_t> neededInputs; // Stores inputs for DecisionConnectors vector<string> storedConn; // Stores decision connectors in order to avoid double counting vector<vector<string>> confAlgorithms; // Stores algorithm name/category that have been configured in L1Menu to be used for setting the parameters @@ -517,46 +513,3 @@ TCS::TopoSteeringStructure::countingConnector(const std::string & output) { return 0; } - -void -TCS::TopoSteeringStructure::setIsolationFW_CTAU(const TrigConf::L1Menu& l1menu) { - const TrigConf::L1ThrExtraInfo_cTAU &cTauExtraInfo = l1menu.thrExtraInfo().cTAU(); - - using WP = TrigConf::Selection::WP; - for(const WP wp : {WP::LOOSE, WP::MEDIUM, WP::TIGHT, WP::LOOSE12, WP::LOOSE20, WP::LOOSE30, WP::LOOSE35, WP::MEDIUM12, WP::MEDIUM20, WP::MEDIUM30, WP::MEDIUM35, WP::TIGHT12, WP::TIGHT20, WP::TIGHT30, WP::TIGHT35}) { - const TrigConf::L1ThrExtraInfo_cTAU::WorkingPoints_cTAU& isol = cTauExtraInfo.isolation(wp, 0); - - m_isolationFW_CTAU[TrigConf::Selection::wpToString(wp)] = static_cast<int>(isol.isolation_fw()); - m_isolationFW_CTAU_jTAUCoreScale[TrigConf::Selection::wpToString(wp)] = static_cast<int>(isol.isolation_jTAUCoreScale_fw()); - } -} - - -void -TCS::TopoSteeringStructure::setIsolationFW_JTAU(const TrigConf::L1Menu& l1menu) { - const TrigConf::L1ThrExtraInfo_jTAU &jTauExtraInfo = l1menu.thrExtraInfo().jTAU(); - - using WP = TrigConf::Selection::WP; - for(const WP wp : {WP::LOOSE, WP::MEDIUM, WP::TIGHT}) { - m_isolationFW_JTAU[TrigConf::Selection::wpToString(wp)] = static_cast<int>(jTauExtraInfo.isolation(wp, 0).isolation_fw()); - } -} - - -// Functions used by HLT seeding -#ifndef TRIGCONF_STANDALONE - -void -TCS::TopoSteeringStructure::setIsolationFW_CTAU(std::map<std::string, int>& isoFW_CTAU, std::map<std::string, int>& isoFW_CTAU_jTAUCoreScale, const TrigConf::L1ThrExtraInfoBase& menuExtraInfo) { - const TrigConf::L1ThrExtraInfo_cTAU& cTauExtraInfo = dynamic_cast<const TrigConf::L1ThrExtraInfo_cTAU&>(menuExtraInfo); - - using WP = TrigConf::Selection::WP; - for(const WP wp : {WP::LOOSE, WP::MEDIUM, WP::TIGHT, WP::LOOSE12, WP::LOOSE20, WP::LOOSE30, WP::LOOSE35, WP::MEDIUM12, WP::MEDIUM20, WP::MEDIUM30, WP::MEDIUM35, WP::TIGHT12, WP::TIGHT20, WP::TIGHT30, WP::TIGHT35}) { - const TrigConf::L1ThrExtraInfo_cTAU::WorkingPoints_cTAU& isol = cTauExtraInfo.isolation(wp, 0); - - isoFW_CTAU[TrigConf::Selection::wpToString(wp)] = static_cast<int>(isol.isolation_fw()); - isoFW_CTAU_jTAUCoreScale[TrigConf::Selection::wpToString(wp)] = static_cast<int>(isol.isolation_jTAUCoreScale_fw()); - } -} - -#endif diff --git a/Trigger/TrigT1/L1Topo/L1TopoInterfaces/L1TopoInterfaces/ConfigurableAlg.h b/Trigger/TrigT1/L1Topo/L1TopoInterfaces/L1TopoInterfaces/ConfigurableAlg.h index c1eb14d9eb561e3958cbb599cb157e7974326923..eb659dab21a39d9530636ebaa9295a9c7b255b1b 100644 --- a/Trigger/TrigT1/L1Topo/L1TopoInterfaces/L1TopoInterfaces/ConfigurableAlg.h +++ b/Trigger/TrigT1/L1Topo/L1TopoInterfaces/L1TopoInterfaces/ConfigurableAlg.h @@ -15,6 +15,7 @@ #include "L1TopoInterfaces/AlgFactory.h" #include "L1TopoCommon/StatusCode.h" #include "L1TopoEvent/GenericTOB.h" +#include "TrigConfData/L1Threshold.h" #include <vector> #include <string> @@ -43,10 +44,6 @@ namespace TCS { void setLegacyMode(bool isLegacyTopo) {m_isLegacyTopo=isLegacyTopo;} - // l1menu isolation info - void setIsolationFW_CTAU( const std::map<std::string, int>& isolationFW_CTAU, const std::map<std::string, int>& isolationFW_CTAU_jTAUCoreScale ) { m_isolationFW_CTAU = isolationFW_CTAU; m_isolationFW_CTAU_jTAUCoreScale = isolationFW_CTAU_jTAUCoreScale; } - void setIsolationFW_JTAU( const std::map<std::string, int>& isolationFW_JTAU ) { m_isolationFW_JTAU = isolationFW_JTAU; } - // accessors const std::string & name() const { return m_name; } const std::string & className() const { return m_className; } @@ -68,11 +65,6 @@ namespace TCS { bool isLegacyTopo() const { return m_isLegacyTopo; } - // l1menu isolation info - const std::map<std::string, int>& isolationFW_CTAU() const { return m_isolationFW_CTAU; } - const std::map<std::string, int>& isolationFW_CTAU_jTAUCoreScale() const { return m_isolationFW_CTAU_jTAUCoreScale; } - const std::map<std::string, int>& isolationFW_JTAU() const { return m_isolationFW_JTAU; } - // Kinematic calculation unsigned int calcDeltaPhiBW(const TCS::GenericTOB* tob1, const TCS::GenericTOB* tob2); unsigned int calcDeltaEtaBW(const TCS::GenericTOB* tob1, const TCS::GenericTOB* tob2); @@ -128,9 +120,9 @@ namespace TCS { void fillHist2D(const std::string & histName, double x, double y); - bool isocut(const std::string& threshold, const unsigned int bit); + bool isocut(const std::string& threshold, const unsigned int bit) const; - bool isocut(const unsigned int threshold, const unsigned int bit); + bool isocut(const unsigned int threshold, const unsigned int bit) const; private: class ConfigurableAlgImpl; @@ -150,11 +142,6 @@ namespace TCS { AlgType m_algType; // stores type of alg (Sorting or Decision) bool m_isLegacyTopo; - - std::map<std::string, int> m_isolationFW_CTAU; // FW isolation WPs for cTau - std::map<std::string, int> m_isolationFW_CTAU_jTAUCoreScale; // FW isolation WPs for cTau (jTAUCore factor) - std::map<std::string, int> m_isolationFW_JTAU; // FW isolation WPs for jTau - }; std::ostream & operator<<(std::ostream &, const TCS::ConfigurableAlg &); diff --git a/Trigger/TrigT1/L1Topo/L1TopoInterfaces/Root/ConfigurableAlg.cxx b/Trigger/TrigT1/L1Topo/L1TopoInterfaces/Root/ConfigurableAlg.cxx index 7eeffb833c99acae0e722ca3809d84a4b913ace3..1952cbb1819e2a90fd7578650e49dda032aac0e8 100644 --- a/Trigger/TrigT1/L1Topo/L1TopoInterfaces/Root/ConfigurableAlg.cxx +++ b/Trigger/TrigT1/L1Topo/L1TopoInterfaces/Root/ConfigurableAlg.cxx @@ -481,7 +481,7 @@ std::string ConfigurableAlg::ToString(const int val) } bool -ConfigurableAlg::isocut(const std::string& threshold, const unsigned int bit) { +ConfigurableAlg::isocut(const std::string& threshold, const unsigned int bit) const { unsigned int value = 0; if (threshold == "None") {value = 0;} else if (threshold == "Loose") {value = 1;} @@ -497,7 +497,7 @@ ConfigurableAlg::isocut(const std::string& threshold, const unsigned int bit) { } bool -ConfigurableAlg::isocut(const unsigned int threshold, const unsigned int bit) { +ConfigurableAlg::isocut(const unsigned int threshold, const unsigned int bit) const { if (bit >= threshold) {return true;} else {return false;} } diff --git a/Trigger/TriggerCommon/TriggerMenuMT/python/L1/Config/TypeWideThresholdConfig.py b/Trigger/TriggerCommon/TriggerMenuMT/python/L1/Config/TypeWideThresholdConfig.py index adf99785d27ee4c2191d16411a26a7fd94f94d51..5547a05add88966a59ccf37ffcc26d5cb63da729 100644 --- a/Trigger/TriggerCommon/TriggerMenuMT/python/L1/Config/TypeWideThresholdConfig.py +++ b/Trigger/TriggerCommon/TriggerMenuMT/python/L1/Config/TypeWideThresholdConfig.py @@ -2,6 +2,7 @@ from collections import OrderedDict as odict from dataclasses import dataclass +from enum import Enum from AthenaCommon.Logging import logging log = logging.getLogger(__name__) @@ -81,6 +82,10 @@ def eFEXfwToFloatConversion_wstot(fw,bitshift): decimal = pow(2,bitshift)/fw return float("{:.3f}".format(decimal)) +def eTAUfwToFloatConversion_bdt(fw): + decimal = fw/4096 + return float("{:.2f}".format(decimal)) + def eFEXfwToFloatConversion_minIsoEt(fw): decimal = fw * 100.0 # To MeV units return float("{:.3f}".format(decimal)) @@ -107,7 +112,7 @@ def getTypeWideThresholdConfig(ttype, do_HI_tob_thresholds=False, do_eFex_BDT_Ta if ttype == ThrType.eTAU: return getConfig_eTAU(do_eFex_BDT_Tau) if ttype == ThrType.cTAU: - return getConfig_cTAU() + return getConfig_cTAU(do_eFex_BDT_Tau) if ttype == ThrType.jTAU: return getConfig_jTAU() if ttype == ThrType.jJ: @@ -384,17 +389,17 @@ class L1Config_eTAU: confObj = odict() confObj["workingPoints"] = odict() confObj["workingPoints"]["Loose"] = [ - odict([("rCore", eFEXfwToFloatConversion(rCore_fw_loose, self.bitshift_rCore)), ("rCore_fw", rCore_fw_loose), + odict([("rCore", eTAUfwToFloatConversion_bdt(rCore_fw_loose) if do_eFex_BDT_Tau else eFEXfwToFloatConversion(rCore_fw_loose, self.bitshift_rCore)), ("rCore_fw", rCore_fw_loose), ("rHad", eFEXfwToFloatConversion(self.rHad_fw_loose, self.bitshift_rHad)), ("rHad_fw", self.rHad_fw_loose), ]), ] confObj["workingPoints"]["Medium"] = [ - odict([("rCore", eFEXfwToFloatConversion(rCore_fw_medium, self.bitshift_rCore)), ("rCore_fw", rCore_fw_medium), + odict([("rCore", eTAUfwToFloatConversion_bdt(rCore_fw_medium) if do_eFex_BDT_Tau else eFEXfwToFloatConversion(rCore_fw_medium, self.bitshift_rCore)), ("rCore_fw", rCore_fw_medium), ("rHad", eFEXfwToFloatConversion(self.rHad_fw_medium, self.bitshift_rHad)), ("rHad_fw", self.rHad_fw_medium), ]), ] confObj["workingPoints"]["Tight"] = [ - odict([("rCore", eFEXfwToFloatConversion(rCore_fw_tight, self.bitshift_rCore)), ("rCore_fw", rCore_fw_tight), + odict([("rCore", eTAUfwToFloatConversion_bdt(rCore_fw_tight) if do_eFex_BDT_Tau else eFEXfwToFloatConversion(rCore_fw_tight, self.bitshift_rCore)), ("rCore_fw", rCore_fw_tight), ("rHad", eFEXfwToFloatConversion(self.rHad_fw_tight, self.bitshift_rHad)), ("rHad_fw", self.rHad_fw_tight), ]), ] @@ -423,7 +428,6 @@ class L1Config_eTAU: getConfig_eTAU = L1Config_eTAU() - @dataclass class L1Config_cTAU: # cTAU isolation parameters (ATR-28621): @@ -431,32 +435,64 @@ class L1Config_cTAU: # jTAUCoreScale: 11 bits (0 - 2047) # (jTAU.EtIso + isolation_jTAUCoreScale_fw/1024 * jTAU.Et) / eTAU.Et < isolation_fw/1024 -> pass + # eTAU rCore/BDT WP: 2 bits (0 - 3) + # We can only specify the WP of the rCore/BDT selection, as defined in L1Config_eTAU above + + # eTAU rHad WP: 2 bits (0 - 3) + # We can only specify the WP of the rHad selection, as defined in L1Config_eTAU above + + class eTAUWP(Enum): + NoSelection = 0 + Loose = 1 + Medium = 2 + Tight = 3 + # Same values as in the TrigConf::Selection::WP enum + + def rCoreMinCut(self, do_eFex_BDT_Tau=True) -> float: + return 0.0 if self is self.NoSelection else getConfig_eTAU(do_eFex_BDT_Tau)['workingPoints'][self.name][0]['rCore'] + def rHadMinCut(self, do_eFex_BDT_Tau=True) -> float: + return 0.0 if self is self.NoSelection else getConfig_eTAU(do_eFex_BDT_Tau)['workingPoints'][self.name][0]['rHad'] + # Generic L, M and T WPs, for the cTAUSpare1/2 isolation_fw_loose: int = 410 isolation_jTAUCoreScale_fw_loose: int = 0 + eTAU_rCoreMin_WP_fw_loose: eTAUWP = eTAUWP.NoSelection + eTAU_rHadMin_WP_fw_loose: eTAUWP = eTAUWP.NoSelection isolation_fw_medium: int = 410 isolation_jTAUCoreScale_fw_medium: int = 0 + eTAU_rCoreMin_WP_fw_medium: eTAUWP = eTAUWP.NoSelection + eTAU_rHadMin_WP_fw_medium: eTAUWP = eTAUWP.NoSelection isolation_fw_tight: int = 307 isolation_jTAUCoreScale_fw_tight: int = 0 + eTAU_rCoreMin_WP_fw_tight: eTAUWP = eTAUWP.NoSelection + eTAU_rHadMin_WP_fw_tight: eTAUWP = eTAUWP.NoSelection # Dedicated M thresholds for the primary items: #cTAU12M (Medium12) isolation_fw_medium12: int = 358 isolation_jTAUCoreScale_fw_medium12: int = 0 + eTAU_rCoreMin_WP_fw_medium12: eTAUWP = eTAUWP.NoSelection + eTAU_rHadMin_WP_fw_medium12: eTAUWP = eTAUWP.NoSelection #cTAU20M (Medium20) isolation_fw_medium20: int = 358 isolation_jTAUCoreScale_fw_medium20: int = 0 + eTAU_rCoreMin_WP_fw_medium20: eTAUWP = eTAUWP.NoSelection + eTAU_rHadMin_WP_fw_medium20: eTAUWP = eTAUWP.NoSelection #cTAU30M (Medium30) isolation_fw_medium30: int = 358 isolation_jTAUCoreScale_fw_medium30: int = 0 + eTAU_rCoreMin_WP_fw_medium30: eTAUWP = eTAUWP.NoSelection + eTAU_rHadMin_WP_fw_medium30: eTAUWP = eTAUWP.NoSelection #cTAU35M (Medium35) isolation_fw_medium35: int = 358 isolation_jTAUCoreScale_fw_medium35: int = 0 + eTAU_rCoreMin_WP_fw_medium35: eTAUWP = eTAUWP.NoSelection + eTAU_rHadMin_WP_fw_medium35: eTAUWP = eTAUWP.NoSelection def __post_init__(self): # By default, duplicate the configs of isolation_fw_loose and isolation_fw_tight: @@ -464,15 +500,19 @@ class L1Config_cTAU: for wp in wp_list: setattr(self, f'isolation_fw_{wp.lower()}', getattr(self, f'isolation_fw_{default_wp.lower()}')) setattr(self, f'isolation_jTAUCoreScale_fw_{wp.lower()}', getattr(self, f'isolation_jTAUCoreScale_fw_{default_wp.lower()}')) + setattr(self, f'eTAU_rCoreMin_WP_fw_{wp.lower()}', getattr(self, f'eTAU_rCoreMin_WP_fw_{default_wp.lower()}')) + setattr(self, f'eTAU_rHadMin_WP_fw_{wp.lower()}', getattr(self, f'eTAU_rHadMin_WP_fw_{default_wp.lower()}')) - def __call__(self) -> odict: + def __call__(self, do_eFex_BDT_Tau=True) -> odict: confObj = odict() confObj['workingPoints'] = odict() for wp in ['Loose', 'Medium', 'Tight', 'Loose12', 'Loose20', 'Loose30', 'Loose35', 'Medium12', 'Medium20', 'Medium30', 'Medium35', 'Tight12', 'Tight20', 'Tight30', 'Tight35']: confObj['workingPoints'][wp] = [ odict([('isolation', cTAUfwToFlowConversion(getattr(self, f'isolation_fw_{wp.lower()}'))), ('isolation_fw', getattr(self, f'isolation_fw_{wp.lower()}')), - ('isolation_jTAUCoreScale', cTAUfwToFlowConversion(getattr(self, f'isolation_jTAUCoreScale_fw_{wp.lower()}'))), ('isolation_jTAUCoreScale_fw', getattr(self, f'isolation_jTAUCoreScale_fw_{wp.lower()}'))]), + ('isolation_jTAUCoreScale', cTAUfwToFlowConversion(getattr(self, f'isolation_jTAUCoreScale_fw_{wp.lower()}'))), ('isolation_jTAUCoreScale_fw', getattr(self, f'isolation_jTAUCoreScale_fw_{wp.lower()}')), + ('eTAU_rCoreMin', getattr(self, f'eTAU_rCoreMin_WP_fw_{wp.lower()}').rCoreMinCut(do_eFex_BDT_Tau)), ('eTAU_rCoreMin_WP_fw', getattr(self, f'eTAU_rCoreMin_WP_fw_{wp.lower()}').value), + ('eTAU_rHadMin', getattr(self, f'eTAU_rHadMin_WP_fw_{wp.lower()}').rHadMinCut(do_eFex_BDT_Tau)), ('eTAU_rHadMin_WP_fw', getattr(self, f'eTAU_rHadMin_WP_fw_{wp.lower()}').value)]), ] confObj['resolutionMeV'] = 100