Closed cherylepatrick closed 10 months ago
In my "souvenir", there is an option in Bayeux to record primary geant4 step infos (G4 track and particle IDs) to make possible the reconstruction of the whole tree of generated particles. It is rather space consuming. I'll have a look in the Falaise config files. I don't remenber exactly where it is hidden :-). ASAP.
Thank you very much Francois!
Hi In principle, with flsimulate-configure, if you activate the "all_details" output profile in the configuration of the Geant4 engine embedded in Bayeux/Falaise, this would have the effect to record a large collection of raw truth hits (in the special hit collection named "__visu.track") from tracks traversing some regions of interest in the detector (source/tracker/calo(s)... but not all parts of the detector because it is soooo heavy) .
Such hits contains in principle
some raw details like the "primary particle" flag (see the mctools::base_step_hit
class) and the primary particle ID if it makes sense, the track and parent track IDs. With these informations, it is possible to rebuild the secondary particles generation scheme of the event. This implies a special offline reconstruction algorithm because Geant4 does not easily allow to provide the [grand-grand-]parent primary track ID on the fly (unless we spend some CPU in Bayeux which is not a good idea for production runs).
However, I guess everything is here to play with what you're proposing, at high storage/CPU cost.
Cheers frc
Fantastic, thank you @fmauger ! @matteoceschia - do you want to try doing a small test simulation run with all_details turned on, to see if you can access the extra info?
I've just made a quick test and asking XML output from flsimulate I was able to browse truth hits in a text editor with this kind of infos:
... more hit infos before ...
<energy_deposit>3.03984796806509860e-03</energy_deposit>
<particle_name>e-</particle_name>
<primary_particle_flag>1</primary_particle_flag>
<track_id>1</track_id>
<parent_track_id>0</parent_track_id>
<material_name>bb_source_material.basic</material_name>
<sensitive_category>__source_SD</sensitive_category>
So seems to work. frc
Fantastic! That's great!
We can close this one.
It would be useful if we could add GEANT info about which simulated tracker/calorimeter hits were generated by which primary decay particle (or its children, I guess) - would be helpful as some ground truth information for machine-learning algorithms, and could provide the missing link we need to use ML for clustering or more sophisticated reconstruction. Is it possible to add it to the event record, and how would we do it? @drbenmorgan or @fmauger I guess you might be able to advise? Thanks in advance.