feat: Allow configurable particle selection and reproducible seeds for Geant4
This PR does two improvements to the geant4 examples integration:
- Make particle selection configurable for
addGeant4as foraddFatras - Allow reproducible seeds for the geant4 algorithm (set the seed for each event from an
ActsExamples::RandomNumbersobject)
I did the change for the examples binaries not in the most beautiful way (so they do compile, but not changed the command line options or so), since they are deprecated anyways...
Codecov Report
Merging #1428 (52c84de) into main (4a41d30) will not change coverage. The diff coverage is
n/a.
@@ Coverage Diff @@
## main #1428 +/- ##
=======================================
Coverage 48.47% 48.47%
=======================================
Files 381 381
Lines 20699 20699
Branches 9503 9503
=======================================
Hits 10034 10034
Misses 4112 4112
Partials 6553 6553
:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more
I'm noticing that the linux_examples_test is taking very long on this PR. Usually this completes under 20min. Could this be a problem with the change here @benjaminhuth?
I'm noticing that the linux_examples_test is taking very long on this PR. Usually this completes under 20min. Could this be a problem with the change here @benjaminhuth?
I'll have a look at this after my vacation, but that will be in 2 weeks...
@paulgessinger I just tried to reproduce this locally. for me this version and main have the same performance. should we try to rerun the CI? maybe it was a coincidence
I'll try rerunning it, but I think it timed out in a few commits on this PR.
I think I resolved the problem, there was an uninitialized ActsExamples::RandomNumbers object which caused a segfault. Whats a bit strange is that a segfault seems to let the docker container freeze until the timeout...
Also, the root hashes of course change because of the changed seeds...
I think that can be merged now!
@benjaminhuth can you update the hashes?
Could you re-approve @asalzburger so we can get this in?
The backport to develop/v19.x failed:
The process '/usr/bin/git' failed with exit code 1
To backport manually, run these commands in your terminal:
# Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add .worktrees/backport-develop/v19.x develop/v19.x
# Navigate to the new working tree
cd .worktrees/backport-develop/v19.x
# Create a new branch
git switch --create backport-1428-to-develop/v19.x
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 9e22341ecb085e65471a0b4024c7d8f07477657f
# Push it to GitHub
git push --set-upstream origin backport-1428-to-develop/v19.x
# Go back to the original working tree
cd ../..
# Delete the working tree
git worktree remove .worktrees/backport-develop/v19.x
Then, create a pull request where the base branch is develop/v19.x and the compare/head branch is backport-1428-to-develop/v19.x.
The backport to develop/v19.x failed:
The process '/usr/bin/git' failed with exit code 1
To backport manually, run these commands in your terminal:
# Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add .worktrees/backport-develop/v19.x develop/v19.x
# Navigate to the new working tree
cd .worktrees/backport-develop/v19.x
# Create a new branch
git switch --create backport-1428-to-develop/v19.x
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 9e22341ecb085e65471a0b4024c7d8f07477657f
# Push it to GitHub
git push --set-upstream origin backport-1428-to-develop/v19.x
# Go back to the original working tree
cd ../..
# Delete the working tree
git worktree remove .worktrees/backport-develop/v19.x
Then, create a pull request where the base branch is develop/v19.x and the compare/head branch is backport-1428-to-develop/v19.x.
The backport to develop/v19.x failed:
The process '/usr/bin/git' failed with exit code 1
To backport manually, run these commands in your terminal:
# Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add .worktrees/backport-develop/v19.x develop/v19.x
# Navigate to the new working tree
cd .worktrees/backport-develop/v19.x
# Create a new branch
git switch --create backport-1428-to-develop/v19.x
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 9e22341ecb085e65471a0b4024c7d8f07477657f
# Push it to GitHub
git push --set-upstream origin backport-1428-to-develop/v19.x
# Go back to the original working tree
cd ../..
# Delete the working tree
git worktree remove .worktrees/backport-develop/v19.x
Then, create a pull request where the base branch is develop/v19.x and the compare/head branch is backport-1428-to-develop/v19.x.