pub struct HitBatch {
pub x: Vec<u16>,
pub y: Vec<u16>,
pub tof: Vec<u32>,
pub tot: Vec<u16>,
pub timestamp: Vec<u32>,
pub chip_id: Vec<u8>,
pub cluster_id: Vec<i32>,
}Expand description
A batch of hits stored in Structure of Arrays (SoA) format.
Fields§
§x: Vec<u16>Columnar storage for X coordinates.
y: Vec<u16>Columnar storage for Y coordinates.
tof: Vec<u32>Columnar storage for Time-of-Flight (corrected).
tot: Vec<u16>Columnar storage for Time-over-Threshold.
timestamp: Vec<u32>Columnar storage for global timestamps.
chip_id: Vec<u8>Columnar storage for Chip IDs (optional if batch is per-chip).
cluster_id: Vec<i32>Cluster assignments (output of clustering).
Implementations§
Source§impl HitBatch
impl HitBatch
Sourcepub fn with_capacity(capacity: usize) -> Self
pub fn with_capacity(capacity: usize) -> Self
Creates a new empty batch with specified capacity.
Sourcepub fn sort_by_tof(&mut self)
pub fn sort_by_tof(&mut self)
Sorts all hits by TOF, keeping columns aligned.
Trait Implementations§
impl StructuralPartialEq for HitBatch
Auto Trait Implementations§
impl Freeze for HitBatch
impl RefUnwindSafe for HitBatch
impl Send for HitBatch
impl Sync for HitBatch
impl Unpin for HitBatch
impl UnwindSafe for HitBatch
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more