latentbrief
← Back to concepts

Graph Pooling

The operation of compressing a graph - many nodes and edges - into a fixed-size representation, enabling graph-level prediction tasks like molecular property prediction or graph classification.

Added May 21, 2026 · 2 min read

Graph pooling enables GNNs to tackle graph-level tasks, which are common in chemistry, biology, and materials science. Without pooling, GNNs are limited to node-level and edge-level tasks. Pooling is what makes GNNs applicable to the question what is this graph? not just what is this node?

Graph pooling is to GNNs what pooling layers are to convolutional neural networks: a way to reduce the size of a representation while preserving the most important information. In node-level tasks, GNNs produce one output per node. But many real tasks require a single output for the whole graph - is this molecule toxic? Is this network a protein with a certain function? Is this transaction graph fraudulent?

To answer graph-level questions, you need to aggregate node representations into a single graph representation. The simplest approach is global pooling: take the mean, sum, or maximum of all node representations. This is computationally cheap and often surprisingly effective, but it ignores graph structure - the same set of nodes pooled differently will produce the same result regardless of how they are connected.

Hierarchical pooling is more sophisticated. It progressively coarsens the graph, grouping nodes into clusters and representing each cluster as a single super-node. This is applied repeatedly until the graph collapses to a single node whose representation captures the whole graph. DiffPool and MinCut Pooling are widely used approaches. They learn which nodes to cluster based on their features and connections - effectively learning an assignment of nodes to clusters that is optimised for the downstream task.

The choice of pooling approach matters especially for tasks where global structure is important. For molecular graphs, a mean pooling that ignores which atoms are connected to which would miss structural isomers - molecules with the same atoms arranged differently. Hierarchical pooling can capture these structural distinctions.

Analogy

Summarising a social network for a business intelligence report. You could list statistics for every individual (no pooling), or group people by department and summarise each department (hierarchical pooling), or compute a single statistic for the whole company (global pooling). Each gives different information, and the right choice depends on what decision you need to make.

Real-world example

In drug discovery, GNNs with pooling predict properties of drug candidate molecules. Each molecule is a graph: atoms are nodes, bonds are edges. After several rounds of message passing, pooling aggregates the atom representations into a single molecular fingerprint. This fingerprint is fed to a classifier that predicts properties like toxicity, solubility, or binding affinity.

Why it matters

Graph pooling enables GNNs to tackle graph-level tasks, which are common in chemistry, biology, and materials science. Without pooling, GNNs are limited to node-level and edge-level tasks. Pooling is what makes GNNs applicable to the question what is this graph? not just what is this node?

In the news

No recent coverage - search for Graph Pooling.

Related concepts