particlemergetool.mergedGenVertices.Path = "overlaidGenVertices" from Configurables import PileupTrackHitMergeTool trackhitsmergetool = PileupTrackHitMergeTool("MyTrackHitsMergeTool") trackhitsmergetool.pileupHitsBranch = "trackHits" trackhitsmergetool.pileupPositionedHitsBranch = "positionedTrackHits" trackhitsmergetool.signalHits = "trackHits" trackhitsmergetool.signalPositionedHits = "positionedTrackHits" trackhitsmergetool.mergedHits = "overlaidTrackHits" trackhitsmergetool.mergedPositionedHits = "overlaidPositionedTrackHits" from Configurables import ConstPileUp pileuptool = ConstPileUp("MyPileupTool", numPileUpEvents=12) from Configurables import PileupOverlayAlg overlay = PileupOverlayAlg() overlay.pileupFilenames = pileupFilenames overlay.randomizePileup = False overlay.mergeTools = ["PileupParticlesMergeTool/MyPileupParticlesMergeTool", "PileupTrackHitMergeTool/MyTrackHitsMergeTool"] overlay.PileUpTool = pileuptool from Configurables import CreateExampleEventData producer = CreateExampleEventData() producer.magicNumberOffset = 300 producer.trackhits.Path = "trackHits" producer.positionedtrackhits.Path = "positionedTrackHits" producer.calohits.Path = "caloHits" producer.positionedcalohits.Path = "positionedCaloHits" producer.genparticles.Path = "genParticles" producer.genvertices.Path = "genVertices"
trackhitsmergetool.pileupHitsBranch = "TrackerHits" trackhitsmergetool.pileupPositionedHitsBranch = "TrackerPositionedHits" # branchnames for the signal trackhitsmergetool.signalHits = "TrackerHits" trackhitsmergetool.signalPositionedHits = "TrackerPositionedHits" # branchnames for the output trackhitsmergetool.mergedHits = "mergedTrackerHits" trackhitsmergetool.mergedPositionedHits = "mergedTrackerPositionedHits" # use the pileuptool to specify the number of pileup from Configurables import ConstPileUp pileuptool = ConstPileUp("ConstPileUp", numPileUpEvents=args.npileup) # algorithm for the overlay from Configurables import PileupOverlayAlg overlay = PileupOverlayAlg() overlay.pileupFilenames = pileupFilenames overlay.randomizePileup = False overlay.noSignal = args.noSignal overlay.mergeTools = [particlemergetool, simparticlemergetool, trackhitsmergetool] overlay.PileUpTool = pileuptool overlay.AuditExecute = True algList += [overlay] from Configurables import FCCDataSvc podioevent = FCCDataSvc("EventDataSvc", input=args.inputfile) # TrickTrack Seeding Configuration
particlemergetool.mergedGenVertices.Path = "overlaidGenVertices" from Configurables import PileupTrackHitMergeTool trackhitsmergetool = PileupTrackHitMergeTool("MyTrackHitsMergeTool") trackhitsmergetool.pileupHitsBranch = "trackHits" trackhitsmergetool.pileupPositionedHitsBranch = "positionedTrackHits" trackhitsmergetool.signalHits = "trackHits" trackhitsmergetool.signalPositionedHits = "positionedTrackHits" trackhitsmergetool.mergedHits = "overlaidTrackHits" trackhitsmergetool.mergedPositionedHits = "overlaidPositionedTrackHits" from Configurables import ConstPileUp pileuptool = ConstPileUp("MyPileupTool", numPileUpEvents=12) from Configurables import PileupOverlayAlg overlay = PileupOverlayAlg() overlay.pileupFilenames = pileupFilenames overlay.randomizePileup = False overlay.mergeTools = [ "PileupParticlesMergeTool/MyPileupParticlesMergeTool", "PileupTrackHitMergeTool/MyTrackHitsMergeTool" ] overlay.PileUpTool = pileuptool from Configurables import CreateExampleEventData producer = CreateExampleEventData() producer.magicNumberOffset = 300 producer.trackhits.Path = "trackHits" producer.positionedtrackhits.Path = "positionedTrackHits" producer.calohits.Path = "caloHits" producer.positionedcalohits.Path = "positionedCaloHits"
hcalfwdmergetool.signalHits = "HCalFwdCells" hcalfwdmergetool.mergedHits = "pileupHCalFwdCells" # edm data from simulation: hits and positioned hits hcalfwdmergetool = PileupCaloHitMergeTool("HCalEndcapHitMerge") hcalfwdmergetool.pileupHitsBranch = prefix + "HCalEndcapCells" hcalfwdmergetool.signalHits = "HCalEndcapCells" hcalfwdmergetool.mergedHits = "pileupHCalEndcapCells" # use the pileuptool to specify the number of pileup from Configurables import ConstPileUp pileuptool = ConstPileUp("MyPileupTool", numPileUpEvents=pileup) # algorithm for the overlay from Configurables import PileupOverlayAlg overlay = PileupOverlayAlg() overlay.pileupFilenames = pileupFilenames overlay.doShuffleInputFiles = True overlay.randomizePileup = True overlay.mergeTools = [ "PileupCaloHitMergeTool/ECalBarrelHitMerge", "PileupCaloHitMergeTool/HCalBarrelHitMerge", ] if not rebase: overlay.mergeTools += [ "PileupCaloHitMergeTool/ECalEndcapHitMerge", "PileupCaloHitMergeTool/ECalFwdHitMerge", "PileupCaloHitMergeTool/HCalExtBarrelHitMerge", "PileupCaloHitMergeTool/HCalEndcapHitMerge", "PileupCaloHitMergeTool/HCalFwdHitMerge"
hcalfwdmergetool.signalHits = "HCalFwdCells" hcalfwdmergetool.mergedHits = "pileupHCalFwdCells" # edm data from simulation: hits and positioned hits hcalfwdmergetool = PileupCaloHitMergeTool("HCalEndcapHitMerge") hcalfwdmergetool.pileupHitsBranch = "HCalEndcapCells" hcalfwdmergetool.signalHits = "HCalEndcapCells" hcalfwdmergetool.mergedHits = "pileupHCalEndcapCells" # use the pileuptool to specify the number of pileup from Configurables import ConstPileUp pileuptool = ConstPileUp("MyPileupTool", numPileUpEvents=simargs.pileup) # algorithm for the overlay from Configurables import PileupOverlayAlg overlay = PileupOverlayAlg() overlay.pileupFilenames = pileupFilenames overlay.randomizePileup = True overlay.mergeTools = [ "PileupParticlesMergeTool/ParticlesMerge", "PileupCaloHitMergeTool/ECalBarrelHitMerge", "PileupCaloHitMergeTool/ECalEndcapHitMerge", "PileupCaloHitMergeTool/ECalFwdHitMerge", "PileupCaloHitMergeTool/HCalBarrelHitMerge", "PileupCaloHitMergeTool/HCalExtBarrelHitMerge", "PileupCaloHitMergeTool/HCalEndcapHitMerge", "PileupCaloHitMergeTool/HCalFwdHitMerge" ] overlay.PileUpTool = pileuptool overlay.noSignal = noSignal