Add particle data table for charge/mass lookups
Adds a particle data table to the ActsFatras
library. The underlying data structures are automatically generated with a python script using the excellent scikit-ehp/particle package. ActsFatras::Particle
can now be constructed with just a PDG id and charge/mass is automatically retrieved.
Fixes #702 (closed).
Merge request reports
Activity
changed milestone to %0.17.00
added Component - Fatras Improvement Minor labels
added 5 commits
Toggle commit listadded 13 commits
-
1b2ae93c...a92b4429 - 7 commits from branch
master
- e1184f04 - Fatras: add particle data table generation script
- 8b659dfb - Fatras: add particle data table
- fa66039b - Fatras: add particle data table tests
- b26d1ade - Fatras: allow Particle construction from PDG id alone
- efdfaf6c - Fatras: fix process setter name for Particle
- aa09aaf2 - Fatras: remove explicit charge/mass from test datasets
Toggle commit list-
1b2ae93c...a92b4429 - 7 commits from branch
My thinking was that at the moment we only need very few quantities anyways. Charge, mass, and, name are the only ones stored and used at the moment. We do not need the full particle data including composition, width, decays, etc. and I did not want to add another dependency. Storing the quantities directly in code should give the fastest access and requires no file handling (as opposed to e.g. shipping a text file and parsing it on-the-fly).
I initially wanted to just use the most recent data file from the particle data group directly and started writing my own parser. Then I found the python scikit-hep/particle package that does all of that for me and saved me quite a bit of time. In the end, both scikit-hep/particle and something like
HepMC::PDG
uses the same underlying data tables from the particle data group. This particular way of using it is nice and fast and I hope has the least amount of overhead (both runtime and external dependencies).In any case, I do not expect this to be the one-true-source of particle data for us. E.g. if we generate particles with Pythia, mass and charge are taken from their internal tables and this is not touched. I expect this to be used mostly for tests and e.g. when running Fatras with a particle gun or similar setups.
added Approved label
added 14 commits
-
aa09aaf2...5d196c82 - 8 commits from branch
master
- a0e2120b - Fatras: add particle data table generation script
- fe3010dd - Fatras: add particle data table
- cd25ff2f - Fatras: add particle data table tests
- 947d28c5 - Fatras: allow Particle construction from PDG id alone
- dd1f0f05 - Fatras: fix process setter name for Particle
- 8e3f1dcc - Fatras: remove explicit charge/mass from test datasets
Toggle commit list-
aa09aaf2...5d196c82 - 8 commits from branch
enabled an automatic merge when the pipeline for 8e3f1dcc succeeds
mentioned in commit 7813a2a1
changed milestone to %0.18.00
changed milestone to %0.17.00