11 from AthenaConfiguration.ComponentAccumulator
import ComponentAccumulator
12 from AthenaConfiguration.ComponentFactory
import CompFactory
13 from AthenaConfiguration.AccumulatorCache
import AccumulatorCache
14 from AthenaConfiguration.Enums
import ProductionStep
23 _name = flags.Tau.ActiveConfig.prefix +
'JetSeedBuilder'
25 JetSeedBuilder = CompFactory.getComp(
"JetSeedBuilder")
28 result.setPrivateTools(JetSeedBuilder)
34 _name = flags.Tau.ActiveConfig.prefix +
'TauVertexFinder'
36 from InDetConfig.InDetTrackSelectionToolConfig
import Tau_InDetTrackSelectionToolForTJVACfg
37 from TrackVertexAssociationTool.TrackVertexAssociationToolConfig
import TauTTVAToolCfg
41 TauVertexFinder = CompFactory.getComp(
"TauVertexFinder")
43 UseTJVA = flags.Tau.doTJVA,
44 AssociatedTracks=
"GhostTrack",
46 Key_trackPartInputContainer= flags.Tau.ActiveConfig.TrackCollection,
47 Key_vertexInputContainer = flags.Tau.ActiveConfig.VertexCollection,
49 inEleRM = flags.Tau.ActiveConfig.inTauEleRM,
52 result.setPrivateTools(TauVertexFinder)
59 _name = flags.Tau.ActiveConfig.prefix +
'TauAxis'
61 TauAxisSetter = CompFactory.getComp(
"TauAxisSetter")
64 VertexCorrection = flags.Tau.doVertexCorrection )
66 result.setPrivateTools(TauAxisSetter)
73 if flags.Common.ProductionStep
is ProductionStep.Reconstruction:
74 ParticleCache =
"ParticleCaloExtension"
84 _name = flags.Tau.ActiveConfig.prefix +
'TauTrackFinder'
87 from BeamSpotConditions.BeamSpotConditionsConfig
import BeamSpotCondAlgCfg
90 from TrackToVertex.TrackToVertexConfig
import TrackToVertexCfg
91 from TrackToCalo.TrackToCaloConfig
import ParticleCaloExtensionToolCfg
92 from TrkConfig.TrkVertexFitterUtilsConfig
import AtlasTrackToVertexIPEstimatorCfg
93 from InDetConfig.InDetTrackSelectorToolConfig
import TauRecInDetTrackSelectorToolCfg
95 TauTrackFinder = CompFactory.getComp(
"TauTrackFinder")
103 removeDuplicateCoreTracks = flags.Tau.RemoveDupeCoreTracks,
104 useGhostTracks = flags.Tau.useGhostTracks,
105 ghostTrackDR = flags.Tau.ghostTrackDR,
106 Key_jetContainer = (flags.Tau.ActiveConfig.SeedJetCollection
if flags.Tau.useGhostTracks
else ""),
107 Key_trackPartInputContainer = flags.Tau.ActiveConfig.TrackCollection,
108 Key_LargeD0TrackInputContainer = (flags.Tau.ActiveConfig.LargeD0TrackCollection
if flags.Tau.associateLRT
else ""),
110 inEleRM = flags.Tau.ActiveConfig.inTauEleRM,
112 result.setPrivateTools(TauTrackFinder)
119 _name = flags.Tau.ActiveConfig.prefix +
'TauClusterFinder'
122 TauClusterFinder = CompFactory.getComp(
"TauClusterFinder")
125 inEleRM = flags.Tau.ActiveConfig.inTauEleRM,
129 result.setPrivateTools(TauClusterFinder)
135 _name = flags.Tau.ActiveConfig.prefix +
'TauVertexedClusterDecorator'
137 TauVertexedClusterDecorator = CompFactory.getComp(
"TauVertexedClusterDecorator")
139 SeedJet = flags.Tau.ActiveConfig.SeedJetCollection)
141 result.setPrivateTools(myTauVertexedClusterDecorator)
147 _name = flags.Tau.ActiveConfig.prefix +
'TauTrackRNNClassifier'
149 TrackRNN = CompFactory.tauRecTools.TrackRNN
150 _RNN = TrackRNN(name = _name +
"_TrackRNN",
151 InputWeightsPath = flags.Tau.tauRNNTrackClassConfig,
152 calibFolder = flags.Tau.tauRecToolsCVMFSPath )
154 result.setPrivateTools(_RNN)
160 _name = flags.Tau.ActiveConfig.prefix +
'TauTrackRNNClassifier'
163 TauTrackRNNClassifier = CompFactory.tauRecTools.TauTrackRNNClassifier
166 cppyy.load_library(
'libxAODTau_cDict')
169 if flags.Tau.associateLRT
and not flags.Tau.classifyLRT:
172 myTauTrackClassifier = TauTrackRNNClassifier( name = _name,
174 classifyLRT = _classifyLRT )
176 result.setPrivateTools(myTauTrackClassifier)
183 _name = flags.Tau.ActiveConfig.prefix +
'EnergyCalibrationLC'
185 TauCalibrateLC = CompFactory.getComp(
"TauCalibrateLC")
187 calibrationFile = flags.Tau.CalibrateLCConfig,
188 Key_vertexInputContainer = flags.Tau.ActiveConfig.VertexCollection)
190 result.setPrivateTools(TauCalibrateLC)
197 _name = flags.Tau.ActiveConfig.prefix +
'CellVariables'
199 TauCellVariables = CompFactory.getComp(
"TauCellVariables")
201 VertexCorrection = flags.Tau.doVertexCorrection)
203 result.setPrivateTools(TauCellVariables)
210 _name = flags.Tau.ActiveConfig.prefix +
'TauElectronVetoVars'
212 from TrackToCalo.TrackToCaloConfig
import ParticleCaloExtensionToolCfg
214 TauElectronVetoVariables = CompFactory.getComp(
"TauElectronVetoVariables")
216 VertexCorrection = flags.Tau.doVertexCorrection,
220 result.setPrivateTools(TauElectronVetoVariables)
229 H1WeightToolCSC12Generic = CompFactory.H1WeightToolCSC12Generic
230 isMC = flags.Input.isMC
235 onlyCellWeight =
False
236 from CaloClusterCorrection.StandardCellWeightCalib
import H1Calibration, editParm
237 (key,folder,tag) = H1Calibration.getCalibDBParams(flags, finder, mainparam, inputn, onlyCellWeight, isMC)
239 from IOVDbSvc.IOVDbSvcConfig
import addFolders
244 if (folder,tag)
not in H1Calibration.loaded_folder:
245 if H1Calibration.overrideFolder():
246 result.merge(
addFolders(flags, folder+
'<tag>'+tag+
'</tag>', detDb=dbString, className=
'CaloRec::ToolConstants') )
248 result.merge(
addFolders(flags, folder, detDb=dbString, className=
'CaloRec::ToolConstants') )
250 H1Calibration.loaded_folder.append( (folder,tag) )
253 toolName = finder +
editParm(mainparam) + inputn
255 cellcalibtool.DBHandleKey = key
256 result.setPrivateTools(cellcalibtool)
264 _name = flags.Tau.ActiveConfig.prefix +
'TauShotFinder'
266 shotPtCut_1Photon = flags.Tau.shotPtCut_1Photon
267 shotPtCut_2Photons = flags.Tau.shotPtCut_2Photons
270 from CaloClusterCorrection.StandardCellWeightCalib
import getCellWeightTool
274 TauShotFinder = CompFactory.getComp(
"TauShotFinder")
277 CaloWeightTool = result.popToolsAndMerge(CaloWeightTool),
279 MinPtCut = shotPtCut_1Photon,
280 AutoDoubleShotCut = shotPtCut_2Photons,
281 Key_RemovedClusterInputContainer = flags.Tau.ActiveConfig.RemovedElectronClusters,
282 RemoveElectronCells = flags.Tau.ActiveConfig.RemoveElectronCells,
283 inEleRM = flags.Tau.ActiveConfig.inTauEleRM,
286 result.setPrivateTools(TauShotFinder)
294 _name = flags.Tau.ActiveConfig.prefix +
'Pi0ClusterFinder'
296 TauPi0CreateROI = CompFactory.getComp(
"TauPi0CreateROI")
300 Key_caloCellInputContainer =
"AllCalo",
301 Key_RemovedClusterInputContainer = flags.Tau.ActiveConfig.RemovedElectronClusters,
302 inEleRM = flags.Tau.ActiveConfig.inTauEleRM,
303 RemoveElectronCells = flags.Tau.ActiveConfig.RemoveElectronCells,
306 result.setPrivateTools(myTauPi0CreateROI)
313 _name = flags.Tau.ActiveConfig.prefix +
'tauPi0CellContainerFinalizer'
315 CaloCellContainerFinalizerTool = CompFactory.getComp(
"CaloCellContainerFinalizerTool")
318 result.setPrivateTools(TauCellContainerFinalizer)
327 _name = flags.Tau.ActiveConfig.prefix +
'LCClassify'
329 CaloLCClassificationTool = CompFactory.getComp(
"CaloLCClassificationTool")
331 LCClassify.ClassificationKey =
"EMFracClassify"
332 LCClassify.UseSpread =
False
333 LCClassify.MaxProbability = 0.5
335 LCClassify.StoreClassificationProbabilityInAOD =
True
336 LCClassify.WeightingOfNegClusters = flags.Calo.TopoCluster.doTreatEnergyCutAsAbsolute
337 LCClassify.UseNormalizedEnergyDensity =
True
339 result.setPrivateTools(LCClassify)
344 _name = flags.Tau.ActiveConfig.prefix +
'CaloLCWeightTool'
347 from CaloTools.CaloNoiseCondAlgConfig
import CaloNoiseCondAlgCfg
352 CaloLCWeightTool = CompFactory.getComp(
"CaloLCWeightTool")
354 LCWeight.CorrectionKey =
"H1ClusterCellWeights"
355 LCWeight.SignalOverNoiseCut = 2.0
356 LCWeight.UseHadProbability =
True
358 result.setPrivateTools(LCWeight)
363 _name = flags.Tau.ActiveConfig.prefix +
'CaloLCOutOfClusterTool'
365 CaloLCOutOfClusterTool = CompFactory.getComp(
"CaloLCOutOfClusterTool")
367 LCOut.CorrectionKey =
"OOCCorrection"
368 LCOut.UseEmProbability =
False
369 LCOut.UseHadProbability =
True
371 result.setPrivateTools(LCOut)
376 _name = flags.Tau.ActiveConfig.prefix +
'LCOutPi0'
378 CaloLCOutOfClusterTool = CompFactory.getComp(
"CaloLCOutOfClusterTool")
380 LCOutPi0.CorrectionKey =
"OOCPi0Correction"
381 LCOutPi0.UseEmProbability =
True
382 LCOutPi0.UseHadProbability =
False
384 result.setPrivateTools(LCOutPi0)
389 _name = flags.Tau.ActiveConfig.prefix +
'CaloLCDeadMaterialTool'
391 CaloLCDeadMaterialTool = CompFactory.getComp(
"CaloLCDeadMaterialTool")
393 LCDeadMaterial.HadDMCoeffKey =
"HadDMCoeff2"
394 LCDeadMaterial.ClusterRecoStatus = 0
395 LCDeadMaterial.WeightModeDM = 2
396 LCDeadMaterial.UseHadProbability =
True
397 LCDeadMaterial.WeightingOfNegClusters = flags.Calo.TopoCluster.doTreatEnergyCutAsAbsolute
399 result.setPrivateTools(LCDeadMaterial)
404 _name = flags.Tau.ActiveConfig.prefix +
'CaloLocalCalib'
406 CaloClusterLocalCalib = CompFactory.getComp(
"CaloClusterLocalCalib")
409 LocalCalib.ClusterRecoStatus = [1,2]
411 LocalCalib.WeightingOfNegClusters = flags.Calo.TopoCluster.doTreatEnergyCutAsAbsolute
413 result.setPrivateTools(LocalCalib)
418 _name = flags.Tau.ActiveConfig.prefix +
'OOCCalibTool'
420 CaloClusterLocalCalib = CompFactory.getComp(
"CaloClusterLocalCalib")
421 OOCCalib = CaloClusterLocalCalib (_name)
422 OOCCalib.ClusterRecoStatus = [1,2]
424 OOCCalib.WeightingOfNegClusters = flags.Calo.TopoCluster.doTreatEnergyCutAsAbsolute
426 result.setPrivateTools(OOCCalib)
431 _name = flags.Tau.ActiveConfig.prefix +
'DMCalib'
433 CaloClusterLocalCalib = CompFactory.getComp(
"CaloClusterLocalCalib")
435 DMCalib.ClusterRecoStatus = [1,2]
437 DMCalib.WeightingOfNegClusters = flags.Calo.TopoCluster.doTreatEnergyCutAsAbsolute
439 result.setPrivateTools(DMCalib)
444 _name = flags.Tau.ActiveConfig.prefix +
'OOCPi0CalibTool'
446 CaloClusterLocalCalib = CompFactory.getComp(
"CaloClusterLocalCalib")
447 OOCPi0Calib = CaloClusterLocalCalib (_name)
448 OOCPi0Calib.ClusterRecoStatus = [1,2]
450 OOCPi0Calib.WeightingOfNegClusters = flags.Calo.TopoCluster.doTreatEnergyCutAsAbsolute
452 result.setPrivateTools(OOCPi0Calib)
457 _name = flags.Tau.ActiveConfig.prefix +
'CellWeights'
459 CaloClusterCellWeightCalib = CompFactory.getComp(
"CaloClusterCellWeightCalib")
461 CellWeights.CellSignalWeightTool = result.popToolsAndMerge(
CellWeightToolCfg(flags))
462 CellWeights.Direction =
"AbsSignal"
463 CellWeights.BelowThresholdLikeAll =
True
464 CellWeights.BelowThresholdDirection =
"AbsSignal"
465 CellWeights.EnergyThreshold = 0.0*MeV
466 CellWeights.IgnoreGeoWeights =
False
468 result.setPrivateTools(CellWeights)
473 _name = flags.Tau.ActiveConfig.prefix +
'Pi0TopoClusterMaker'
476 from CaloTools.CaloNoiseCondAlgConfig
import CaloNoiseCondAlgCfg
481 CaloTopoClusterMaker = CompFactory.getComp(
"CaloTopoClusterMaker")
484 TopoClusterForTaus.CellsName = flags.Tau.ActiveConfig.TauCommonPi0Cells
485 TopoClusterForTaus.CalorimeterNames=[
"LAREM"]
486 TopoClusterForTaus.SeedSamplingNames = [
"PreSamplerB",
"EMB1",
"EMB2",
"PreSamplerE",
"EME1",
"EME2"]
487 TopoClusterForTaus.NeighborOption =
"super3D"
488 TopoClusterForTaus.RestrictHECIWandFCalNeighbors =
False
489 TopoClusterForTaus.RestrictPSNeighbors =
True
490 TopoClusterForTaus.CellThresholdOnEorAbsEinSigma = 0.0
491 TopoClusterForTaus.NeighborThresholdOnEorAbsEinSigma = 2.0
492 TopoClusterForTaus.SeedThresholdOnEorAbsEinSigma = 4.0
493 TopoClusterForTaus.SeedCutsInAbsE =
True
494 TopoClusterForTaus.ClusterCutsInAbsEt =
True
495 TopoClusterForTaus.ClusterEtorAbsEtCut = 0.5*GeV
496 TopoClusterForTaus.TwoGaussianNoise = flags.Calo.TopoCluster.doTwoGaussianNoise
498 TopoClusterForTaus.SeedCutsInT = flags.Calo.TopoCluster.doTimeCut
499 TopoClusterForTaus.CutOOTseed = flags.Calo.TopoCluster.extendTimeCut
and flags.Calo.TopoCluster.doTimeCut
500 TopoClusterForTaus.UseTimeCutUpperLimit = flags.Calo.TopoCluster.useUpperLimitForTimeCut
501 TopoClusterForTaus.TimeCutUpperLimit = flags.Calo.TopoCluster.timeCutUpperLimit
502 TopoClusterForTaus.XTalkEM2 = flags.Calo.TopoCluster.xtalkEM2
503 TopoClusterForTaus.XTalkEM2D = flags.Calo.TopoCluster.xtalkEM2D
504 TopoClusterForTaus.XTalkEM2n = flags.Calo.TopoCluster.xtalkEM2n
505 TopoClusterForTaus.XTalkEM3 = flags.Calo.TopoCluster.xtalkEM3
506 TopoClusterForTaus.XTalkEMEta = flags.Calo.TopoCluster.xtalkEMEta
507 TopoClusterForTaus.XTalkDeltaT = flags.Calo.TopoCluster.xtalkDeltaT
508 TopoClusterForTaus.XTalk2Eratio1 = flags.Calo.TopoCluster.xtalk2Eratio1
509 TopoClusterForTaus.XTalk2Eratio2 = flags.Calo.TopoCluster.xtalk2Eratio2
510 TopoClusterForTaus.XTalk3Eratio = flags.Calo.TopoCluster.xtalk3Eratio
511 TopoClusterForTaus.XTalkEtaEratio = flags.Calo.TopoCluster.xtalkEtaEratio
512 TopoClusterForTaus.XTalk2DEratio = flags.Calo.TopoCluster.xtalk2DEratio
514 result.setPrivateTools(TopoClusterForTaus)
520 _name = flags.Tau.ActiveConfig.prefix +
'Pi0TopoClusterSplitter'
522 CaloTopoClusterSplitter = CompFactory.getComp(
"CaloTopoClusterSplitter")
529 TopoSplitterForTaus.SamplingNames = [
"EMB2",
"EME2"]
533 TopoSplitterForTaus.SecondarySamplingNames = [
"EMB1",
"EME1"]
534 TopoSplitterForTaus.ShareBorderCells =
True
535 TopoSplitterForTaus.RestrictHECIWandFCalNeighbors =
False
536 TopoSplitterForTaus.WeightingOfNegClusters = flags.Calo.TopoCluster.doTreatEnergyCutAsAbsolute
538 result.setPrivateTools(TopoSplitterForTaus)
543 _name = flags.Tau.ActiveConfig.prefix +
'Pi0TopoMoments'
546 from CaloTools.CaloNoiseCondAlgConfig
import CaloNoiseCondAlgCfg
551 CaloClusterMomentsMaker = CompFactory.getComp(
"CaloClusterMomentsMaker")
553 TopoMomentsForTaus.WeightingOfNegClusters = flags.Calo.TopoCluster.doTreatEnergyCutAsAbsolute
554 TopoMomentsForTaus.MaxAxisAngle = 20*deg
555 TopoMomentsForTaus.TwoGaussianNoise = flags.Calo.TopoCluster.doTwoGaussianNoise
556 TopoMomentsForTaus.MinBadLArQuality = 4000
557 TopoMomentsForTaus.MomentsNames = [
"FIRST_PHI"
578 result.setPrivateTools(TopoMomentsForTaus)
583 _name = flags.Tau.ActiveConfig.prefix +
'CaloClusterBadChannelList'
585 CaloClusterBadChannelListCorr = CompFactory.getComp(
"CaloClusterBadChannelList")
588 result.setPrivateTools(BadChannelListCorrForTaus)
595 _name = flags.Tau.ActiveConfig.prefix +
'Pi0ClusterCreator'
597 TauPi0ClusterCreator = CompFactory.getComp(
"TauPi0ClusterCreator")
600 result.setPrivateTools(TauPi0ClusterCreator)
607 _name = flags.Tau.ActiveConfig.prefix +
'Pi0ClusterScaler'
609 TauPi0ClusterScaler = CompFactory.getComp(
"TauPi0ClusterScaler")
612 result.setPrivateTools(TauPi0ClusterScaler)
619 _name = flags.Tau.ActiveConfig.prefix +
'Pi0ScoreCalculator'
621 TauPi0ScoreCalculator = CompFactory.getComp(
"TauPi0ScoreCalculator")
623 BDTWeightFile = flags.Tau.Pi0ScoreConfig)
625 result.setPrivateTools(TauPi0ScoreCalculator)
632 _name = flags.Tau.ActiveConfig.prefix +
'Pi0Selector'
634 TauPi0Selector = CompFactory.getComp(
"TauPi0Selector")
636 ClusterEtCut = flags.Tau.pi0EtCuts,
637 ClusterBDTCut_1prong = flags.Tau.pi0MVACuts_1prong,
638 ClusterBDTCut_mprong = flags.Tau.pi0MVACuts_mprong)
640 result.setPrivateTools(TauPi0Selector)
647 _name = flags.Tau.ActiveConfig.prefix +
'TauVertexVariables'
649 from TrkConfig.TrkVertexFittersConfig
import TauAdaptiveVertexFitterCfg
650 from TrkConfig.TrkVertexSeedFinderToolsConfig
import (
651 CrossDistancesSeedFinderCfg)
653 TauVertexVariables = CompFactory.getComp(
"TauVertexVariables")
658 result.setPrivateTools(TauVertexVariables)
665 _name = flags.Tau.ActiveConfig.prefix +
'TauCommonCalcVars'
667 TauCommonCalcVars = CompFactory.getComp(
"TauCommonCalcVars")
670 result.setPrivateTools(TauCommonCalcVars)
677 _name = flags.Tau.ActiveConfig.prefix +
'TauSubstructure'
679 TauSubstructureVariables = CompFactory.getComp(
"TauSubstructureVariables")
682 result.setPrivateTools(TauSubstructureVariables)
689 _name = flags.Tau.ActiveConfig.prefix +
'MvaTESVariableDecorator'
691 MvaTESVariableDecorator = CompFactory.getComp(
"MvaTESVariableDecorator")
693 Key_vertexInputContainer = flags.Tau.ActiveConfig.VertexCollection,
694 EventShapeKey = flags.Tau.ActiveConfig.EventShapeCollection,
695 VertexCorrection = flags.Tau.doVertexCorrection)
696 result.setPrivateTools(MvaTESVariableDecorator)
703 _name = flags.Tau.ActiveConfig.prefix +
'MvaTESEvaluator'
705 MvaTESEvaluator = CompFactory.getComp(
"MvaTESEvaluator")
707 WeightFileName = flags.Tau.MvaTESConfig,
708 WeightFileName0p = flags.Tau.MvaTESConfig0p )
710 result.setPrivateTools(MvaTESEvaluator)
715 _name = flags.Tau.ActiveConfig.prefix +
'TauIDVarCalculator'
717 TauIDVarCalculator = CompFactory.getComp(
"TauIDVarCalculator")
719 VertexCorrection = flags.Tau.doVertexCorrection)
721 result.setPrivateTools(myTauIDVarCalculator)
726 _name = flags.Tau.ActiveConfig.prefix +
'TauJetRNN'
728 TauJetRNNEvaluator = CompFactory.getComp(
"TauJetRNNEvaluator")
729 RNNConf = flags.Tau.TauJetRNNConfig
732 NetworkFile1P = RNNConf[0],
733 NetworkFile2P = RNNConf[1],
734 NetworkFile3P = RNNConf[2],
735 OutputVarname =
"RNNJetScore",
739 VertexCorrection = flags.Tau.doVertexCorrection,
740 InputLayerScalar =
"scalar",
741 InputLayerTracks =
"tracks",
742 InputLayerClusters =
"clusters",
743 OutputLayer =
"rnnid_output",
744 OutputNode =
"sig_prob")
746 result.setPrivateTools(myTauJetRNNEvaluator)
750 import PyUtils.RootUtils
as ru
751 ROOT = ru.import_root()
753 cppyy.load_library(
'libxAODTau_cDict')
756 _name = flags.Tau.ActiveConfig.prefix +
'TauWPDecoratorJetRNN'
758 TauWPDecorator = CompFactory.getComp(
"TauWPDecorator")
759 WPConf = flags.Tau.TauJetRNNWPConfig
761 flatteningFile1Prong = WPConf[0],
762 flatteningFile2Prong = WPConf[1],
763 flatteningFile3Prong = WPConf[2],
765 [ ROOT.xAOD.TauJetParameters.IsTauFlag.JetRNNSigVeryLoose,
766 ROOT.xAOD.TauJetParameters.IsTauFlag.JetRNNSigLoose,
767 ROOT.xAOD.TauJetParameters.IsTauFlag.JetRNNSigMedium,
768 ROOT.xAOD.TauJetParameters.IsTauFlag.JetRNNSigTight ],
769 SigEff1P = [0.95, 0.85, 0.75, 0.60],
770 SigEff2P = [0.95, 0.75, 0.60, 0.45],
771 SigEff3P = [0.95, 0.75, 0.60, 0.45],
772 ScoreName =
"RNNJetScore",
773 NewScoreName =
"RNNJetScoreSigTrans",
776 result.setPrivateTools(myTauWPDecorator)
781 _name = flags.Tau.ActiveConfig.prefix +
'TauGNN_v' +
str(version)
783 TauGNNEvaluator = CompFactory.getComp(
"TauGNNEvaluator")
784 GNNConf = flags.Tau.TauGNNConfig[version]
786 NetworkFileInclusive = GNNConf,
787 OutputVarname = flags.Tau.GNTauScoreName[version],
788 OutputPTau =
"GNTauProbTau",
789 OutputPJet =
"GNTauProbJet",
790 MaxTracks = flags.Tau.GNTauMaxTracks[version],
791 MaxClusters = flags.Tau.GNTauMaxClusters[version],
793 MinTauPt = flags.Tau.MinPtDAOD,
794 VertexCorrection = flags.Tau.doVertexCorrection,
795 DecorateTracks =
False,
796 InputLayerScalar =
"tau_vars",
797 InputLayerTracks =
"track_vars",
798 InputLayerClusters =
"cluster_vars",
799 NodeNameTau=flags.Tau.GNTauNodeNameTau,
800 NodeNameJet=flags.Tau.GNTauNodeNameJet)
802 result.setPrivateTools(myTauGNNEvaluator)
807 _name = flags.Tau.ActiveConfig.prefix +
'TauWPDecoratorGNN_v' +
str(version)
809 TauWPDecorator = CompFactory.getComp(
"TauWPDecorator")
810 WPConf = flags.Tau.TauGNNWP[version]
812 flatteningFile1Prong = WPConf[0],
813 flatteningFile2Prong = WPConf[1],
814 flatteningFile3Prong = WPConf[2],
815 DecorWPNames = flags.Tau.GNTauDecorWPNames[version],
816 DecorWPCutEffs1P = [0.95, 0.85, 0.75, 0.60],
817 DecorWPCutEffs2P = [0.95, 0.75, 0.60, 0.45],
818 DecorWPCutEffs3P = [0.95, 0.75, 0.60, 0.45],
819 ScoreName = flags.Tau.GNTauScoreName[version],
820 NewScoreName = flags.Tau.GNTauTransScoreName[version],
822 result.setPrivateTools(myTauWPDecorator)
827 _name = flags.Tau.ActiveConfig.prefix +
'TauEleRNN'
829 TauJetRNNEvaluator = CompFactory.getComp(
"TauJetRNNEvaluator")
830 RNNConf = flags.Tau.TauEleRNNConfig
832 NetworkFile1P = RNNConf[0],
833 NetworkFile3P = RNNConf[1],
834 OutputVarname =
"RNNEleScore",
838 VertexCorrection = flags.Tau.doVertexCorrection,
839 InputLayerScalar =
"scalar",
840 InputLayerTracks =
"tracks",
841 InputLayerClusters =
"clusters",
842 OutputLayer =
"rnneveto_output",
843 OutputNode =
"sig_prob")
845 result.setPrivateTools(myTauEleRNNEvaluator)
849 import PyUtils.RootUtils
as ru
850 ROOT = ru.import_root()
852 cppyy.load_library(
'libxAODTau_cDict')
855 _name = flags.Tau.ActiveConfig.prefix +
'TauWPDecoratorEleRNN'
857 TauWPDecorator = CompFactory.getComp(
"TauWPDecorator")
858 WPConf = flags.Tau.TauEleRNNWPConfig
860 flatteningFile1Prong = WPConf[0],
861 flatteningFile3Prong = WPConf[1],
863 [ ROOT.xAOD.TauJetParameters.IsTauFlag.EleRNNLoose,
864 ROOT.xAOD.TauJetParameters.IsTauFlag.EleRNNMedium,
865 ROOT.xAOD.TauJetParameters.IsTauFlag.EleRNNTight ],
866 SigEff1P = [0.95, 0.90, 0.85],
867 SigEff3P = [0.98, 0.95, 0.90],
869 ScoreName =
"RNNEleScore",
870 NewScoreName =
"RNNEleScoreSigTrans",
873 result.setPrivateTools(myTauEleWPDecorator)
878 _name = flags.Tau.ActiveConfig.prefix +
'TauWPDecoratorEleRNNFix_v1'
880 TauWPDecorator = CompFactory.getComp(
"TauWPDecorator")
881 WPConf = flags.Tau.TauEleRNNWPfix
883 flatteningFile1Prong = WPConf[0],
884 flatteningFile3Prong = WPConf[1],
885 DecorWPNames = [
"EleRNNLoose_v1",
"EleRNNMedium_v1",
"EleRNNTight_v1" ],
886 DecorWPCutEffs1P = [0.95, 0.90, 0.85],
887 DecorWPCutEffs3P = [0.98, 0.95, 0.90],
889 ScoreName =
"RNNEleScore",
890 NewScoreName =
"RNNEleScoreSigTrans_v1",
893 result.setPrivateTools(myTauEleWPDecorator)
898 _name = flags.Tau.ActiveConfig.prefix +
'TauDecayModeNNClassifier'
900 TauDecayModeNNClassifier = CompFactory.getComp(
"TauDecayModeNNClassifier")
902 WeightFile=flags.Tau.DecayModeNNClassifierConfig)
904 result.setPrivateTools(myTauDecayModeNNClassifier)
909 _name = flags.Tau.ActiveConfig.prefix +
'TauAODSelector'
911 TauAODSelector = CompFactory.getComp(
"TauAODSelector")
913 Min0pTauPt = flags.Tau.MinPt0p,
914 MinTauPt = flags.Tau.MinPt,
915 doEarlyStopping = flags.Tau.doEarlyStopping
and not flags.Output.doWriteESD)
917 result.setPrivateTools(myTauAODSelector)
924 _name = flags.Tau.ActiveConfig.prefix +
'TauCombinedTES'
926 TauCombinedTES = CompFactory.getComp(
"TauCombinedTES")
928 WeightFileName = flags.Tau.CombinedTESConfig)
930 result.setPrivateTools(myTauCombinedTES)
937 _name = flags.Tau.ActiveConfig.prefix +
'MuonRemoval'
938 TauAODMuonRemovalTool = CompFactory.getComp(
"TauAODMuonRemovalTool")
940 Key_MuonInputContainer =
'Muons',
945 result.setPrivateTools(myMuonRemoval)
951 _name = flags.Tau.ActiveConfig.prefix +
'TauEleOverlapChecker'
952 TauEleOverlapChecker = CompFactory.getComp(
"TauEleOverlapChecker")
955 Key_RemovedClustersContainer = flags.Tau.ActiveConfig.RemovedElectronClusters,
956 Key_RemovedTracksContainer = flags.Tau.ActiveConfig.RemovedElectronTracks,
957 CheckingCone = flags.Tau.ActiveConfig.EleRM_CheckingConeSize,
959 result.setPrivateTools(myTauEleOverlapChecker)