I think I have come up with a better design of the primary generator action in the simulation:
Now all the generators inherit from a common SLArBaseGenerator class, this making possible to have a generation methods common to all generators.
Also, each generator now owns its vertex generator, these also inheriting from a common abstract base class
The new design allows one to run multiple generators in the same event (eg, cosmic + GENIE + radiogenic +... ). Downside of this is that the configuration has become a bit less immediate (no macro command yet). Instead, generators are now configured in yet another json file (you will find examples in the /assets/macros/).
Each generator has to be defined by its type (marley, genie, ...) and by a custom label for event tracking. For example, I can run in a single event multiple instances of the tyep = decay0 generator, the first with label = "Ar39_gen", second with label = "Ar42_gen", and so on.
Other sparse fixing should have improved performance and memory managment, although I still haven't touched the backtraker, nor checked if they still work.
On the side, I have fixed a wrong uint conversion in the SLArGENIEGeneratorAction which was plagin most vertices outside the TPC volume.
I think I have come up with a better design of the primary generator action in the simulation: Now all the generators inherit from a common
SLArBaseGenerator
class, this making possible to have a generation methods common to all generators. Also, each generator now owns its vertex generator, these also inheriting from a common abstract base classThe new design allows one to run multiple generators in the same event (eg, cosmic + GENIE + radiogenic +... ). Downside of this is that the configuration has become a bit less immediate (no macro command yet). Instead, generators are now configured in yet another json file (you will find examples in the
/assets/macros/
). Each generator has to be defined by its type (marley, genie, ...) and by a custom label for event tracking. For example, I can run in a single event multiple instances of the tyep = decay0 generator, the first with label = "Ar39_gen", second with label = "Ar42_gen", and so on.Other sparse fixing should have improved performance and memory managment, although I still haven't touched the backtraker, nor checked if they still work.
On the side, I have fixed a wrong uint conversion in the
SLArGENIEGeneratorAction
which was plagin most vertices outside the TPC volume.