Skip to content

Add HDF5 integrity checks, permissive data format, and robust merging#40

Merged
Jozefov merged 12 commits intopluskal-lab:mainfrom
Jozefov:feature/hdf5-merging-improvements
Apr 8, 2026
Merged

Add HDF5 integrity checks, permissive data format, and robust merging#40
Jozefov merged 12 commits intopluskal-lab:mainfrom
Jozefov:feature/hdf5-merging-improvements

Conversation

@Jozefov
Copy link
Copy Markdown
Contributor

@Jozefov Jozefov commented Mar 17, 2026

Improvements to HDF5 merging and LC-MS/MS processing robustness, developed for the GeMS dataset construction pipeline.

Key changes:

  • Add DataFormatAll permissive format class and 'ALL' fallback in assign_dformat()
  • Add MSLevelsOrder.MISSING_MS1 for files lacking MS1 spectra; make get_instrument_props() exception-safe
  • Add verify_hdf5_integrity() to detect corrupted/truncated files
  • Rewrite merge_lcmsms_hdf5s() with two-pass union-key handling, per-file metadata group, and output integrity verification

Jozefov and others added 12 commits March 17, 2026 10:26
Add a permissive DataFormatAll data format class that accepts essentially
all spectra (wide ranges for charge, m/z, intensity). Update assign_dformat()
to return 'ALL' instead of '-' when no standard format matches, and add the
'ALL' case to DataFormatBuilder.
Add MSLevelsOrder.MISSING_MS1 enum value to detect files lacking MS1
precursor spectra. Add a check in get_order_of_spectra() that returns
MISSING_MS1 when MS1 level is absent. Wrap get_instrument_props() in
try/except to gracefully handle files where TBXIC computation fails.
Add verify_hdf5_integrity() to detect corrupted/truncated HDF5 files.
Rewrite merge_lcmsms_hdf5s() with a two-pass approach: first validate
and collect union keys from all input files, then merge with proper
handling of heterogeneous datasets, metadata collection into a dedicated
HDF5 group, and output integrity verification. Add helper functions
for dataset appending, metadata coercion, and fill-array generation.
Handle MISSING_MS1 files in read_lcmsms().
@Jozefov Jozefov merged commit 83db88a into pluskal-lab:main Apr 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants