Skip to main content

read_tof_sidecar

Function read_tof_sidecar 

Source
pub fn read_tof_sidecar(
    path: &Path,
    n_frames: Option<usize>,
) -> Result<Vec<f64>, IoError>
Expand description

Read a VENUS *_Spectra.txt TOF sidecar into bin edges (µs).

See parse_tof_sidecar_text for format semantics and validation.

§Arguments

  • path — Path to the sidecar file.
  • n_frames — When Some(n), the resulting edge count is validated against the TIFF stack’s frame count (n + 1 edges for n frames).