Compressed Bruker format files containing 2D NMR data.
Output Files:
nmrML Files
XML-based files following the nmrML standard, containing:
Metadata about the experiment
Molecular structure
Spectral data
Peak assignments
Extracted Files from nmrml_extract.py
.mol: Molecular structure
_peaklist.csv: List of peaks and their properties
_assignments.csv: Atom-to-peak assignments
_metadata.json: Experiment metadata
Algorithms:
nmrml_creator.py
Molecular Structure Processing:Parses SDF/MOL files to extract atom coordinates and bond information, converts to nmrML-compatible XML format
Spectrum Processing:Processes raw spectral data (FID or processed spectra), applies optional processing like water signal removal, encodes spectral data in base64 format (with optional compression)
Peak and Assignment Processing:Parses peak lists, identifies chemical shifts and multiplet structures, maps peaks to molecular structure if assignments available
2D Spectrum Processing:Processes 2D NMR data (e.g., HSQC), creates contour plots and JSON representations, handles assignments
nmrml_extract.py
XML Parsing:Parses the nmrML XML structure, extracts metadata, molecular structure, and spectral data
Molecular Structure Extraction:Converts XML representation back to MOL format, reconstructs 2D coordinates
Assignment Extraction:Extracts peak assignments, converts to CSV, maps to molecular structure
Spectral Data Decoding:Decodes base64 spectral data, decompresses, converts to numeric arrays
Examples:
The examples directory contains sample input files:
Example CSV files for chemical shifts
Example peak lists
Example SDF/MOL files
Contributing:
Contributions to improve the toolkit are welcome. Please follow these steps:
Fork the repository
Create a feature branch
Submit a pull request
License:
This project is licensed under the MIT License - see the LICENSE file for details.
Acknowledgments:
This toolkit was developed as part of the Natural Products Magnetic Resonance Database (NP-MRD) project at the Wishart Lab.