Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ddsim] Get total number of events and time per event right #1257

Closed
BrieucF opened this issue May 3, 2024 · 2 comments · Fixed by #1258
Closed

[ddsim] Get total number of events and time per event right #1257

BrieucF opened this issue May 3, 2024 · 2 comments · Fixed by #1258

Comments

@BrieucF
Copy link
Contributor

BrieucF commented May 3, 2024

I realized while running on an externally generated file, with the option -N -1, that the total number of event and the time per event were wrong.

There is one too many event in e.g. m_evtTotal: https://github.com/AIDASoft/DD4hep/blob/master/DDG4/src/Geant4GeneratorActionInit.cpp#L48

Geant4Output2EDM4hep INFO  +++ Saving EDM4hep event 0 run 0.
GenerationInit   INFO  +++ Initializing event 2. Within run:0 event 2.
UI               INFO  ++ End of file reached, ending run...
GenerationInit   WARN  +++ Finished run 0 after 2 events (2 events in total)

while I have only one event.

And the time per event is reported as negative due to the -1 flag:

DDSim            INFO DDSim            INFO  StartUp Time: 8.60 s, Event Processing: 351.13 s (-351.13 s/Event)

Here is a reproducer [1], let me know if you need a more streamlined one.

[1]

source /cvmfs/sw-nightlies.hsf.org/key4hep/setup.sh
ddsim --compactFile $K4GEO/FCCee/IDEA/compact/IDEA_o1_v02/IDEA_o1_v02.xml --inputFiles /afs/cern.ch/user/b/brfranco/work/public/background_studies/k4geo/pairs_1.pairs --outputFile IDEA_01_v03_pairs_1.root -N -1
@andresailer
Copy link
Member

Thanks for reporting this @BrieucF , it is fixed now.

@BrieucF
Copy link
Contributor Author

BrieucF commented May 7, 2024

Thanks to you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants