JeffersonLab / JANA2

Multi-threaded HENP Event Reconstruction
https://jeffersonlab.github.io/JANA2/
Other
6 stars 9 forks source link

Add support for timeslices #278

Closed nathanwbrei closed 6 months ago

nathanwbrei commented 6 months ago

Previously, JEvent represented "physics events". This prevented JFactories, JEventProcessors, and JEventSources from operating on other levels of the event hierarchy such as timeslices, blocks, subevents, etc. This PR makes it so that JEvent can represent any level of the event hierarchy, using the JEventLevel tag. JEvents now have access to their parent events (e.g. a physics event can access the timeslice it originated from) and (in contrast with the now-superceded BlockSource) the parents' lifetimes are extended to encompass the lifetimes of all children. Factories, processors, and sources are all tied to a JEventLevel. A new component, JEventUnfolder, has been added in order to 'move down' the event hierarchy, e.g. by splitting a timeslice into physics events, or merging streams of slow detector events with fast detector events. The TopologyBuilder has been extended to automatically construct multi-event-level topologies from whatever components the user has provided.