Skip to content
Snippets Groups Projects

start work on DummyFF benchmark

Open Sylvester Joosten requested to merge add_ff into master
Files
6
+ 58
0
from Gaudi.Configuration import *
from Configurables import ApplicationMgr, EICDataSvc, PodioOutput, GeoSvc
from GaudiKernel import SystemOfUnits as units
detector_name = "athena"
if "JUGGLER_DETECTOR" in os.environ :
detector_name = str(os.environ["JUGGLER_DETECTOR"])
detector_path = ""
if "DETECTOR_PATH" in os.environ :
detector_path = str(os.environ["DETECTOR_PATH"])
# todo add checks
input_sim_file = str(os.environ["JUGGLER_SIM_FILE"])
output_rec_file = str(os.environ["JUGGLER_REC_FILE"])
n_events = str(os.environ["JUGGLER_N_EVENTS"])
podioevent = EICDataSvc("EventDataSvc", inputs=[input_sim_file], OutputLevel=WARNING)
from Configurables import PodioInput
from Configurables import Jug__Base__InputCopier_dd4pod__Geant4ParticleCollection_dd4pod__Geant4ParticleCollection_ as MCCopier
from Configurables import Jug__Reco__DummyFarForwardParticles as DummyFFRec
algorithms = [ ]
podioinput = PodioInput("PodioReader",
collections=["mcparticles"])#, OutputLevel=DEBUG)
algorithms.append( podioinput )
## copiers to get around input --> output copy bug. Note the "2" appended to the output collection.
copier = MCCopier("MCCopier",
inputCollection="mcparticles",
outputCollection="mcparticles2")
algorithms.append( copier )
ff_rec = DummyFFRec("DummyFFRec",
inputMCParticles="mcparticles",
outputParticles="ReconstructedParticles",
OutputLevel=DEBUG)
algorithms.append( ff_rec )
out = PodioOutput("out", filename=output_rec_file)
out.outputCommands = ["keep *",
"drop mcparticles"
]
algorithms.append(out)
ApplicationMgr(
TopAlg = algorithms,
EvtSel = 'NONE',
EvtMax = n_events,
ExtSvc = [podioevent],
OutputLevel=WARNING
)
Loading