Skip to content
Snippets Groups Projects
Commit e85a28e2 authored by Yuan-Tang Chou's avatar Yuan-Tang Chou
Browse files

Add Smart Collection for ExKt jet collection.

Former-commit-id: 826ec463bc65251e5024ca80503ed0cb97218f18
parent 6efa60e8
No related branches found
No related tags found
No related merge requests found
JetReclustering @ 14d525e5
Subproject commit 14d525e5e1a97d03029e42f7819f158cf0e4397c
...@@ -25,6 +25,9 @@ FullListOfSmartContainers = [ ...@@ -25,6 +25,9 @@ FullListOfSmartContainers = [
"AntiKt6LCTopoJets", "AntiKt6LCTopoJets",
"AntiKt7LCTopoJets", "AntiKt7LCTopoJets",
"AntiKt8LCTopoJets", "AntiKt8LCTopoJets",
"AntiKt8EMTopoJets",
"AntiKt8EMTopoExKt2SubJets",
"AntiKt8EMTopoExKt3SubJets",
"BTagging_AntiKt4LCTopo", "BTagging_AntiKt4LCTopo",
"BTagging_AntiKt4EMTopo", "BTagging_AntiKt4EMTopo",
"BTagging_AntiKt4EMPFlow", "BTagging_AntiKt4EMPFlow",
...@@ -33,6 +36,8 @@ FullListOfSmartContainers = [ ...@@ -33,6 +36,8 @@ FullListOfSmartContainers = [
"BTagging_AntiKt4Track", "BTagging_AntiKt4Track",
"BTagging_AntiKtVR30Rmax4Rmin02Track", "BTagging_AntiKtVR30Rmax4Rmin02Track",
"BTagging_AntiKtVR30Rmax4Rmin02Track_expert", "BTagging_AntiKtVR30Rmax4Rmin02Track_expert",
"BTagging_AntiKt8EMTopoExKt2Sub",
"BTagging_AntiKt8EMTopoExKt3Sub",
"InDetTrackParticles", "InDetTrackParticles",
"PrimaryVertices", "PrimaryVertices",
"HLT_xAOD__MuonContainer_MuonEFInfo", "HLT_xAOD__MuonContainer_MuonEFInfo",
...@@ -43,6 +48,4 @@ FullListOfSmartContainers = [ ...@@ -43,6 +48,4 @@ FullListOfSmartContainers = [
"HLT_xAOD__BTaggingContainer_HLTBjetFex", "HLT_xAOD__BTaggingContainer_HLTBjetFex",
"HLT_xAOD__TrigBphysContainer_EFBMuMuFex", "HLT_xAOD__TrigBphysContainer_EFBMuMuFex",
"HLT_xAOD__TrigVertexCountsContainer_vertexcounts" "HLT_xAOD__TrigVertexCountsContainer_vertexcounts"
] ]
...@@ -51,7 +51,7 @@ msg.setLevel(L.logging.INFO) ...@@ -51,7 +51,7 @@ msg.setLevel(L.logging.INFO)
class lockable_list(list): class lockable_list(list):
def __init__(self,data=[]): def __init__(self,data=[]):
list.__init__(self,data) list.__init__(self,data)
self.__dict__["_locked"] = False self.__dict__["_locked"] = False
def append(self,name): def append(self,name):
if self._locked == True: if self._locked == True:
msg.error("Attempting to Modify SlimmingHelper after AppendContentToStream has Been Called") msg.error("Attempting to Modify SlimmingHelper after AppendContentToStream has Been Called")
...@@ -76,7 +76,7 @@ def buildNamesAndTypes(): ...@@ -76,7 +76,7 @@ def buildNamesAndTypes():
else: else:
from DerivationFrameworkCore.StaticNamesAndTypes import StaticNamesAndTypes from DerivationFrameworkCore.StaticNamesAndTypes import StaticNamesAndTypes
namesAndTypes = StaticNamesAndTypes namesAndTypes = StaticNamesAndTypes
return namesAndTypes return namesAndTypes
class SlimmingHelper: class SlimmingHelper:
def __init__(self,inputName): def __init__(self,inputName):
...@@ -85,9 +85,9 @@ class SlimmingHelper: ...@@ -85,9 +85,9 @@ class SlimmingHelper:
self.StaticContent = lockable_list() # Content added explicitly via old-style content lists self.StaticContent = lockable_list() # Content added explicitly via old-style content lists
self.ExtraVariables = lockable_list() # Content added by users via variable names (dictionary type:[item1,item,..,N]) self.ExtraVariables = lockable_list() # Content added by users via variable names (dictionary type:[item1,item,..,N])
# Smart slimming (only variables needed for CP + kinematics) # Smart slimming (only variables needed for CP + kinematics)
self.SmartCollections = lockable_list() self.SmartCollections = lockable_list()
self.AllVariables = lockable_list() # Containers for which all branches should be kept self.AllVariables = lockable_list() # Containers for which all branches should be kept
self.AppendToDictionary = {} self.AppendToDictionary = {}
self.NamesAndTypes = buildNamesAndTypes() self.NamesAndTypes = buildNamesAndTypes()
self.theHandler = ContentHandler(self.name+"Handler",self.NamesAndTypes) self.theHandler = ContentHandler(self.name+"Handler",self.NamesAndTypes)
self.IncludeMuonTriggerContent = False self.IncludeMuonTriggerContent = False
...@@ -99,7 +99,7 @@ class SlimmingHelper: ...@@ -99,7 +99,7 @@ class SlimmingHelper:
self.IncludeBJetTriggerContent = False self.IncludeBJetTriggerContent = False
self.IncludeBPhysTriggerContent = False self.IncludeBPhysTriggerContent = False
self.IncludeMinBiasTriggerContent = False self.IncludeMinBiasTriggerContent = False
# This hack prevents any members from being modified after lock is set to true, this happens in AppendContentToStream # This hack prevents any members from being modified after lock is set to true, this happens in AppendContentToStream
def __setattr__(self,name,value): def __setattr__(self,name,value):
if self._locked==True: if self._locked==True:
...@@ -113,25 +113,25 @@ class SlimmingHelper: ...@@ -113,25 +113,25 @@ class SlimmingHelper:
# Function to check the configuration of the Smart Slimming List # Function to check the configuration of the Smart Slimming List
def CheckList(self,masterList): def CheckList(self,masterList):
conflicted_items=[] conflicted_items=[]
for item in CompulsoryContent: for item in CompulsoryContent:
if item.endswith("#*"): if item.endswith("#*"):
compare_str=item[:-2].replace("xAOD::","") compare_str=item[:-2].replace("xAOD::","")
for m_item in masterList: for m_item in masterList:
if m_item.startswith(compare_str): if m_item.startswith(compare_str):
conflicted_items.append(m_item) conflicted_items.append(m_item)
if len(conflicted_items)!=0: if len(conflicted_items)!=0:
msg.error("Smart Slimming lists attempting to add " +str(conflicted_items)+" which are already included in Compulsory content please remove these items from Smart Slimming List") msg.error("Smart Slimming lists attempting to add " +str(conflicted_items)+" which are already included in Compulsory content please remove these items from Smart Slimming List")
raise RuntimeError("Conflict in Smart Slimming List and Compulsory Content") raise RuntimeError("Conflict in Smart Slimming List and Compulsory Content")
# The main routine: called by all job options once. # The main routine: called by all job options once.
def AppendContentToStream(self,Stream): def AppendContentToStream(self,Stream):
# Master item list: all items that must be passed to the ContentHandler for processing # Master item list: all items that must be passed to the ContentHandler for processing
# This will now be filled # This will now be filled
masterItemList = [] masterItemList = []
# All variables list: where all variables are requested, no variable lists are needed # All variables list: where all variables are requested, no variable lists are needed
# This list ensures that variables are not added individually in such cases # This list ensures that variables are not added individually in such cases
allVariablesList = [] allVariablesList = []
# Add all-variable collections # Add all-variable collections
if len(self.AllVariables)>0: if len(self.AllVariables)>0:
formatName = Stream.Name.strip("Stream_DAOD") formatName = Stream.Name.strip("Stream_DAOD")
...@@ -161,57 +161,57 @@ class SlimmingHelper: ...@@ -161,57 +161,57 @@ class SlimmingHelper:
from DerivationFrameworkCore.JetTriggerFixContent import JetTriggerFixContent from DerivationFrameworkCore.JetTriggerFixContent import JetTriggerFixContent
for item in JetTriggerFixContent: for item in JetTriggerFixContent:
Stream.AddItem(item) Stream.AddItem(item)
if (self.IncludeEtMissTriggerContent == True): if (self.IncludeEtMissTriggerContent == True):
triggerContent = True triggerContent = True
self.SmartCollections.append("HLT_xAOD__TrigMissingETContainer_TrigEFMissingET") self.SmartCollections.append("HLT_xAOD__TrigMissingETContainer_TrigEFMissingET")
from DerivationFrameworkCore.EtMissTriggerFixContent import EtMissTriggerFixContent from DerivationFrameworkCore.EtMissTriggerFixContent import EtMissTriggerFixContent
for item in EtMissTriggerFixContent: for item in EtMissTriggerFixContent:
Stream.AddItem(item) Stream.AddItem(item)
if (self.IncludeTauTriggerContent == True): if (self.IncludeTauTriggerContent == True):
triggerContent = True triggerContent = True
self.SmartCollections.append("HLT_xAOD__TauJetContainer_TrigTauRecMerged") self.SmartCollections.append("HLT_xAOD__TauJetContainer_TrigTauRecMerged")
if (self.IncludeBJetTriggerContent == True): if (self.IncludeBJetTriggerContent == True):
triggerContent = True triggerContent = True
self.SmartCollections.append("HLT_xAOD__BTaggingContainer_HLTBjetFex") self.SmartCollections.append("HLT_xAOD__BTaggingContainer_HLTBjetFex")
if (self.IncludeBPhysTriggerContent == True): if (self.IncludeBPhysTriggerContent == True):
triggerContent = True triggerContent = True
self.SmartCollections.append("HLT_xAOD__TrigBphysContainer_EFBMuMuFex") self.SmartCollections.append("HLT_xAOD__TrigBphysContainer_EFBMuMuFex")
if (self.IncludeMinBiasTriggerContent == True): if (self.IncludeMinBiasTriggerContent == True):
triggerContent = True triggerContent = True
self.SmartCollections.append("HLT_xAOD__TrigVertexCountsContainer_vertexcounts") self.SmartCollections.append("HLT_xAOD__TrigVertexCountsContainer_vertexcounts")
# Smart items # Smart items
if len(self.SmartCollections)>0: if len(self.SmartCollections)>0:
for collection in self.SmartCollections: for collection in self.SmartCollections:
masterItemList.extend(self.GetSmartItems(collection)) masterItemList.extend(self.GetSmartItems(collection))
# Run some basic tests to prevent clashes with CompulsoryContent content # Run some basic tests to prevent clashes with CompulsoryContent content
self.CheckList(masterItemList) self.CheckList(masterItemList)
# Add extra variables # Add extra variables
if len(self.ExtraVariables)>0: if len(self.ExtraVariables)>0:
for item in self.ExtraVariables: for item in self.ExtraVariables:
masterItemList.extend(self.GetExtraItems(item)) masterItemList.extend(self.GetExtraItems(item))
#Add on-the-fly containers to the dictionary #Add on-the-fly containers to the dictionary
for _cont,_type in ContainersOnTheFly: for _cont,_type in ContainersOnTheFly:
if not self.AppendToDictionary.has_key(_cont): if not self.AppendToDictionary.has_key(_cont):
self.AppendToDictionary[_cont]=_type self.AppendToDictionary[_cont]=_type
# Process the master list... # Process the master list...
# Main containers (this is a simple list of lines, one per container X collection) # Main containers (this is a simple list of lines, one per container X collection)
mainEntries = [] mainEntries = []
# Aux items (this is a dictionary: collection name and list of aux variables) # Aux items (this is a dictionary: collection name and list of aux variables)
auxEntries = {} auxEntries = {}
self.theHandler.AppendToDictionary = self.AppendToDictionary self.theHandler.AppendToDictionary = self.AppendToDictionary
mainEntries,auxEntries = self.theHandler.GetContent(masterItemList,allVariablesList) mainEntries,auxEntries = self.theHandler.GetContent(masterItemList,allVariablesList)
# Add processed items to the stream # Add processed items to the stream
excludedAuxData = "-caloExtension.-cellAssociation.-clusterAssociation" # From https://svnweb.cern.ch/trac/atlasoff/browser/InnerDetector/InDetExample/InDetRecExample/trunk/share/WriteInDetAOD.py#L41 excludedAuxData = "-caloExtension.-cellAssociation.-clusterAssociation" # From https://svnweb.cern.ch/trac/atlasoff/browser/InnerDetector/InDetExample/InDetRecExample/trunk/share/WriteInDetAOD.py#L41
excludedAuxEntries= [entry.strip("-") for entry in excludedAuxData.split(".")] excludedAuxEntries= [entry.strip("-") for entry in excludedAuxData.split(".")]
...@@ -222,7 +222,7 @@ class SlimmingHelper: ...@@ -222,7 +222,7 @@ class SlimmingHelper:
theDictionary = dict(self.NamesAndTypes.items() + self.AppendToDictionary.items()) theDictionary = dict(self.NamesAndTypes.items() + self.AppendToDictionary.items())
if item in theDictionary.keys(): if item in theDictionary.keys():
if (theDictionary[item]=='xAOD::JetAuxContainer'): if (theDictionary[item]=='xAOD::JetAuxContainer'):
entry = "xAOD::JetAuxContainer#"+item+"." entry = "xAOD::JetAuxContainer#"+item+"."
elif (theDictionary[item]=='xAOD::ShallowAuxContainer'): elif (theDictionary[item]=='xAOD::ShallowAuxContainer'):
entry = "xAOD::ShallowAuxContainer#"+item+"." entry = "xAOD::ShallowAuxContainer#"+item+"."
elif ("AuxInfo" in theDictionary[item]): elif ("AuxInfo" in theDictionary[item]):
...@@ -232,23 +232,23 @@ class SlimmingHelper: ...@@ -232,23 +232,23 @@ class SlimmingHelper:
elif (theDictionary[item]=='xAOD::EventInfo'): elif (theDictionary[item]=='xAOD::EventInfo'):
entry = "xAOD::AuxInfoBase!#"+item+"." entry = "xAOD::AuxInfoBase!#"+item+"."
elif (theDictionary[item]=='xAOD::EventShape'): elif (theDictionary[item]=='xAOD::EventShape'):
entry = "xAOD::AuxInfoBase!#"+item+"." entry = "xAOD::AuxInfoBase!#"+item+"."
# Next two lines - remaining containers # Next two lines - remaining containers
# that still need to be expanded with AuxStoreWrapper # that still need to be expanded with AuxStoreWrapper
elif (theDictionary[item] in ContainersForExpansion): elif (theDictionary[item] in ContainersForExpansion):
entry = "xAOD::AuxContainerBase#"+item+"." entry = "xAOD::AuxContainerBase#"+item+"."
else: else:
entry = "xAOD::AuxContainerBase!#"+item+"." entry = "xAOD::AuxContainerBase!#"+item+"."
for element in auxEntries[item]: for element in auxEntries[item]:
if (theDictionary[item.replace("Aux","")]=='xAOD::TrackParticleContainer') and element in excludedAuxEntries:continue #Skip anything that shouldn't be written out to a DAOD for tracks if (theDictionary[item.replace("Aux","")]=='xAOD::TrackParticleContainer') and element in excludedAuxEntries:continue #Skip anything that shouldn't be written out to a DAOD for tracks
length = len(auxEntries[item]) length = len(auxEntries[item])
if (element==(auxEntries[item])[length-1]): if (element==(auxEntries[item])[length-1]):
entry += element entry += element
else: else:
entry += element+"." entry += element+"."
if theDictionary[item.replace("Aux","")]=='xAOD::TrackParticleContainer' and auxEntries[item]=="": if theDictionary[item.replace("Aux","")]=='xAOD::TrackParticleContainer' and auxEntries[item]=="":
entry+=excludedAuxData entry+=excludedAuxData
Stream.AddItem(entry) Stream.AddItem(entry)
# Add compulsory items not covered by smart slimming (so no expansion) # Add compulsory items not covered by smart slimming (so no expansion)
for item in CompulsoryContent: for item in CompulsoryContent:
...@@ -260,14 +260,14 @@ class SlimmingHelper: ...@@ -260,14 +260,14 @@ class SlimmingHelper:
from DerivationFrameworkCore.JetTauEtMissTriggerContent import JetTauEtMissTriggerContent from DerivationFrameworkCore.JetTauEtMissTriggerContent import JetTauEtMissTriggerContent
for item in JetTauEtMissTriggerContent: for item in JetTauEtMissTriggerContent:
Stream.AddItem(item) Stream.AddItem(item)
# JetTrigger: not slimmed for now because of CLID issue # JetTrigger: not slimmed for now because of CLID issue
#if (self.IncludeJetTriggerContent == True): #if (self.IncludeJetTriggerContent == True):
# triggerContent = True # triggerContent = True
# from DerivationFrameworkCore.JetTriggerContent import JetTriggerContent # from DerivationFrameworkCore.JetTriggerContent import JetTriggerContent
# for item in JetTriggerContent: # for item in JetTriggerContent:
# Stream.AddItem(item) # Stream.AddItem(item)
# Same issue for BJetTrigger # Same issue for BJetTrigger
#if (self.IncludeBJetTriggerContent == True): #if (self.IncludeBJetTriggerContent == True):
# triggerContent = True # triggerContent = True
...@@ -275,16 +275,16 @@ class SlimmingHelper: ...@@ -275,16 +275,16 @@ class SlimmingHelper:
# for item in BJetTriggerContent: # for item in BJetTriggerContent:
# Stream.AddItem(item) # Stream.AddItem(item)
# non xAOD collections for MinBias # non xAOD collections for MinBias
if (self.IncludeMinBiasTriggerContent == True): if (self.IncludeMinBiasTriggerContent == True):
from DerivationFrameworkCore.MinBiasTrigger_nonxAOD_Content import MinBiasTrigger_nonxAOD_Content from DerivationFrameworkCore.MinBiasTrigger_nonxAOD_Content import MinBiasTrigger_nonxAOD_Content
for item in MinBiasTrigger_nonxAOD_Content: for item in MinBiasTrigger_nonxAOD_Content:
Stream.AddItem(item) Stream.AddItem(item)
if (triggerContent): if (triggerContent):
for item in CompulsoryTriggerNavigation: for item in CompulsoryTriggerNavigation:
Stream.AddItem(item) Stream.AddItem(item)
# Add non-xAOD and on-the-fly content (not covered by smart slimming so no expansion) # Add non-xAOD and on-the-fly content (not covered by smart slimming so no expansion)
badItemsWildcards = [] badItemsWildcards = []
badItemsXAOD = [] badItemsXAOD = []
...@@ -302,15 +302,15 @@ class SlimmingHelper: ...@@ -302,15 +302,15 @@ class SlimmingHelper:
if (len(badItemsXAOD)>0): if (len(badItemsXAOD)>0):
msg.error("These static items are xAOD collections: not permitted") msg.error("These static items are xAOD collections: not permitted")
print badItemsXAOD print badItemsXAOD
raise RuntimeError("Static content list contains xAOD collections") raise RuntimeError("Static content list contains xAOD collections")
#Prevent any more modifications As they will be completely ignored, and hard to debug #Prevent any more modifications As they will be completely ignored, and hard to debug
print self.ExtraVariables,dir(self.ExtraVariables) print self.ExtraVariables,dir(self.ExtraVariables)
self.StaticContent.lock() self.StaticContent.lock()
self.ExtraVariables.lock() self.ExtraVariables.lock()
self.SmartCollections.lock() self.SmartCollections.lock()
self.AllVariables.lock() self.AllVariables.lock()
self._locked=True self._locked=True
################################################################################### ###################################################################################
################################################################################### ###################################################################################
...@@ -417,7 +417,16 @@ class SlimmingHelper: ...@@ -417,7 +417,16 @@ class SlimmingHelper:
items.extend(AntiKt7LCTopoJetsCPContent) items.extend(AntiKt7LCTopoJetsCPContent)
elif collectionName=="AntiKt8LCTopoJets": elif collectionName=="AntiKt8LCTopoJets":
from DerivationFrameworkJetEtMiss.AntiKt8LCTopoJetsCPContent import AntiKt8LCTopoJetsCPContent from DerivationFrameworkJetEtMiss.AntiKt8LCTopoJetsCPContent import AntiKt8LCTopoJetsCPContent
items.extend(AntiKt8LCTopoJetsCPContent) items.extend(AntiKt8LCTopoJetsCPContent)
elif collectionName=="AntiKt8EMTopoJets":
from DerivationFrameworkJetEtMiss.AntiKt8EMTopoJetsCPContent import AntiKt8EMTopoJetsCPContent
items.extend(AntiKt8EMTopoJetsCPContent)
elif collectionName=="AntiKt8EMTopoExKt2SubJets":
from DerivationFrameworkJetEtMiss.AntiKt8EMTopoExKt2SubJetsCPContent import AntiKt8EMTopoExKt2SubJetsCPContent
items.extend(AntiKt8EMTopoExKt2SubJetsCPContent)
elif collectionName=="AntiKt8EMTopoExKt3SubJets":
from DerivationFrameworkJetEtMiss.AntiKt8EMTopoExKt3SubJetsCPContent import AntiKt8EMTopoExKt3SubJetsCPContent
items.extend(AntiKt8EMTopoExKt3SubJetsCPContent)
elif collectionName=="BTagging_AntiKt4LCTopo": elif collectionName=="BTagging_AntiKt4LCTopo":
from DerivationFrameworkFlavourTag.BTaggingContent import BTaggingStandardContent from DerivationFrameworkFlavourTag.BTaggingContent import BTaggingStandardContent
items.extend(BTaggingStandardContent("AntiKt4LCTopoJets")) items.extend(BTaggingStandardContent("AntiKt4LCTopoJets"))
...@@ -446,6 +455,12 @@ class SlimmingHelper: ...@@ -446,6 +455,12 @@ class SlimmingHelper:
elif collectionName=="BTagging_AntiKtVR30Rmax4Rmin02Track_expert": elif collectionName=="BTagging_AntiKtVR30Rmax4Rmin02Track_expert":
from DerivationFrameworkFlavourTag.BTaggingContent import BTaggingExpertContent from DerivationFrameworkFlavourTag.BTaggingContent import BTaggingExpertContent
items.extend(BTaggingExpertContent("AntiKtVR30Rmax4Rmin02TrackJets")) items.extend(BTaggingExpertContent("AntiKtVR30Rmax4Rmin02TrackJets"))
elif collectionName=="BTagging_AntiKt8EMTopoExKt2Sub":
from DerivationFrameworkFlavourTag.BTaggingContent import BTaggingExpertContent
items.extend(BTaggingExpertContent("BTagging_AntiKt8EMTopoExKt2Sub"))
elif collectionName=="BTagging_AntiKt8EMTopoExKt3Sub":
from DerivationFrameworkFlavourTag.BTaggingContent import BTaggingExpertContent
items.extend(BTaggingExpertContent("BTagging_AntiKt8EMTopoExKt3Sub"))
elif collectionName=="InDetTrackParticles": elif collectionName=="InDetTrackParticles":
from DerivationFrameworkInDet.InDetTrackParticlesCPContent import InDetTrackParticlesCPContent from DerivationFrameworkInDet.InDetTrackParticlesCPContent import InDetTrackParticlesCPContent
items.extend(InDetTrackParticlesCPContent) items.extend(InDetTrackParticlesCPContent)
...@@ -459,25 +474,25 @@ class SlimmingHelper: ...@@ -459,25 +474,25 @@ class SlimmingHelper:
from DerivationFrameworkCore.EGammaTriggerContent import EGammaTriggerContent from DerivationFrameworkCore.EGammaTriggerContent import EGammaTriggerContent
items.extend(EGammaTriggerContent) items.extend(EGammaTriggerContent)
elif collectionName=="HLT_xAOD__JetContainer_a4tcemsubjesFS": elif collectionName=="HLT_xAOD__JetContainer_a4tcemsubjesFS":
from DerivationFrameworkCore.JetTriggerContent import JetTriggerContent from DerivationFrameworkCore.JetTriggerContent import JetTriggerContent
items.extend(JetTriggerContent) items.extend(JetTriggerContent)
elif collectionName=="HLT_xAOD__TrigMissingETContainer_TrigEFMissingET": elif collectionName=="HLT_xAOD__TrigMissingETContainer_TrigEFMissingET":
from DerivationFrameworkCore.EtMissTriggerContent import EtMissTriggerContent from DerivationFrameworkCore.EtMissTriggerContent import EtMissTriggerContent
items.extend(EtMissTriggerContent) items.extend(EtMissTriggerContent)
elif collectionName=="HLT_xAOD__TauJetContainer_TrigTauRecMerged": elif collectionName=="HLT_xAOD__TauJetContainer_TrigTauRecMerged":
from DerivationFrameworkCore.TauTriggerContent import TauTriggerContent from DerivationFrameworkCore.TauTriggerContent import TauTriggerContent
items.extend(TauTriggerContent) items.extend(TauTriggerContent)
elif collectionName=="HLT_xAOD__BTaggingContainer_HLTBjetFex": elif collectionName=="HLT_xAOD__BTaggingContainer_HLTBjetFex":
from DerivationFrameworkFlavourTag.BJetTriggerContent import BJetTriggerContent from DerivationFrameworkFlavourTag.BJetTriggerContent import BJetTriggerContent
items.extend(BJetTriggerContent) items.extend(BJetTriggerContent)
elif collectionName=="HLT_xAOD__TrigBphysContainer_EFBMuMuFex": elif collectionName=="HLT_xAOD__TrigBphysContainer_EFBMuMuFex":
from DerivationFrameworkCore.BPhysTriggerContent import BPhysTriggerContent from DerivationFrameworkCore.BPhysTriggerContent import BPhysTriggerContent
items.extend(BPhysTriggerContent) items.extend(BPhysTriggerContent)
elif collectionName=="HLT_xAOD__TrigVertexCountsContainer_vertexcounts": elif collectionName=="HLT_xAOD__TrigVertexCountsContainer_vertexcounts":
from DerivationFrameworkCore.MinBiasTriggerContent import MinBiasTriggerContent from DerivationFrameworkCore.MinBiasTriggerContent import MinBiasTriggerContent
items.extend(MinBiasTriggerContent) items.extend(MinBiasTriggerContent)
else: else:
raise RuntimeError("Smart slimming container "+collectionName+" does not exist or does not have a smart slimming list") raise RuntimeError("Smart slimming container "+collectionName+" does not exist or does not have a smart slimming list")
return items return items
# Kinematics content only # Kinematics content only
...@@ -494,7 +509,7 @@ class SlimmingHelper: ...@@ -494,7 +509,7 @@ class SlimmingHelper:
auxContainerName = splitup[0]+"Aux" auxContainerName = splitup[0]+"Aux"
items = [] items = []
items.append(splitup[0]) items.append(splitup[0])
auxLine = "" auxLine = ""
length = len(splitup) length = len(splitup)
for string in splitup: for string in splitup:
if string==splitup[0]: if string==splitup[0]:
...@@ -506,18 +521,15 @@ class SlimmingHelper: ...@@ -506,18 +521,15 @@ class SlimmingHelper:
auxLine = auxLine+string+"." auxLine = auxLine+string+"."
items.append(auxLine) items.append(auxLine)
return items return items
# Check that static content is legit # Check that static content is legit
def ValidateStaticContent(self,item): def ValidateStaticContent(self,item):
# No wildcards # No wildcards
if ("*" in item): if ("*" in item):
return "WILDCARD" return "WILDCARD"
# No xAOD containers # No xAOD containers
sep = item.split("#") sep = item.split("#")
collection = sep[1] collection = sep[1]
if ("xAOD::" in item and sep[1] in self.NamesAndTypes.keys()): if ("xAOD::" in item and sep[1] in self.NamesAndTypes.keys()):
return "XAOD" return "XAOD"
return "OK" return "OK"
...@@ -105,9 +105,10 @@ OutputJets["FTAG1"] = ["AntiKtVR30Rmax4Rmin02TrackJets", ...@@ -105,9 +105,10 @@ OutputJets["FTAG1"] = ["AntiKtVR30Rmax4Rmin02TrackJets",
"AntiKt10LCTopoTrimmedPtFrac5SmallR20ExKt3SubJets", "AntiKt10LCTopoTrimmedPtFrac5SmallR20ExKt3SubJets",
"AntiKt10LCTopoTrimmedPtFrac5SmallR20ExCoM2SubJets", "AntiKt10LCTopoTrimmedPtFrac5SmallR20ExCoM2SubJets",
"AntiKt4EMTopoJets", "AntiKt4EMTopoJets",
"AntiKt8EMTopoJets", # "AntiKt8EMTopoJets",
"AntiKt8EMTopoExKt2SubJets", # "AntiKt8EMTopoExKt2SubJets",
"AntiKt8EMTopoExKt3SubJets",] # "AntiKt8EMTopoExKt3SubJets",
]
reducedJetList = ["AntiKt2PV0TrackJets", reducedJetList = ["AntiKt2PV0TrackJets",
...@@ -185,7 +186,10 @@ FTAG1SlimmingHelper.SmartCollections = ["Electrons","Muons", ...@@ -185,7 +186,10 @@ FTAG1SlimmingHelper.SmartCollections = ["Electrons","Muons",
"PrimaryVertices", "PrimaryVertices",
"InDetTrackParticles", "InDetTrackParticles",
"AntiKt4EMTopoJets", "BTagging_AntiKt4EMTopo", "AntiKt4EMTopoJets", "BTagging_AntiKt4EMTopo",
"MET_Reference_AntiKt4EMTopo"] "MET_Reference_AntiKt4EMTopo",
"AntiKt8EMTopoJets",
"AntiKt8EMTopoExKt2SubJets",
"AntiKt8EMTopoExKt3SubJets",]
FTAG1SlimmingHelper.AllVariables = ["AntiKt4EMTopoJets", FTAG1SlimmingHelper.AllVariables = ["AntiKt4EMTopoJets",
"BTagging_AntiKtVR30Rmax4Rmin02Track", "BTagging_AntiKtVR30Rmax4Rmin02Track",
...@@ -196,8 +200,8 @@ FTAG1SlimmingHelper.AllVariables = ["AntiKt4EMTopoJets", ...@@ -196,8 +200,8 @@ FTAG1SlimmingHelper.AllVariables = ["AntiKt4EMTopoJets",
"BTagging_AntiKt10LCTopoTrimmedPtFrac5SmallR20ExKt3SubJFVtx", "BTagging_AntiKt10LCTopoTrimmedPtFrac5SmallR20ExKt3SubJFVtx",
"BTagging_AntiKt10LCTopoTrimmedPtFrac5SmallR20ExCoM2Sub", "BTagging_AntiKt10LCTopoTrimmedPtFrac5SmallR20ExCoM2Sub",
"BTagging_AntiKt10LCTopoTrimmedPtFrac5SmallR20ExCoM2SubJFVtx", "BTagging_AntiKt10LCTopoTrimmedPtFrac5SmallR20ExCoM2SubJFVtx",
"BTagging_AntiKt8EMTopoExKt2Sub", # "BTagging_AntiKt8EMTopoExKt2Sub",
"BTagging_AntiKt8EMTopoExKt3Sub", # "BTagging_AntiKt8EMTopoExKt3Sub",
"BTagging_AntiKt4EMTopo", "BTagging_AntiKt4EMTopo",
"BTagging_AntiKt2Track", "BTagging_AntiKt2Track",
"BTagging_AntiKt4EMTopoJFVtx", "BTagging_AntiKt4EMTopoJFVtx",
...@@ -296,16 +300,16 @@ FTAG1SlimmingHelper.AppendToDictionary = { ...@@ -296,16 +300,16 @@ FTAG1SlimmingHelper.AppendToDictionary = {
"BTagging_AntiKt10LCTopoTrimmedPtFrac5SmallR20ExCoM2SubJFVtxAux" : "xAOD::BTagVertexAuxContainer", "BTagging_AntiKt10LCTopoTrimmedPtFrac5SmallR20ExCoM2SubJFVtxAux" : "xAOD::BTagVertexAuxContainer",
"BTagging_AntiKt10LCTopoTrimmedPtFrac5SmallR20ExCoM2SubSecVtx" : "xAOD::VertexContainer" , "BTagging_AntiKt10LCTopoTrimmedPtFrac5SmallR20ExCoM2SubSecVtx" : "xAOD::VertexContainer" ,
"BTagging_AntiKt10LCTopoTrimmedPtFrac5SmallR20ExCoM2SubSecVtxAux" : "xAOD::VertexAuxContainer", "BTagging_AntiKt10LCTopoTrimmedPtFrac5SmallR20ExCoM2SubSecVtxAux" : "xAOD::VertexAuxContainer",
"AntiKt8EMTopoJets" : "xAOD::JetContainer" , # "AntiKt8EMTopoJets" : "xAOD::JetContainer" ,
"AntiKt8EMTopoJetsAux" : "xAOD::JetAuxContainer" , # "AntiKt8EMTopoJetsAux" : "xAOD::JetAuxContainer" ,
"AntiKt8EMTopoExKt2SubJets" : "xAOD::JetContainer" , # "AntiKt8EMTopoExKt2SubJets" : "xAOD::JetContainer" ,
"AntiKt8EMTopoExKt2SubJetsAux" : "xAOD::JetAuxContainer" , # "AntiKt8EMTopoExKt2SubJetsAux" : "xAOD::JetAuxContainer" ,
"BTagging_AntiKt8EMTopoExKt2Sub" : "xAOD::BTaggingContainer" , # "BTagging_AntiKt8EMTopoExKt2Sub" : "xAOD::BTaggingContainer" ,
"BTagging_AntiKt8EMTopoExKt2SubAux" : "xAOD::BTaggingAuxContainer", # "BTagging_AntiKt8EMTopoExKt2SubAux" : "xAOD::BTaggingAuxContainer",
"AntiKt8EMTopoExKt3SubJets" : "xAOD::JetContainer" , # "AntiKt8EMTopoExKt3SubJets" : "xAOD::JetContainer" ,
"AntiKt8EMTopoExKt3SubJetsAux" : "xAOD::JetAuxContainer" , # "AntiKt8EMTopoExKt3SubJetsAux" : "xAOD::JetAuxContainer" ,
"BTagging_AntiKt8EMTopoExKt3Sub" : "xAOD::BTaggingContainer" , # "BTagging_AntiKt8EMTopoExKt3Sub" : "xAOD::BTaggingContainer" ,
"BTagging_AntiKt8EMTopoExKt3SubAux" : "xAOD::BTaggingAuxContainer" # "BTagging_AntiKt8EMTopoExKt3SubAux" : "xAOD::BTaggingAuxContainer"
} }
#---------------------------------------------------------------------- #----------------------------------------------------------------------
......
# Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
AntiKt8EMTopoExKt2SubJetsCPContent = [
"Kt4EMTopoOriginEventShape",
"Kt4EMTopoOriginEventShapeAux.Density",
"AntiKt8EMTopoExKt2SubJets",
"AntiKt8EMTopoExKt2SubJets.pt.eta.phi.m.JetConstitScaleMomentum_pt.JetConstitScaleMomentum_eta.JetConstitScaleMomentum_phi.JetConstitScaleMomentum_m.NumTrkPt500.SumPtTrkPt500.EnergyPerSampling.EMFrac.ActiveArea4vec_eta.ActiveArea4vec_m.ActiveArea4vec_phi.ActiveArea4vec_pt.AverageLArQF.DetectorEta.FracSamplingMax.FracSamplingMaxIndex.GhostTrack.HECFrac.HECQuality.Jvt.JVFCorr.JvtRpt.LArQuality.NegativeE.NumTrkPt1000.TrackWidthPt1000.GhostMuonSegmentCount.PartonTruthLabelID.ConeTruthLabelID.HadronConeExclExtendedTruthLabelID.HadronConeExclTruthLabelID.TrueFlavor.Timing",
"MET_Track",
"MET_TrackAux.name.mpx.mpy",
"MuonSegments",
"MuonSegmentsAux.",
"PrimaryVertices",
"PrimaryVerticesAux.vertexType"
]
# Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
AntiKt8EMTopoExKt3SubJetsCPContent = [
"Kt4EMTopoOriginEventShape",
"Kt4EMTopoOriginEventShapeAux.Density",
"AntiKt8EMTopoExKt3SubJets",
"AntiKt8EMTopoExKt3SubJets.pt.eta.phi.m.JetConstitScaleMomentum_pt.JetConstitScaleMomentum_eta.JetConstitScaleMomentum_phi.JetConstitScaleMomentum_m.NumTrkPt500.SumPtTrkPt500.EnergyPerSampling.EMFrac.ActiveArea4vec_eta.ActiveArea4vec_m.ActiveArea4vec_phi.ActiveArea4vec_pt.AverageLArQF.DetectorEta.FracSamplingMax.FracSamplingMaxIndex.GhostTrack.HECFrac.HECQuality.Jvt.JVFCorr.JvtRpt.LArQuality.NegativeE.NumTrkPt1000.TrackWidthPt1000.GhostMuonSegmentCount.PartonTruthLabelID.ConeTruthLabelID.HadronConeExclExtendedTruthLabelID.HadronConeExclTruthLabelID.TrueFlavor.Timing",
"MET_Track",
"MET_TrackAux.name.mpx.mpy",
"MuonSegments",
"MuonSegmentsAux.",
"PrimaryVertices",
"PrimaryVerticesAux.vertexType"
]
# Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
AntiKt8EMTopoJetsCPContent = [
"Kt4EMTopoOriginEventShape",
"Kt4EMTopoOriginEventShapeAux.Density",
"AntiKt8EMTopoJets",
"AntiKt8EMTopoJetsAux.pt.eta.phi.m.JetConstitScaleMomentum_pt.JetConstitScaleMomentum_eta.JetConstitScaleMomentum_phi.JetConstitScaleMomentum_m.NumTrkPt500.SumPtTrkPt500.EnergyPerSampling.EMFrac.ActiveArea4vec_eta.ActiveArea4vec_m.ActiveArea4vec_phi.ActiveArea4vec_pt.AverageLArQF.DetectorEta.FracSamplingMax.FracSamplingMaxIndex.GhostTrack.HECFrac.HECQuality.Jvt.JVFCorr.JvtRpt.LArQuality.NegativeE.NumTrkPt1000.TrackWidthPt1000.GhostMuonSegmentCount.PartonTruthLabelID.ConeTruthLabelID.HadronConeExclExtendedTruthLabelID.HadronConeExclTruthLabelID.TrueFlavor.Timing.ExKt2SubJets.ExKt2SubJets_ContainerName.ExKt2SubJets_IndexList.ExKt3SubJets.ExKt3SubJets_ContainerName.ExKt3SubJets_IndexList",
"MET_Track",
"MET_TrackAux.name.mpx.mpy",
"MuonSegments",
"MuonSegmentsAux.",
"PrimaryVertices",
"PrimaryVerticesAux.vertexType"
]
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment