Graph Element Networks: adaptive, structured computation and memory

Ferran Alet, Adarsh K. Jeewajee, Maria Bauzá, Alberto Rodriguez, Tomás Lozano-Pérez, Leslie Pack Kaelbling

TL;DR

This paper introduces Graph Element Networks (GENs), a novel approach that leverages Graph Neural Networks (GNNs) to model spatial processes without requiring a predefined graph structure. GENs adaptively optimize node placement and connectivity within a continuous space, enabling efficient and flexible computation for tasks like solving partial differential equations, predicting physical interactions, and representing complex scenes.

What Problem Does This Paper Address?

Traditional deep learning models often rely on fixed architectural inductive biases that are well-suited for specific data structures (e.g., CNNs for images, GNNs for explicit graphs). However, many real-world problems involve spatial processes where there isn't a clear, a priori graphical structure. Examples include modeling physical phenomena like heat diffusion or fluid dynamics, or understanding spatial relationships in robotics and scene understanding. Existing methods often struggle to generalize to different spatial scales, levels of detail, or complex, arbitrary shapes. This paper aims to bridge this gap by proposing a flexible and adaptive computational framework that can learn to structure its own computation over continuous spatial domains.

Methods

The core contribution is the Graph Element Network (GEN). GENs treat GNNs as a computational substrate for modeling spatial functions. Instead of pre-defining nodes and edges, GENs:

  • Mesh a continuous space: Nodes are placed within the spatial domain (X), and their locations can be optimized.
  • Use GNNs for propagation: A GNN operates on these nodes in a latent space, propagating information to model relationships between spatial locations. This is inspired by finite element methods (FEMs) where a continuous domain is divided into smaller elements.
  • Adaptive Representation: A key innovation is the ability to optimize node positions and graph connectivity. This allows the network to allocate computational resources (nodes) to more complex or important regions of the space, effectively creating a "mesh" tailored to the problem.
  • Generalization: The learned GNN weights are shared across nodes, allowing the same model to operate on spaces of different sizes or at varying levels of precision by adjusting the number and placement of nodes.
  • Encoder-Decoder Architecture: Input spatial functions are encoded into the latent space, processed by the GNN, and then decoded to produce output functions.

Datasets

The paper demonstrates GENs on several tasks, utilizing existing datasets and implicitly defining new ones for specific experiments:

  • Partial Differential Equations (PDEs): The authors generated their own datasets for modeling heat propagation in "houses" (2D squares) and on spheres. These datasets involved varying heater/cooler positions and temperatures, with ground truth solutions obtained from FEM solvers or numerically computed.
  • Robotics (Omnipush): The Omnipush dataset was used, which consists of real-world data of a robot pushing objects of varying shapes and weights. The input includes images and push parameters, and the output is the object's final pose.
  • Scene Representation: The problem of neural scene representation was tackled using a dataset similar to that used in prior work (Eslami et al., 2018), involving 2D images from different camera poses within a 3D scene (mazes). The task was to predict an image from a new camera pose.

Key Insights and Ideas

  • GNNs as a Computational Substrate: The paper reframes GNNs not just for relational data, but as a flexible computational engine that can learn to structure its own computation over continuous spaces.
  • Adaptive Meshing: Optimizing node positions and connectivity is a powerful way to focus computational effort on the most informative parts of a spatial domain, leading to efficiency and improved accuracy. This is analogous to how FEM meshes are refined in areas of high gradients.
  • Generalization Across Scales and Precision: The ability to reuse learned GNN weights across different mesh configurations (varying node density) allows GENs to generalize to different spatial scales and trade computation for accuracy at test time.
  • Bridging FEM and Deep Learning: GENs draw inspiration from FEMs, offering a data-driven approach to problems traditionally solved with numerical methods, but with the added benefit of learning and adaptation.
  • Handling "No A Priori Structure": GENs are particularly well-suited for problems where entities or explicit graph structures are not readily apparent, such as continuous physical fields.

Key Results

  • PDEs: GENs achieved competitive or superior results compared to baselines (including Neural Processes) on modeling heat diffusion on squares and spheres, often with significantly fewer nodes and faster inference. For the Poisson equation, a 4x4 GEN mesh already outperformed a baseline, and denser meshes continued to improve accuracy.
  • Robotics: In the Omnipush task, GENs significantly outperformed a modular meta-learning method and a Neural Process baseline in predicting object movement, achieving a mean squared prediction error of 0.045 ± 0.002 compared to 0.062 and 0.078 ± 0.006 respectively.
  • Scene Representation: GENs achieved comparable classification accuracy to Neural Processes but learned significantly faster (half the epochs). Crucially, GENs demonstrated superior generalization to larger "supermazes" (concatenated original mazes) than Neural Processes, maintaining performance as the problem size increased.

Limitations and Future Work

  • Computational Instability: The authors note that increasing the number of propagation steps and graph size quadratically can sometimes lead to unstable propagation, especially when generalizing to much larger meshes than seen during training. This is identified as an interesting area for future work.
  • Optimization of Connectivity: While node positions are optimized via gradient descent, changing connectivity is non-smooth. The authors explored this but found no significant benefit from smoothing, suggesting further research into more sophisticated optimization of graph topology.
  • Discrete Node Optimization: The paper mentions the possibility of combining gradient descent with discrete search steps to add or remove nodes, allowing the network to grow to an appropriate size for a problem instance, but this was not experimentally explored.
  • Generalization to Unseen Mesh Configurations: While GENs generalize well to different mesh sizes, performance can degrade on significantly larger meshes than those seen during training (as shown in Figure 7).
  • Computational Cost: While GENs can trade computation for accuracy, the computational cost can still increase significantly with larger meshes and more propagation steps.

Summary updated

BibTeX
@inproceedings{alet2019graph,
  author = {Ferran Alet and Adarsh K. Jeewajee and Maria Bauzá and Alberto Rodriguez and Tomás Lozano-Pérez and Leslie Pack Kaelbling},
  title = {{Graph Element Networks: adaptive, structured computation and memory}},
  booktitle = {International Conference on Machine Learning},
  year = {2019},
  url = {https://openreview.net/forum?id=n7lK8NLHQ9M},
}
Figure