16.3. Hit Collections
Table of Contents
Recording detector interactions
In GATE, a hit collection is the structured record of all microscopic detector interactions that occur in specified sensitive volumes during a simulation. Each individual interaction is a hit, and the hit collection is the container that groups these hits together so that you can later transform them into detector-level signals through the digitizer chain or analyze them directly.
A hit is created whenever a particle deposits energy inside a volume that has been declared sensitive. For example, each time a gamma photon interacts in a scintillation crystal and transfers some energy, GATE can record a hit with information such as the deposited energy, the position of the interaction, the time, and identifiers that tell you which volume and which event produced the hit. These hits are then stored in hit collections that are organized by sensitive detector and by volume hierarchy.
Hit collections connect the detailed physics of particle transport with the electronics-level modeling that follows. The digitizer chain does not work with individual Geant4 steps, it works with hit collections. First, GATE groups all the hits recorded during the simulation into collections, often one collection per sensitive detector system, for example one for the PET crystals and another for a timing layer. After the simulation ends, or at user-defined points, these collections can be processed to create singles or higher-level quantities such as coincidences.
Hit collections also preserve the link between low-level physics events and later reconstructed data. Each hit typically stores an event or track identifier, so you can, for example, trace back a particular coincidence event in PET to the original annihilation and to the multiple hits it created in different crystals. This is essential when you want to label events as true, scattered, or random, or when you need to study detector performance in detail.
From a practical point of view, recording detector interactions means attaching appropriate actors or sensitive detectors to your volumes and configuring them so that GATE writes out the desired hit information. You can choose which attributes to save, such as position, energy, time, particle type, or volume ID, to control file size and keep only what you need. The resulting hit collections are typically written to ROOT files, where each collection corresponds to a tree or a branch that you can inspect later using ROOT or Python tools.
It is important to understand that hit collections are not yet what a real detector would output. They are idealized lists of microscopic interactions, without energy blurring, dead time, or thresholds. These effects are introduced later, in the digitizer stage. By separating hit recording from digitization, GATE lets you reuse the same hit collections with different digitizer configurations, for example to test the impact of various energy resolutions or thresholds on the final detector performance without re-running the full physics simulation.
When you design a simulation, you decide which geometry elements should be sensitive and therefore produce hits. For example, in a gamma camera, you might set the NaI crystal as sensitive but leave the collimator and shielding as non-sensitive, so only interactions in the crystal appear in the hit collection. In a PET scanner, you typically define each crystal as a sensitive volume so that every interaction in any crystal is recorded. You then obtain one or more hit collections that reflect the chosen granularity of your detector model.
Finally, working with hit collections requires careful thought about performance and storage. Recording every interaction in a large voxelized patient phantom, for instance, can create enormous hit collections, which may not be needed if you are only interested in dose. In contrast, for detailed detector studies, you might deliberately keep all hits in the scintillator to study light yield or timing characteristics. Understanding what a hit collection is and how it is built is therefore essential when you plan efficient, meaningful detector simulations in GATE.
Views: 10
KAHIBARO