Skip to content

Sigilweaver/OpenSXRaw

Repository files navigation

OpenSXRaw

CI crates.io PyPI docs.rs License: Apache-2.0 Rust MSRV

Part of the OpenMassSpec stack for mass spectrometry raw-file access.

Rust and Python reader for SCIEX .wiff/.wiff.scan legacy mass spectrometry data files, with no SCIEX SDK or software dependency. Covers the TripleTOF and QTRAP instrument families.

Documentation: sigilweaver.app/opensxraw/docs

Install

Prefer openmassspec-io with the sciex feature unless you need this parser standalone (minimal dependencies, or building your own abstraction) - the umbrella gives you format auto-detection, mzML conversion, and Arrow streaming across all wired-in vendors for free:

cargo add openmassspec-io --features sciex
pip install openmassspec[sciex]

Standalone:

Rust:

cargo add opensxraw

Python:

pip install opensxraw

Quickstart

Rust:

use opensxraw::reader::Reader;
use openmassspec_core::SpectrumSource;

let mut reader = Reader::open("sample.wiff")?;
for spectrum in reader.iter_spectra() {
    println!("{}: {} peaks", spectrum.native_id, spectrum.mz.len());
}

Python:

import opensxraw

reader = opensxraw.RawReader("sample.wiff")
spectrum = reader.read_spectrum(0)
print(spectrum.ms_level, spectrum.retention_time_sec, len(spectrum.mz))

Reader::open (and RawReader) expects the paired .wiff.scan file to sit alongside the .wiff file, with .scan appended to the .wiff filename.

See the docs site for the full guide, format specification, and API reference.

License

Apache-2.0. See LICENSE.

The format specification was developed by binary analysis of public mass-spectrometry datasets (PRIDE accessions). See CORPUS.md and ATTRIBUTION.md.

About

Rust reader for SCIEX .wiff/.wiff.scan legacy mass spectrometry files, clean-room reverse-engineered.

Resources

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages