308 stream_name =
'StreamDAOD_MUON5'
314 from DerivationFrameworkPhys.TriggerListsHelper
import TriggerListsHelper
315 MUON5TriggerListsHelper = TriggerListsHelper(flags)
318 from DerivationFrameworkMuons.JPsiVertexFitSetupCfg
import AddMCPJPsiVertexFitCfg
322 acc.merge(
MUON5KernelCfg(flags, name=
"MUON5Kernel", StreamName = stream_name, TriggerListsHelper = MUON5TriggerListsHelper))
325 from LeptonTaggers.LeptonTaggersConfig
import DecorateImprovedPromptLeptonAlgsCfg, DecoratePLITAlgsCfg
332 from OutputStreamAthenaPool.OutputStreamConfig
import OutputStreamCfg
333 from xAODMetaDataCnv.InfileMetaDataConfig
import SetupMetaDataForStreamCfg
334 from DerivationFrameworkCore.SlimmingHelper
import SlimmingHelper
336 MUON5SlimmingHelper =
SlimmingHelper(
"MUON5SlimmingHelper", NamesAndTypes = flags.Input.TypedCollections, flags = flags)
340 MUON5SlimmingHelper.SmartCollections = [
"EventInfo",
342 "InDetTrackParticles",
346 "AntiKt4EMPFlowJets",
347 "AntiKtVR30Rmax4Rmin02PV0TrackJets",
348 "BTagging_AntiKt4EMPFlow",
349 "MET_Baseline_AntiKt4EMPFlow",
353 MUON5SlimmingHelper.AllVariables = [
355 "CaloCalTopoClusters",
356 "MuonClusterCollection",
357 "TopoClusterIsoCentralEventShape",
358 "TopoClusterIsoForwardEventShape",
359 "GSFConversionVertices",
362 "AntiKtVR30Rmax4Rmin02PV0TrackJets",
365 excludedVertexAuxData =
"-vxTrackAtVertex.-MvfFitInfo.-isInitialized.-VTAV"
367 StaticContent += [
"xAOD::VertexContainer#SoftBVrtClusterTool_Tight_Vertices"]
368 StaticContent += [
"xAOD::VertexAuxContainer#SoftBVrtClusterTool_Tight_VerticesAux." + excludedVertexAuxData]
369 StaticContent += [
"xAOD::VertexContainer#SoftBVrtClusterTool_Medium_Vertices"]
370 StaticContent += [
"xAOD::VertexAuxContainer#SoftBVrtClusterTool_Medium_VerticesAux." + excludedVertexAuxData]
371 StaticContent += [
"xAOD::VertexContainer#SoftBVrtClusterTool_Loose_Vertices"]
372 StaticContent += [
"xAOD::VertexAuxContainer#SoftBVrtClusterTool_Loose_VerticesAux." + excludedVertexAuxData]
373 StaticContent += [
"CaloCellContainer#DFMUONCellContainer"]
374 StaticContent += [
"CaloClusterCellLinkContainer#MuonClusterCollection_links"]
376 MUON5SlimmingHelper.StaticContent = StaticContent
379 CommonEgammaContent= [
380 "ptcone20",
"ptcone30",
"ptcone40",
"ptvarcone20",
"ptvarcone30",
"ptvarcone40",
"topoetcone30",
381 "neflowisol20",
"neflowisol30",
"neflowisol40",
382 "ptvarcone20_Nonprompt_All_MaxWeightTTVA_pt500" ,
"ptvarcone20_Nonprompt_All_MaxWeightTTVA_pt1000",
383 "ptvarcone30_Nonprompt_All_MaxWeightTTVA_pt500",
"ptvarcone30_Nonprompt_All_MaxWeightTTVA_pt1000",
384 "ptvarcone40_Nonprompt_All_MaxWeightTTVA_pt500",
"ptvarcone40_Nonprompt_All_MaxWeightTTVA_pt1000",
385 "ptcone20_Nonprompt_All_MaxWeightTTVA_pt500",
"ptcone20_Nonprompt_All_MaxWeightTTVA_pt1000",
386 "ptcone30_Nonprompt_All_MaxWeightTTVA_pt500",
"ptcone30_Nonprompt_All_MaxWeightTTVA_pt1000",
387 "ptcone40_Nonprompt_All_MaxWeightTTVA_pt500",
"ptcone40_Nonprompt_All_MaxWeightTTVA_pt1000",
388 "topoetconecoreConeEnergyCorrection"
390 ElectronsExtraContent = [
394 "deltaPhiRescaled2",
"deltaPhiFromLastMeasurement",
395 "originalTrackParticle"
396 ] + CommonEgammaContent
400 PhotonsExtraContent = [
401 ".".
join([
"Photons"] + CommonEgammaContent )
404 MuonsExtraContent = [
408 "MeasEnergyLoss.MeasEnergyLossSigma.EnergyLossSigma.ParamEnergyLoss",
409 "ParamEnergyLossSigmaMinus.ParamEnergyLossSigmaPlus.clusterLink.scatteringCurvatureSignificance",
410 "deltaPhiRescaled2.deltaPhiFromLastMeasurement.scatteringNeighbourSignificance",
411 "ptcone20.ptcone30.ptcone40.ptvarcone20.ptvarcone30.ptvarcone40.topoetcone30",
412 "neflowisol20.neflowisol30.neflowisol40.ptvarcone20_Nonprompt_All_MaxWeightTTVA_pt500",
413 "ptvarcone20_Nonprompt_All_MaxWeightTTVA_pt1000.ptvarcone30_Nonprompt_All_MaxWeightTTVA_pt500",
414 "ptvarcone30_Nonprompt_All_MaxWeightTTVA_pt1000.ptvarcone40_Nonprompt_All_MaxWeightTTVA_pt500",
415 "ptvarcone40_Nonprompt_All_MaxWeightTTVA_pt1000.ptcone20_Nonprompt_All_MaxWeightTTVA_pt500",
416 "ptcone20_Nonprompt_All_MaxWeightTTVA_pt1000.ptcone30_Nonprompt_All_MaxWeightTTVA_pt500",
417 "ptcone30_Nonprompt_All_MaxWeightTTVA_pt1000.ptcone40_Nonprompt_All_MaxWeightTTVA_pt500",
418 "ptcone40_Nonprompt_All_MaxWeightTTVA_pt1000",
424 InDetTrackParticlesExtraContent = [
427 "InDetTrackParticles",
"TTVA_AMVFVertices.TTVA_AMVFWeights",
428 "btagIp_d0.btagIp_z0SinTheta.btagIp_d0Uncertainty.btagIp_z0SinThetaUncertainty",
429 "numberOfNextToInnermostPixelLayerHits.numberOfInnermostPixelLayerSharedHits",
430 "numberOfInnermostPixelLayerSplitHits.numberOfPixelSplitHits.leptonID"
435 ExtraVariables = ElectronsExtraContent + PhotonsExtraContent + MuonsExtraContent + InDetTrackParticlesExtraContent
436 MUON5SlimmingHelper.ExtraVariables += ExtraVariables
437 MUON5SlimmingHelper.ExtraVariables += [
438 "CombinedMuonTrackParticles.definingParametersCovMatrix.definingParametersCovMatrix.vertexLink",
439 "ExtrapolatedMuonTrackParticles.definingParametersCovMatrix.vertexLink",
440 "MuonSpectrometerTrackParticles.definingParametersCovMatrix.vertexLink",
441 "CaloCalTopoClusters.calE.calEta.calM.calPhi.e_sampl.rawM.rawPhi.rawEta.rawE",
442 "EventInfo.GenFiltHT.GenFiltMET.GenFiltHTinclNu.GenFiltPTZ.GenFiltFatJ",
445 from LeptonTaggers.LeptonTaggersConfig
import GetExtraImprovedPromptVariablesForDxAOD, GetExtraPLITVariablesForDxAOD
449 from DerivationFrameworkEGamma.ElectronsCPDetailedContent
import ElectronsCPDetailedContent
450 MUON5SlimmingHelper.ExtraVariables += ElectronsCPDetailedContent
451 from DerivationFrameworkEGamma.ElectronsCPDetailedContent
import GSFTracksCPDetailedContent
452 MUON5SlimmingHelper.ExtraVariables += GSFTracksCPDetailedContent
456 MUON5SlimmingHelper.SmartCollections += [
458 "AntiKt4TruthDressedWZJets",
460 MUON5SlimmingHelper.AllVariables += [
469 "TruthPrimaryVertices",
472 MUON5SlimmingHelper.ExtraVariables+= [
473 "TruthPrimaryVertices.t.x.y.z",
474 "InDetTrackParticles.ftagTruthTypeLabel.ftagTruthOriginLabel.ftagTruthVertexIndex"
479 MUON5SlimmingHelper.IncludeTriggerNavigation =
False
480 MUON5SlimmingHelper.IncludeJetTriggerContent =
False
481 MUON5SlimmingHelper.IncludeMuonTriggerContent =
False
482 MUON5SlimmingHelper.IncludeEGammaTriggerContent =
False
483 MUON5SlimmingHelper.IncludeTauTriggerContent =
False
484 MUON5SlimmingHelper.IncludeEtMissTriggerContent =
False
485 MUON5SlimmingHelper.IncludeBJetTriggerContent =
False
486 MUON5SlimmingHelper.IncludeBPhysTriggerContent =
False
487 MUON5SlimmingHelper.IncludeMinBiasTriggerContent =
False
491 if flags.Trigger.EDMVersion == 2:
492 from DerivationFrameworkPhys.TriggerMatchingCommonConfig
import AddRun2TriggerMatchingToSlimmingHelper
494 OutputContainerPrefix =
"TrigMatch_",
495 TriggerList = MUON5TriggerListsHelper.Run2TriggerNamesTau)
497 OutputContainerPrefix =
"TrigMatch_",
498 TriggerList = MUON5TriggerListsHelper.Run2TriggerNamesNoTau)
500 if flags.Trigger.EDMVersion == 3
or (flags.Trigger.EDMVersion == 2
and flags.Trigger.doEDMVersionConversion):
501 from TrigNavSlimmingMT.TrigNavSlimmingMTConfig
import AddRun3TrigNavSlimmingCollectionsToSlimmingHelper
505 MUON5ItemList = MUON5SlimmingHelper.GetItemList()
506 acc.merge(
OutputStreamCfg(flags,
"DAOD_MUON5", ItemList=MUON5ItemList, AcceptAlgs=[
"MUON5Kernel"]))
507 acc.merge(
SetupMetaDataForStreamCfg(flags,
"DAOD_MUON5", AcceptAlgs=[
"MUON5Kernel"], createMetadata=[MetadataCategory.CutFlowMetaData, MetadataCategory.TruthMetaData]))