Unsupervised machine learning-based image recognition of raw IR spectra: Toward chemist-like chemical structural classification and beyond numerical data

17 January 2025, Version 5
This content is a preprint and has not undergone peer review at the time of posting.

Abstract

Recent advances in artificial intelligence have significantly improved spectral data analysis. In this study, we used unsupervised machine learning to classify chemical compounds based on infrared (IR) spectral images, without relying on prior chemical knowledge. The potential of machine learning for chemical classification was demonstrated by extracting IR spectral images from the Spectral Database for Organic Compounds and converting them into 208620-dimensional vector data. Hierarchical clustering of 230 compounds revealed distinct main clusters (A–G), each with specific subclusters exhibiting higher intracluster similarities. Despite the challenges, including sensitivity to spectral deviations and difficulty of distinguishing delicate chemical structures in spectra with low transparency in the fingerprint area, the proposed image recognition approach exhibits good potential. Both principal component analysis (PCA) and k-means clustering produced similar results. Furthermore, the method demonstrated high robustness to noise. The Tanimoto coefficient was used to evaluate the molecular similarity, providing valuable insights. However, some results deviated from chemists’ intuitions. The study also highlighted that the scaling composition formulas and molecular weights did not affect the classification results because high-dimensional features dominated the process. A comparison of the clustering results obtained from molecular fingerprints, using the adjusted Rand index as a metric, indicated that the image data provided better classification performance than numerical data of the same resolution. Overall, this study demonstrates the feasibility of using machine learning with IR spectral image data for chemical classification and offers a novel perspective that complements traditional methods, although the classifications may not always align with chemists’ intuitions. This approach has broader implications for fields such as drug discovery, materials science, and automated spectral analysis, where handling large, raw spectral datasets is essential.

Keywords

machine learning
IR spectra
artificial intelligence
hierarchical clustering
image recognition

Supplementary materials

Title
Description
Actions
Title
SI
Description
table
Actions
Title
PW
Description
Password to access raw files @GitHub
Actions

Comments

Comments are not moderated before they are posted, but they can be removed by the site moderators if they are found to be in contravention of our Commenting Policy [opens in a new tab] - please read this policy before you post. Comments should be used for scholarly discussion of the content in question. You can find more information about how to use the commenting feature here [opens in a new tab] .
This site is protected by reCAPTCHA and the Google Privacy Policy [opens in a new tab] and Terms of Service [opens in a new tab] apply.