ATLAS Offline Software
Functions | Variables
python.StandardJetMods Namespace Reference

Functions

def _jetname (jetdef, modspec)
 
def isMC (flags)
 
def _constitContainername (jetdef, modspec)
 

Variables

 stdJetModifiers = ldict()
 
 Sort
 Define the simple modifier setups here – those defined in JetRec. More...
 
 Filter
 
 Filter_ifnotESD
 
 Filter_calibThreshold
 
 Calib
 
 PartonTruthLabel
 
 JetDeltaRLabel
 
 JetGhostLabel
 
 JetDeltaRInitialLabel
 
 JetGhostInitialLabel
 
 JetQuarkChargeLabel
 
 JetTaggingTruthLabel
 
 JetPileupLabel
 
 nsubjettiness
 
 nsubjettinessR
 
 ktdr
 
 ktsplitter
 
 angularity
 
 dipolarity
 
 planarflow
 
 ktmassdrop
 
 ecorr
 
 ecorrR
 
 ecorrgeneral
 
 ecorrgeneralratios
 
 comshapes
 
 pull
 
 charge
 
 qw
 
 softdropobs
 
 qgtransformer
 
 toptransformer
 
 vr
 

Function Documentation

◆ _constitContainername()

def python.StandardJetMods._constitContainername (   jetdef,
  modspec 
)
private
Returns the exact constituent container name used to build jetdef

Definition at line 85 of file StandardJetMods.py.

85 def _constitContainername(jetdef,modspec):
86  """Returns the exact constituent container name used to build jetdef"""
87  constitdef = jetdef.inputdef
88  containername = constitdef.containername(jetdef).split(':')[-1] if callable(constitdef.containername) else constitdef.containername
89  return containername
90 
91 
92 # Standard jet moments
93 try:
94  from JetMomentTools import JetMomentToolsConfig
95  stdJetModifiers.update(
96 
97  # Easy cases, no special config or prereqs, just default tool config
98  ClusterMoments = JetModifier("JetClusterMomentsTool", "clsmoms", JetContainer = _jetname),
99  ECPSFrac = JetModifier("JetECPSFractionTool", "ecpsfrac", JetContainer = _jetname),
100  Width = JetModifier("JetWidthTool", "width", JetContainer = _jetname),
101 
102  # More complex cases here
103  CaloEnergies = JetModifier("JetCaloEnergies", "jetens",
104  prereqs=["mod:EMScaleMom"],
105  Calculations=["EMFrac", "HECFrac", "PSFrac", "FracSamplingMax"], JetContainer = _jetname,
106  ),
107 
108  CaloEnergiesLargeR = JetModifier("JetCaloEnergies", "jetenslargeR",
109  prereqs=["mod:EMScaleMom"],
110  Calculations=["EMFrac", "HECFrac", "PSFrac", "EM3Frac", "Tile0Frac", "EffNClusts"], JetContainer = _jetname,
111  calcClusterBasedVars = True,
112  ),
113 
114  # CaloEnergiesClus is only relevant for FE-based jet collections
115  CaloEnergiesClus = JetModifier("JetCaloEnergies", "jetensclus",
116  prereqs=["mod:EMScaleMom"],
117  Calculations=["EMFrac", "HECFrac", "PSFrac", "FracSamplingMax"], JetContainer = _jetname,
118  calcClusterBasedVars = True),
119 
120  CaloQuality = JetModifier("JetCaloQualityTool", "caloqual",
121  TimingCuts = [5,10],
122  Calculations = ["LArQuality", "N90Constituents", "NegativeE", "Timing", "HECQuality", "Centroid", "AverageLArQF", "BchCorrCell"],JetContainer = _jetname),
123 
124  CaloQualityFE = JetModifier("JetCaloQualityToolFE", "caloqualFE",
125  TimingCuts = [5,10],
126  ThresholdCuts = [90],
127  Calculations = ["LArQuality", "NegativeE", "Timing", "HECQuality", "Centroid", "AverageLArQF", "BchCorrCell"],JetContainer = _jetname),
128 
129  N90 = JetModifier("JetCaloQualityTool", "n90",
130  Calculations = ["N90Constituents"],JetContainer = _jetname),
131 
132  ConstitFourMom = JetModifier("JetConstitFourMomTool", "constitfourmom_basename",
133  createfn=JetMomentToolsConfig.getConstitFourMomTool,),
134  EMScaleMom = JetModifier("JetEMScaleMomTool", "emscalemom_basename",
135  createfn=JetMomentToolsConfig.getEMScaleMomTool,
136  JetContainer = _jetname),
137 
138  JVF = JetModifier("JetVertexFractionTool", "jvf",
139  createfn=JetMomentToolsConfig.getJVFTool,
140  prereqs = [inputsFromContext("TVA"), "mod:TrackMoments", inputsFromContext("Vertices")],
141  JetContainer = _jetname),
142  JVT = JetModifier("JetVertexTaggerTool", "jvt",
143  createfn=JetMomentToolsConfig.getJVTTool,
144  prereqs = [ "mod:JVF" ],JetContainer = _jetname),
145  NNJVT = JetModifier("JetVertexNNTagger", "nnjvt",
146  createfn=JetMomentToolsConfig.getNNJvtTool,
147  prereqs = [ "mod:JVF" ],JetContainer = _jetname),
148  LArHVCorr = JetModifier("JetLArHVTool", "larhvcorr",
149  prereqs = ["mod:EMScaleMom"],JetContainer = _jetname),
150  OriginSetPV = JetModifier("JetOriginCorrectionTool", "origin_setpv",
151  prereqs = [ "mod:JVF" ],JetContainer = _jetname, OnlyAssignPV=True),
152  TrackMoments = JetModifier("JetTrackMomentsTool", "trkmoms",
153  createfn=JetMomentToolsConfig.getTrackMomentsTool,
154  prereqs = [ inputsFromContext("TVA"),"ghost:Track" ],JetContainer = _jetname),
155 
156  TrackSumMoments = JetModifier("JetTrackSumMomentsTool", "trksummoms",
157  createfn=JetMomentToolsConfig.getTrackSumMomentsTool,
158  prereqs = [ inputsFromContext("TVA"),"ghost:Track" ],JetContainer = _jetname),
159  Charge = JetModifier("JetChargeTool", "jetcharge",
160  prereqs = [ "ghost:Track" ]),
161 
162  QGTagging = JetModifier("JetQGTaggerVariableTool", "qgtagging",
163  createfn=JetMomentToolsConfig.getQGTaggingTool,
164  prereqs = lambda _,jetdef :
165  [inputsFromContext("TVA"),"mod:TrackMoments"] +
166  (["mod:JetPtAssociation"] if not isMC(jetdef._cflags) else []),
167  JetContainer = _jetname),
168 
169  fJVT = JetModifier("JetForwardPFlowJvtTool", "fJVT",
170  createfn=JetMomentToolsConfig.getPFlowfJVTTool,
171  prereqs = [inputsFromContext("TVA"),inputsFromContext("EventDensity"),inputsFromContext("Vertices"),"mod:NNJVT"],
172  JetContainer = _jetname),
173 
174  bJVT = JetModifier("JetBalancePFlowJvtTool", "bJVT",
175  createfn=JetMomentToolsConfig.getPFlowbJVTTool,
176  prereqs = [inputsFromContext("EventDensity"),inputsFromContext("Vertices"),"mod:NNJVT"],
177  JetContainer = _jetname),
178 
179  ConstitFrac = JetModifier("JetConstituentFrac", "constitFrac",
180  JetContainer = _jetname,
181  ),
182 
183  groomMRatio = JetModifier("JetGroomMRatio", "groomMRatio",
184  JetContainer = _jetname,
185  ),
186 
187  JetPtAssociation = JetModifier("JetPtAssociationTool", "jetPtAssociation",
188  filterfn=isMC,
189  createfn=JetMomentToolsConfig.getJetPtAssociationTool,
190  prereqs=["ghost:Truth"],
191  JetContainer = _jetname
192  ),
193 
194  # *******************
195  # Isolation variables
196  jetiso = JetModifier("JetIsolationTool","iso",
197  JetContainer=_jetname,
198  InputConstitContainer = _constitContainername,
199  IsolationCalculations = ["IsoFixedCone:5:Pt", "IsoFixedCone:5:PtPUsub",],
200  RhoKey = lambda jetdef, specs : "Kt4"+jetdef.inputdef.label+"EventShape" ,
201  prereqs= ["input:EventDensity"], #lambda spec,jetdef : ["input:Kt4"+jetdef.inputdef.label+"EventShape",],
202  ),
203 
204  jetisoTruth = JetModifier("JetIsolationTool","isoTruth",
205  JetContainer=_jetname,
206  InputConstitContainer = _constitContainername,
207  IsolationCalculations = ["IsoFixedCone:5:Pt", ],
208  RhoKey = "",
209  ),
210 
211 
212  )

◆ _jetname()

def python.StandardJetMods._jetname (   jetdef,
  modspec 
)
private

Definition at line 75 of file StandardJetMods.py.

75 def _jetname(jetdef,modspec):
76  return jetdef.fullname()
77 

◆ isMC()

def python.StandardJetMods.isMC (   flags)
A simple filter function for  testing if we're running in MC
returns (bool, str) where the str contains an explanation of why the bool is False.
(probably worth re-allocating somehere else)

Definition at line 78 of file StandardJetMods.py.

78 def isMC(flags):
79  """A simple filter function for testing if we're running in MC
80  returns (bool, str) where the str contains an explanation of why the bool is False.
81  (probably worth re-allocating somehere else)"""
82  return flags.Input.isMC or flags.Overlay.DataOverlay, "Input file is not MC"
83 
84 

Variable Documentation

◆ angularity

python.StandardJetMods.angularity

Definition at line 288 of file StandardJetMods.py.

◆ Calib

python.StandardJetMods.Calib

Definition at line 58 of file StandardJetMods.py.

◆ charge

python.StandardJetMods.charge

Definition at line 306 of file StandardJetMods.py.

◆ comshapes

python.StandardJetMods.comshapes

Definition at line 302 of file StandardJetMods.py.

◆ dipolarity

python.StandardJetMods.dipolarity

Definition at line 290 of file StandardJetMods.py.

◆ ecorr

python.StandardJetMods.ecorr

Definition at line 296 of file StandardJetMods.py.

◆ ecorrgeneral

python.StandardJetMods.ecorrgeneral

Definition at line 299 of file StandardJetMods.py.

◆ ecorrgeneralratios

python.StandardJetMods.ecorrgeneralratios

Definition at line 300 of file StandardJetMods.py.

◆ ecorrR

python.StandardJetMods.ecorrR

Definition at line 297 of file StandardJetMods.py.

◆ Filter

python.StandardJetMods.Filter

Definition at line 34 of file StandardJetMods.py.

◆ Filter_calibThreshold

python.StandardJetMods.Filter_calibThreshold

Definition at line 43 of file StandardJetMods.py.

◆ Filter_ifnotESD

python.StandardJetMods.Filter_ifnotESD

Definition at line 39 of file StandardJetMods.py.

◆ JetDeltaRInitialLabel

python.StandardJetMods.JetDeltaRInitialLabel

Definition at line 242 of file StandardJetMods.py.

◆ JetDeltaRLabel

python.StandardJetMods.JetDeltaRLabel

Definition at line 226 of file StandardJetMods.py.

◆ JetGhostInitialLabel

python.StandardJetMods.JetGhostInitialLabel

Definition at line 250 of file StandardJetMods.py.

◆ JetGhostLabel

python.StandardJetMods.JetGhostLabel

Definition at line 234 of file StandardJetMods.py.

◆ JetPileupLabel

python.StandardJetMods.JetPileupLabel

Definition at line 269 of file StandardJetMods.py.

◆ JetQuarkChargeLabel

python.StandardJetMods.JetQuarkChargeLabel

Definition at line 257 of file StandardJetMods.py.

◆ JetTaggingTruthLabel

python.StandardJetMods.JetTaggingTruthLabel

Definition at line 263 of file StandardJetMods.py.

◆ ktdr

python.StandardJetMods.ktdr

Definition at line 284 of file StandardJetMods.py.

◆ ktmassdrop

python.StandardJetMods.ktmassdrop

Definition at line 294 of file StandardJetMods.py.

◆ ktsplitter

python.StandardJetMods.ktsplitter

Definition at line 286 of file StandardJetMods.py.

◆ nsubjettiness

python.StandardJetMods.nsubjettiness

Definition at line 280 of file StandardJetMods.py.

◆ nsubjettinessR

python.StandardJetMods.nsubjettinessR

Definition at line 281 of file StandardJetMods.py.

◆ PartonTruthLabel

python.StandardJetMods.PartonTruthLabel

Definition at line 221 of file StandardJetMods.py.

◆ planarflow

python.StandardJetMods.planarflow

Definition at line 292 of file StandardJetMods.py.

◆ pull

python.StandardJetMods.pull

Definition at line 304 of file StandardJetMods.py.

◆ qgtransformer

python.StandardJetMods.qgtransformer

Definition at line 317 of file StandardJetMods.py.

◆ qw

python.StandardJetMods.qw

Definition at line 308 of file StandardJetMods.py.

◆ softdropobs

python.StandardJetMods.softdropobs

Definition at line 310 of file StandardJetMods.py.

◆ Sort

python.StandardJetMods.Sort

Define the simple modifier setups here – those defined in JetRec.

Definition at line 33 of file StandardJetMods.py.

◆ stdJetModifiers

python.StandardJetMods.stdJetModifiers = ldict()

Definition at line 28 of file StandardJetMods.py.

◆ toptransformer

python.StandardJetMods.toptransformer

Definition at line 329 of file StandardJetMods.py.

◆ vr

python.StandardJetMods.vr

Definition at line 339 of file StandardJetMods.py.

python.StandardJetContext.inputsFromContext
def inputsFromContext(inputKey, prefix="", suffix="")
Definition: StandardJetContext.py:112
python.StandardJetMods.isMC
def isMC(flags)
Definition: StandardJetMods.py:78
python.StandardJetMods._constitContainername
def _constitContainername(jetdef, modspec)
Definition: StandardJetMods.py:85
python.StandardJetMods._jetname
def _jetname(jetdef, modspec)
Definition: StandardJetMods.py:75
Trk::split
@ split
Definition: LayerMaterialProperties.h:38