OpenARaw
Part of the OpenMassSpec stack for mass spectrometry raw-file access.
Rust and Python reader for Agilent MassHunter .d mass spectrometry data
directories, with no Agilent SDK or software dependency. Covers the
modern AcqData MassHunter shape across Q-TOF (profile and centroid)
and QQQ (MRM) acquisitions.
Documentation: sigilweaver.app/openaraw/docs
Known issues and gaps
- Q-TOF m/z accuracy depends on the run's calibration. The reader
applies each scan's stored calibration and does no reference-mass
correction of its own. Measured on public corpus runs: peptide fragment
ions (y1, immonium) read at a median of -2 to -9 ppm (95th percentile
8 to 16 ppm), and background ions not used for locking (siloxanes,
DEHP) at a median of -3.6 to +3.2 ppm over 19 bundles. Runs without
reference-mass correction can be off by 10 to 20 ppm:
- PXD031927 (G6550A): reference ion +12.5 ppm, siloxanes +17 to +19 ppm.
- PXD044639 (G6550B, acquisition software 10.1): purine 121.0509 at -17.5 to -19.2 ppm.
- PXD057471 (G6540A,
DefaultMassCal.xmlonly): DEHP at -11 to -13.5 ppm.
- Stored MS2 precursor m/z can disagree with the MS1 peak. In PXD031402 and PXD014285 the precursor target m/z differs from the matching MS1 peak by about 32 ppm and 10 ppm. Use a precursor tolerance of at least 30 ppm, or re-pick the precursor from the MS1 scan. Q-TOF MS2 spectra have no parent-scan link, charge state or isolation width.
- Collision energy has no unit.
MSScan.xsdtypes the scan record'sCollisionEnergyas a bare double, and no other file in the bundle states its unit. TheVoltsandVoltageunits inMSActualDefs.xmlbelong to telemetry channels (Collision Energy:1to4,Col. Cell Energy) whose logged values differ from the scan records (Col. Cell Energylogs about 3 where the records carry 40.0 in PXD031771/526b_1.d), so they do not give the unit of the record's field. The reader reports the value with an unknown unit and declares the checkunknown_collision_energy_unitinRunMetadata::unstated, sowrite_mzmlconverts every Q-TOF MS/MS bundle (185 of the 332 readable corpus bundles) with default options: the value is written as a unit-lessuserParam, each MS/MS spectrum carries anopenmassspec: warning unknown_collision_energy_unitentry, and the run carries oneunstated_by_sourcewarning. Do not read the number as eV or NCE. In Python,collision_energies[i]["unit"]isNone. - Triple quadrupole (MRM) spectra have no stateable precursor. The scan
record holds the product m/z and the MRM channel number
(
extra["openaraw.mrm_channel_id"]); the Q1 m/z lives in the method file and is not read. An MRM spectrum therefore has ms level 2, notarget_mz,selected_mzorprecursor_native_id, and no collision energy, and per-transition SRM chromatograms are not emitted. The mzML writer accepts these spectra and the 108 MRM corpus bundles convert, but Core'sassert_source_invariantsrejects them withMissingPrecursor, sotests/conformance.rschecks the other invariants through a wrapper that adds a placeholdertarget_mz. Product m/z values are stored directly and match the method's transitions. - Bundles that cannot be decoded raise errors. A Q-TOF bundle with
neither
MSMassCal.binnorDefaultMassCal.xmlhas no calibration (PXD031771/655_2.d), and a bundle whose scan records point into a missing data file cannot be read (PXD022473/M.d, noMSProfile.bin). Each affected scan is an error fromiter_spectra(RuntimeErrorin Python); flight times are never reported as m/z. Malformed folders withoutAcqDataorMSScan.binfail to open (6 of 338 corpus uploads). - Corpus gaps. Tested instruments are the G6410A triple quadrupole
and G6530, G6540 and G6550 Q-TOFs. Negative mode is covered only by
the short negative segment of five PXD031771 runs (190 spectra). Not
covered: ion mobility (6560), GC-MS ChemStation
.Dfolders (DATA.MS), and models not yet seen in public data (for example 6545, 6546, 6470 and 6495).
Install
Prefer openmassspec-io
with the agilent feature/extra 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 agilent
pip install openmassspec[agilent]
Standalone:
Rust:
cargo add openaraw
Python:
pip install openaraw
Quickstart
Rust:
use openaraw::reader::Reader;
use openmassspec_core::SpectrumSource;
let mut reader = Reader::open("sample.d")?;
for spectrum in reader.iter_spectra() {
let spectrum = spectrum?;
println!("{}: {} peaks", spectrum.native_id, spectrum.mz.len());
}
Python:
import openaraw
reader = openaraw.RawReader("sample.d")
spectrum = reader.read_spectrum(0)
print(spectrum.ms_level, spectrum.retention_time_sec, len(spectrum.mz))
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.
Metadata
Release files for openaraw 2.0.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| openaraw-2.0.0.tar.gz | 67.8 kB | With provenance | Details for openaraw-2.0.0.tar.gz |
Built distributions (wheels)
| File | Actions Reset | |||
|---|---|---|---|---|
| openaraw-2.0.0-cp310-abi3-win_amd64.whl | CPython 3.10 | abi3 | Windows x86-64 | Details for openaraw-2.0.0-cp310-abi3-win_amd64.whl |
| openaraw-2.0.0-cp310-abi3-manylinux2014_x86_64.manylinux_2_17_x86_64.whl | CPython 3.10 | abi3 | Linux glibc 2.17+ x86-64 | Details for openaraw-2.0.0-cp310-abi3-manylinux2014_x86_64.manylinux_2_17_x86_64.whl |
| openaraw-2.0.0-cp310-abi3-manylinux2014_aarch64.manylinux_2_17_aarch64.whl | CPython 3.10 | abi3 | Linux glibc 2.17+ ARM64 | Details for openaraw-2.0.0-cp310-abi3-manylinux2014_aarch64.manylinux_2_17_aarch64.whl |
| openaraw-2.0.0-cp310-abi3-macosx_11_0_arm64.whl | CPython 3.10 | abi3 | macOS 11.0+ ARM64 | Details for openaraw-2.0.0-cp310-abi3-macosx_11_0_arm64.whl |
| openaraw-2.0.0-cp310-abi3-macosx_10_12_x86_64.whl | CPython 3.10 | abi3 | macOS 10.12+ x86-64 | Details for openaraw-2.0.0-cp310-abi3-macosx_10_12_x86_64.whl |
Total release size: 2.2 MB
Release files / openaraw-2.0.0.tar.gz
| Download URL | openaraw-2.0.0.tar.gz |
|---|---|
| Size | 67.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
3f07371446f252592d3a516279d723df678266fdda2ab11e04ed4aeeb01d5b7f
|
|
BLAKE2b-256 checksum How to use checksums |
62b507aff3d3b2c45d91c3969040c850fb1257f34270cf91e2a19a8e6c9e0552
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 27, 2026.
Transparency logRelease files / openaraw-2.0.0-cp310-abi3-win_amd64.whl
| Download URL | openaraw-2.0.0-cp310-abi3-win_amd64.whl |
|---|---|
| Size | 330.4 kB |
| Tags | CPython 3.10 Windows x86-64 abi3 |
|
SHA-256 checksum How to use checksums |
f6dd423ce8c65117a2475ecdc9ad032894397cfa653ffa5d6ebd9af266d175a7
|
|
BLAKE2b-256 checksum How to use checksums |
9dc1a3c88cc3ceada56ddbf6374a47fdb50428e25cdf3c95423a7523a899fb68
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 27, 2026.
Transparency logRelease files / openaraw-2.0.0-cp310-abi3-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
| Download URL | openaraw-2.0.0-cp310-abi3-manylinux2014_x86_64.manylinux_2_17_x86_64.whl |
|---|---|
| Size | 487.4 kB |
| Tags | CPython 3.10 Linux glibc 2.17+ x86-64 abi3 |
|
SHA-256 checksum How to use checksums |
3d70122ee2f7172396d4b75473e652604e86883b8a3b1a4e194b765b79db4b1c
|
|
BLAKE2b-256 checksum How to use checksums |
268b8284ae453392357240c13e49d5c23b64a919693d2f4fdb036e7940c5e783
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 27, 2026.
Transparency logRelease files / openaraw-2.0.0-cp310-abi3-manylinux2014_aarch64.manylinux_2_17_aarch64.whl
| Download URL | openaraw-2.0.0-cp310-abi3-manylinux2014_aarch64.manylinux_2_17_aarch64.whl |
|---|---|
| Size | 474.9 kB |
| Tags | CPython 3.10 Linux glibc 2.17+ ARM64 abi3 |
|
SHA-256 checksum How to use checksums |
3dfb54730d96329aeef664e64e734d3e4ea9f039535b23a0eac5199317da493f
|
|
BLAKE2b-256 checksum How to use checksums |
cb6e7d5e0b8d73b00a17aae14b6ade275249d47b024a5e515885ac224a1d511f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 27, 2026.
Transparency logRelease files / openaraw-2.0.0-cp310-abi3-macosx_11_0_arm64.whl
| Download URL | openaraw-2.0.0-cp310-abi3-macosx_11_0_arm64.whl |
|---|---|
| Size | 434.4 kB |
| Tags | CPython 3.10 abi3 macOS 11.0+ ARM64 |
|
SHA-256 checksum How to use checksums |
5a21ab288c2dc1d4dff8403ca12f278a5e1f07e58b2d9a2472706db85e45dd81
|
|
BLAKE2b-256 checksum How to use checksums |
656f71ff6e0bbde77b256cca7664456d85655f8d455ba88f3b5ae740dc3e45a1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 27, 2026.
Transparency logRelease files / openaraw-2.0.0-cp310-abi3-macosx_10_12_x86_64.whl
| Download URL | openaraw-2.0.0-cp310-abi3-macosx_10_12_x86_64.whl |
|---|---|
| Size | 439.4 kB |
| Tags | CPython 3.10 abi3 macOS 10.12+ x86-64 |
|
SHA-256 checksum How to use checksums |
fbdcbaf1fccc1d14a52acaa514f17f53a594459266c9059dd07519fc0be8ea7a
|
|
BLAKE2b-256 checksum How to use checksums |
e283f5e586bbf02cac2a3e5113c001b96863e544322f99f02d3f025f592d7d4e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 27, 2026.
Transparency logSecurity for openaraw 2.0.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
All 6 files in this release have been uploaded with provenance metadata.
Attestation for openaraw-2.0.0.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 27, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.