ATLAS Offline Software
Loading...
Searching...
No Matches
python.StandardJetConstits Namespace Reference

Functions

 standardReco (input)
 _trackParticleInputsExist (flags)
 List of standard input sources for jets.
 _muonSegmentInputsExist (flags)
 _unassocMuonSegmentInputsExist (flags)
 _largeRTracksExist (flags)
 getCaloClusterEnergyMLCalibAlgBuilder ()
 getPFOClusterMLCorrectionAlgorithmBuilder ()
 _getWeightPFOToolDefault (*l)
 List of standard constituent modifiers.

Variables

 stdInputExtDic = ldict()
 stdConstitDic = ldict()
 stdContitModifDic = ldict()
list _stdInputList
list _truthFlavours
 _locked
list _stdSeqList
str vtxKey = "PrimaryVertices"
str tvaKey = "JetTrackVtxAssoc"
list _stdModList

Detailed Description

 StandardJetConstits: A module containing standard definitions for jet inputs : external container and 
 constituents.
 These can be copied and modified by users who want something a bit   
 different from what is provided.                                     
                                                                      
 Author: TJ Khoo, P-A Delsart                                                      

Function Documentation

◆ _getWeightPFOToolDefault()

_getWeightPFOToolDefault ( * l)
protected

List of standard constituent modifiers.

One Property of the CorrectPFO constit modifier is a tool. 
we use this function as a placeholder, allowing to delay the instantiation of this property tool
to the time the modifier itself is instantiated.

Definition at line 596 of file StandardJetConstits.py.

596def _getWeightPFOToolDefault(*l):
597 """One Property of the CorrectPFO constit modifier is a tool.
598 we use this function as a placeholder, allowing to delay the instantiation of this property tool
599 to the time the modifier itself is instantiated.
600 """
601 from AthenaConfiguration.ComponentFactory import CompFactory
602 return CompFactory.getComp("CP::WeightPFOTool")("weightPFO")
603
604

◆ _largeRTracksExist()

_largeRTracksExist ( flags)
protected

Definition at line 128 of file StandardJetConstits.py.

128def _largeRTracksExist(flags):
129 warning = "Large radius tracking did not run"
130 if "InDetLargeD0TrackParticles" in flags.Input.Collections:
131 # the conditions here weren't the same as above: apparently we
132 # require _both_ the input condition _and_ the tracking
133 # flag. I don't know if this is what we want but it keeps with
134 # the existing behavior.
135 #
136 # Again, the isAnalysisRelease function is needed to short
137 # circuit the flag check, since flags.Tracking doesn't exist
138 # in analysis releases.
139 if isAnalysisRelease() or flags.Tracking.doLargeD0:
140 return True, warning
141 return False, warning
142

◆ _muonSegmentInputsExist()

_muonSegmentInputsExist ( flags)
protected

Definition at line 107 of file StandardJetConstits.py.

107def _muonSegmentInputsExist(flags):
108 warning = "Muon reco is disabled"
109 if "MuonSegments" in flags.Input.Collections:
110 return True, warning
111 if isAnalysisRelease():
112 # reco flags don't exist in analysis release
113 return False, warning
114 return flags.Reco.EnableCombinedMuon, warning
115

◆ _trackParticleInputsExist()

_trackParticleInputsExist ( flags)
protected

List of standard input sources for jets.

Definition at line 97 of file StandardJetConstits.py.

97def _trackParticleInputsExist(flags):
98 warning = "Tracking is disabled and no InDetTrackParticles in input"
99 if "InDetTrackParticles" in flags.Input.Collections:
100 return True, warning
101 if isAnalysisRelease():
102 # we can't check reco flags in analysis release (and would not
103 # be building tracks anyway)
104 return False, warning
105 return flags.Reco.EnableTracking, warning
106

◆ _unassocMuonSegmentInputsExist()

_unassocMuonSegmentInputsExist ( flags)
protected

Definition at line 116 of file StandardJetConstits.py.

116def _unassocMuonSegmentInputsExist(flags):
117 warning = "UnAssociated muon segments not present"
118 if "UnAssocMuonSegments" in flags.Input.Collections:
119 return True, warning
120 if flags.Input.RunNumbers[0] < 410000:
121 # Unassociated containers only exist from Run 3 and mc23 onwards
122 return False, warning
123 if isAnalysisRelease():
124 # reco flags don't exist in analysis release
125 return False, warning
126 return flags.Reco.EnableCombinedMuon, warning
127

◆ getCaloClusterEnergyMLCalibAlgBuilder()

getCaloClusterEnergyMLCalibAlgBuilder ( )

Definition at line 143 of file StandardJetConstits.py.

143def getCaloClusterEnergyMLCalibAlgBuilder():
144 def f(flags,spec):
145 from CaloRec.CaloClusterMLCalibAlgLiteConfig import CaloClusterMLCalibAlgLiteCfg
146 return CaloClusterMLCalibAlgLiteCfg(flags._cflags)
147 return f

◆ getPFOClusterMLCorrectionAlgorithmBuilder()

getPFOClusterMLCorrectionAlgorithmBuilder ( )

Definition at line 148 of file StandardJetConstits.py.

148def getPFOClusterMLCorrectionAlgorithmBuilder():
149 def f(flags,spec):
150 from eflowRec.PFRun3Config import PFOClusterMLCorrectionAlgorithmBuilder
151 return PFOClusterMLCorrectionAlgorithmBuilder(flags._cflags, spec)
152 return f
153
154
155

◆ standardReco()

standardReco ( input)
Returns a helper function which invokes the standard reco configuration for the container 'input' 
(where input is external to the jet domain).

We group the definition of functions here rather than separately, so that we can change them 
automatically to a void function in case we're in an Analysis release and we can not import upstream packages.

Definition at line 47 of file StandardJetConstits.py.

47def standardReco(input):
48 """Returns a helper function which invokes the standard reco configuration for the container 'input'
49 (where input is external to the jet domain).
50
51 We group the definition of functions here rather than separately, so that we can change them
52 automatically to a void function in case we're in an Analysis release and we can not import upstream packages.
53
54 """
55
56 doNothingFunc = lambda *l:None # noqa: E731
57 if isAnalysisRelease():
58 return doNothingFunc
59
60
61 if input=='CaloClusters':
62 def f(jetdef,spec):
63 from CaloRec.CaloRecoConfig import CaloRecoCfg
64 flags = jetdef._cflags
65 return CaloRecoCfg(flags) if flags.Jet.doUpstreamDependencies else None
66 elif input=='Tracks':
67 def f(jetdef,spec):
68 from InDetConfig.TrackRecoConfig import InDetTrackRecoCfg
69 flags = jetdef._cflags
70 return InDetTrackRecoCfg(flags) if flags.Jet.doUpstreamDependencies else None
71 elif input=="Muons":
72 def f(jetdef,spec):
73 from MuonConfig.MuonReconstructionConfig import MuonReconstructionCfg
74 flags = jetdef._cflags
75 return MuonReconstructionCfg(flags) if flags.Jet.doUpstreamDependencies else None
76 elif input=="PFlow":
77 def f(jetdef,spec):
78 if not jetdef._cflags.Jet.doUpstreamDependencies:
79 return None
80 from eflowRec.PFRun3Config import PFCfg
81 return PFCfg(jetdef._cflags)
82 elif input=="DressedWZ":
83 def f(jetdef,spec):
84 from DerivationFrameworkMCTruth.MCTruthCommonConfig import PreJetMCTruthAugmentationsCfg
85 return PreJetMCTruthAugmentationsCfg(jetdef._cflags,decorationDressing='dressedPhoton')
86 else:
87 f = doNothingFunc
88
89 return f
90
Definition PFCfg.py:1

Variable Documentation

◆ _locked

python.StandardJetConstits._locked
protected

Definition at line 422 of file StandardJetConstits.py.

◆ _stdInputList

list python.StandardJetConstits._stdInputList
protected

Definition at line 156 of file StandardJetConstits.py.

◆ _stdModList

list python.StandardJetConstits._stdModList
protected

Definition at line 607 of file StandardJetConstits.py.

◆ _stdSeqList

list python.StandardJetConstits._stdSeqList
protected

List of standard constituent sequences This sequences uses the constit modifiers below

Definition at line 435 of file StandardJetConstits.py.

◆ _truthFlavours

list python.StandardJetConstits._truthFlavours
protected
Initial value:
= ["BHadronsInitial", "BHadronsFinal", "BQuarksFinal",
"CHadronsInitial", "CHadronsFinal", "CQuarksFinal",
"TausFinal",
"WBosons", "ZBosons", "HBosons", "TQuarksFinal",
"Partons",]

Definition at line 407 of file StandardJetConstits.py.

◆ stdConstitDic

python.StandardJetConstits.stdConstitDic = ldict()

Definition at line 27 of file StandardJetConstits.py.

◆ stdContitModifDic

python.StandardJetConstits.stdContitModifDic = ldict()

Definition at line 28 of file StandardJetConstits.py.

◆ stdInputExtDic

python.StandardJetConstits.stdInputExtDic = ldict()

Definition at line 26 of file StandardJetConstits.py.

◆ tvaKey

str python.StandardJetConstits.tvaKey = "JetTrackVtxAssoc"

Definition at line 606 of file StandardJetConstits.py.

◆ vtxKey

str python.StandardJetConstits.vtxKey = "PrimaryVertices"

Definition at line 605 of file StandardJetConstits.py.