Molecule Identification with Rotational Spectroscopy and Probabilistic Deep Learning

Michael McCarthy, Kin Long Kelvin LeeThe Journal of Physical Chemistry A 2020 · DOI

Abstract

A proof-of-concept framework for identifying molecules of unknown elemental composition and structure using experimental rotational data and probabilistic deep learning is presented. Using a minimal set of input data determined experimentally, we describe four neural network architectures that yield information to assist in the identification of an unknown molecule. The first architecture translates spectroscopic parameters into Coulomb matrix eigenspectra as a method of recovering chemical and structural information encoded in the rotational spectrum. The eigenspectrum is subsequently used by three deep learning networks to constrain the range of stoichiometries, generate SMILES strings, and predict the most likely functional groups present in the molecule. In each model, we utilize dropout layers as an approximation to Bayesian sampling, which subsequently generates probabilistic predictions from otherwise deterministic models. These models are trained on a modestly sized theoretical dataset comprising ∼83 000 unique organic molecules (between 18 and 180 amu) optimized at the ωB97X-D/6-31+G(d) level of theory, where the theoretical uncertainties of the spectoscopic constants are well-understood and used to further augment training. Since chemical and structural properties depend strongly on molecular composition, we divided the dataset into four groups corresponding to pure hydrocarbons, oxygen-bearing species, nitrogen-bearing species, and both oxygen- and nitrogen-bearing species, training each type of network with one of these categories, thus creating "experts" within each domain of molecules. We demonstrate how these models can then be used for practical inference on four molecules and discuss both the strengths and shortcomings of our approach and the future directions these architectures can take.

Introduction

Rotational spectroscopy is a cornerstone of molecular identification, offering unparalleled precision in distinguishing between structural isomers. However, the traditional workflow for identifying unknown species—often encountered as "U-lines" in interstellar space or laboratory plasmas—is labor-intensive. It typically requires a researcher to hypothesize a molecular structure, perform computationally expensive quantum mechanical calculations to predict its rotational constants, and then compare these to experimental data. As molecular complexity increases, the number of possible isomers grows combinatorially, making this "guess-and-check" method increasingly inefficient. This paper presents a probabilistic deep learning framework designed to automate this process, translating raw spectroscopic constants directly into chemical and structural insights.

Methodology

The proposed framework utilizes a multi-stage neural network pipeline. The input consists of eight experimentally derived parameters: three rotational constants ($A, B, C$), three dipole moment components ($\mu_a, \mu_b, \mu_c$), the Ray's asymmetry parameter ($\kappa$), and the inertial defect ($\Delta$).

The core of the approach is the Spectroscopy Decoder, a Multi-Layer Perceptron (MLP) that maps these constants to the eigenvalues of a Coulomb Matrix. The Coulomb matrix is a representation of a molecule's 3D charge distribution, where the diagonal elements relate to the atomic numbers and off-diagonal elements represent the electrostatic interaction between nuclei. By predicting the eigenspectrum of this matrix, the model creates a structural "fingerprint" that bridges the gap between physics-based spectroscopic data and chemical topology.

Coulomb matrix eigenspectra ($\lambda$) for four representative molecules: Benzaldehyde, Pyridine, Fulvene, and Benzene. These eigenspectra serve as a structural fingerprint, bridging the gap between raw spectroscopic constants and chemical identity.

Following the decoder, three specialized networks process the predicted eigenspectrum:

  1. Formula Decoder: Predicts the stoichiometry (counts of H, C, O, and N atoms).
  2. Functional Group Classifier: A 1D Convolutional Neural Network (CNN) that identifies chemical motifs such as alcohols, nitriles, or aromatic rings.
  3. SMILES Decoder: An LSTM network that generates a SMILES string, a text-based representation of the molecular structure.

To account for uncertainty, the researchers implemented Monte Carlo Dropout. By maintaining active dropout layers during inference and running the model 2,000 times for each input, the system generates a probability distribution rather than a single deterministic guess. This allows the model to quantify its confidence, which is crucial when dealing with noisy experimental data or complex mixtures.

Data and Training

The models were trained on a theoretical dataset of approximately 83,000 unique organic molecules (18–180 amu) containing H, C, O, and N. Structures were sourced from the Open Molecule Generator (OMG) and PubChem, then optimized at the $\omega$B97X-D/6-31+G(d) level of theory. To ensure robustness, the training data was augmented with synthetic noise reflecting known theoretical-experimental discrepancies. Furthermore, the dataset was partitioned into four "expert" domains (hydrocarbons, O-bearing, N-bearing, and O/N-bearing) to handle chemical degeneracies more effectively.

Key Results

The framework demonstrated high efficacy in several areas. The Formula Decoder consistently constrained the number of heavy atoms (C, O, N) to within $\pm 1$ of the ground truth. The Functional Group Classifier achieved $F_1$ scores near 0.99 for many categories, significantly outperforming baseline k-nearest neighbor models. In terms of speed, the model can perform inference in 4 to 6 seconds on a standard GPU, a massive improvement over traditional manual identification.

A case study on benzene highlighted the model's strengths; despite benzene's high symmetry making it a difficult target, the "Hydrocarbon Expert" correctly identified its mass and high degree of unsaturation.

Limitations and Future Directions

While promising, the framework has limitations. The SMILES decoder struggled with complex structures, often producing invalid strings. The model also showed a bias against highly symmetric small molecules due to their underrepresentation in the training set. Future work will explore more advanced architectures like Transformers or true Bayesian Neural Networks and expand the chemical space to include elements like sulfur and silicon, which are vital for astrochemistry.

Conclusion

This proof-of-concept demonstrates that deep learning can effectively decode the complex structural information hidden within rotational spectra. By providing probabilistic chemical identities, this framework offers a powerful new tool for researchers tackling the identification of unknown molecules in diverse scientific fields.

Summary updated

BibTeX
@article{mccarthy2020molecule,
  author = {Michael McCarthy and Kin Long Kelvin Lee},
  title = {{Molecule Identification with Rotational Spectroscopy and Probabilistic Deep Learning}},
  journal = {The Journal of Physical Chemistry A},
  year = {2020},
  doi = {10.1021/acs.jpca.0c01376},
}
Figure