Surpassing the human eye: machine learning image analysis rapidly determines chemical mixture composition

Machine learning model provides quick method for determining the composition of solid chemical mixtures using only photographs of the sample.

Artistic depiction of machine learning analysis of chemical mixture ratios. (Image: Yasuhide Inokuma)

Have you ever accidentally ruined a recipe in the kitchen by adding salt instead of sugar? Due to their similar appearance, it’s an easy mistake to make. Similarly, checking with the naked eye is also used in chemistry labs to provide quick, initial assessments of reactions; however, just like in the kitchen, the human eye has its limitations and can be unreliable. 

To address this, researchers at the Institute of Chemical Reaction Design and Discovery (WPI-ICReDD), Hokkaido University led by Professor Yasuhide Inokuma have developed a machine learning model that can distinguish the composition ratio of solid mixtures of chemical compounds using only photographs of the samples.

The model was designed and developed using mixtures of sugar and salt as a test case. The team employed a combination of random cropping, flipping and rotating of the original photographs in order to create a larger number of sub images for training and testing. This enabled the model to be developed using only 300 original images for training. The trained model was roughly twice as accurate as the naked eye of even the most expert member of the team.

“I think it’s fascinating that with machine learning we have been able to reproduce and even exceed the accuracy of the eyes of experienced chemists,” commented Inokuma. “This tool should be able to help new chemists achieve an experienced eye more quickly.”

Comparison of manual (top) and machine learning (bottom) methods for mixture evaluation. (Yuki Ide, et al. Industrial and Engineering Chemistry Research. August 23, 2023)

After the successful test case, researchers applied this model to the evaluation of different chemical mixtures.  The model successfully distinguished different polymorphs and enantiomers, both of which are extremely similar versions of the same molecule with subtle differences in atomic or molecular arrangement. Distinguishing these subtle differences is important in the pharmaceutical industry and normally requires a more time-consuming process.

The model was even able to handle more complex mixtures, accurately assessing the percentage of a target molecule in a four-component mixture. Reaction yield was also analyzed, determining the progress of a thermal decarboxylation reaction. 

The team further demonstrated the versatility of their model, showing that it could accurately analyze images taken with a mobile phone, after supplemental training was performed. The researchers anticipate a wide variety of applications, both in the research lab and in industry.

“We see this as being applicable in situations where constant, rapid evaluation is required, such as monitoring reactions at a chemical plant or as an analysis step in an automated process using a synthesis robot,” explained Specially Appointed Assistant Professor Yuki Ide. “Additionally, this could act as an observation tool for those who have impaired vision.”

Members of the research team at the Institute for Chemical Reaction Design and Discovery (WPI-ICReDD), Hokkaido University. Back row, left to right: Yasuhide Inokuma, Sheng Hu, Yuki Ide. Front row, left to right: Yuya Inaba, Hayato Shirakura, Taichi Sano. (Photo: WPI-ICReDD)

Published: 29 Aug 2023


Contact details:

Academic International Public Relations Officer

Kita 8, Nishi 5, Kita-ku, Sapporo
060-0808 Hokkaido

Content type: 

Yuki Ide, Hayato Shirakura, Taichi Sano, Muthuchamy Murugavel, Yuya Inaba, Sheng Hu, Ichigaku Takigawa, Yasuhide Inokuma. Machine Learning-Based Analysis of Molar and Enantiomeric Ratios and Reaction Yields Using Images of Solid Mixtures. Industrial & Engineering Chemistry Research. August 23, 2023.
DOI: 10.1021/acs.iecr.3c01882

Funding information:

This work was supported by the Japan Society for the Promotion of Science (JSPS) KAKENHI grants (22H02058, 20K21214, 20H05962, 20H0567, 21K14597, 21J20973); the Japan Science and Technology Agency (JST) SPRING grant (JPMJSP2119), FOREST grant (JPMJFR211H); the Asahi Glass Foundation Continuation Grant for Young Researchers; and the Institute for Chemical Reaction Design and Discovery (ICReDD), which was established by the World Premier International Research Initiative (WPI) of the Ministry of Education, Culture, Sports, Science and Technology of Japan (MEXT).