Uncertainty-Aware Chemical Analyses via Monte Carlo Deep Model Inference - Bernardo, Leandro Pereira; Pereira, Andre Luiz da S.; Dias, David Neves; Vieira, Helida; Malbar, Renato; Novaes, Aline Machado de Azevedo; Faria, Rafaella Magliano Balbi de; Carvalho, Rogerio Mesquita de; Gonçalves, Maria Luisa Aleixo; Mehl, Ana; Fernandes, Leandro A. F. (Anais da Conference on Graphics, Patterns and Images (SIBGRAPI), 2025)
We present a computer vision-based solution for estimating Chloride concentration and pH in water samples. The proposed chemical methodology produces samples with visually distinguishable reactions. Images are captured in a controlled lighting environment, and preprocessing techniques are applied to segment the Region of Interest (ROI). Each ROI is processed by a Convolutional Neural Network (CNN), which extracts highlevel descriptors. From each input sample, a total of n×n CNN-based descriptors (one per pixel in the spatially aligned feature map) yield a high-dimensional representation of local sample characteristics. They are input into a Neural Network model. After training, the model can infer a predictive distribution for each input image. This allows for the computation of descriptive statistics that characterize the associated uncertainty of the model's predictions. Our approach is inspired by the Monte Carlo method: descriptors are treated as independent observations drawn from a latent feature distribution. Although they are deterministically extracted from activation maps, they result from random visual outcomes of the same underlying analytical parameter. Conversely, they are not independent. The proposed approach can be applied to several tasks, including quality assurance, process monitoring, and compliance verification.