Physical Pooling Functions in Graph Neural Networks for Molecular Property Prediction
Artur M. Schweidtmann, Jan G. Rittig, Jana M. Weber, Martin Grohe, Manuel Dahmen, Kai Leonhard, Alexander Mitsos
TL;DR
This work demonstrates that the pooling function used to aggregate atomic representations into a molecular fingerprint in graph neural networks must align with the underlying physics of the target property. By contrasting sum, mean, max, and set2set pooling across 1-GNN and MXMNet architectures on QM9 and alkanes, the authors show that sum pooling reliably captures size-dependent (extensive) properties and improves extrapolation, while mean/max pooling can fail for such properties and sometimes overfit. For size-independent (intensive) properties, pooling choice is less critical, though certain combinations (e.g., mean or max) can outperform sum in extrapolation for some targets. Overall, incorporating physical insight into pooling choices yields better generalization and should guide pooling design in future GNN-based molecular-property predictions.
Abstract
Graph neural networks (GNNs) are emerging in chemical engineering for the end-to-end learning of physicochemical properties based on molecular graphs. A key element of GNNs is the pooling function which combines atom feature vectors into molecular fingerprints. Most previous works use a standard pooling function to predict a variety of properties. However, unsuitable pooling functions can lead to unphysical GNNs that poorly generalize. We compare and select meaningful GNN pooling methods based on physical knowledge about the learned properties. The impact of physical pooling functions is demonstrated with molecular properties calculated from quantum mechanical computations. We also compare our results to the recent set2set pooling approach. We recommend using sum pooling for the prediction of properties that depend on molecular size and compare pooling functions for properties that are molecular size-independent. Overall, we show that the use of physical pooling functions significantly enhances generalization.
