Graph-ViT-MLPMixer
A graph network that splits a graph into overlapping patches and mixes the patch tokens with MLP or attention layers.
Graphs and geometry · 275 operations Checked
Click or tap a spot to read it up close. Scroll or drag inside the diagram to move through it. Zoom with + and − or Ctrl and scroll. Press 0 for the whole graph. Swipe inside the diagram to move through it. Use + and − to zoom.
At a glance
- Task
- Graphs and geometry
- Parameters
- 476.9K
- Operations
- 275
- Framework
- PyTorch
- Recurrent
- No
- Published
- ICML 2023
- Cited by
- 21 (as of 24 October 2026)
- Authors
- Xiaoxin He, Bryan Hooi, Thomas Laurent and others
- License
- MIT
- Checked
- Passed: the trace was replayed operation by operation and matched the model's own output for this input.
Files
The file opened in a new tab. Use your browser's Save command there to keep it.
The diagram is a drawing of a TorchLens trace of the source code. It contains no code or weights.
Details
- Stable ID
- m17115
- Graph hash
- 8fc65cfc1c11b81cdb4a6783f2735d1c7d8921d58b7e7368f0df30cc2a9ad727
- Skeleton hash
- 22ddb9692de93d2df7078ce9ec4f0f9f0ab0bf9aa7200866755101ff1a379edc
- Architecture hash
- f310e55e76eda890aab5efffe4484f56fce5d02ffba625d5bb8f3799a9e36253
- Diagram SHA-256
- 7b701237f8a62b85e4373fbb1f9b0b0b53c9fc2860270f286036c14f057e68d7
- TorchLens version
- 2.36.0
- Renderer
- graphviz 2.43.0+pyvips 3.2.0+libvips 8.18.7+render-opts@06c1f0d3
- Check
- Forward pass replayed in PyTorch
What it is
Graph ViT/MLP-Mixer is a class of graph neural networks that brings the ViT and MLP-Mixer architectures from computer vision to graphs. The paper starts from two limitations of standard message-passing GNNs, over-squashing and poor long-range dependencies, which global attention can solve only at quadratic cost.
The graph is first partitioned into patches with METIS, a graph clustering algorithm. Each patch is then expanded to its one-hop neighborhood, so patches overlap and the links between them are preserved. A GNN acts as the patch encoder and turns each patch into a fixed-size representation. The resulting tokens pass through mixer layers, each a residual network that alternates a token mixer over all patches with a channel mixer applied to each patch independently; the token mixer is an MLP or graph-based multi-head attention (gMHA). A global average pooling layer followed by a fully-connected layer makes the prediction.
The paper states a complexity linear in the number of nodes and edges, and tests the architecture on 4 simulated datasets and 7 real-world benchmarks. The patches are small: the paper gives a mean of around 3.15 nodes per patch for molecular datasets and around 17.20 for image datasets.
Key idea. Graph ViT/MLP-Mixer splits a graph into overlapping patches, turns each patch into a token and mixes the tokens with MLP or attention layers.
- graph vit
- graph mlp-mixer
- graph vit/mlp-mixer
- graph-vit-mlpmixer
- graph patches
- metis graph partition
- long-range graph dependencies
- over-squashing
- graph classification
- graph regression
AI-written summary, based on the paper and checked automatically against it; not reviewed by a person. Corrections welcome.
Cite the paper
@misc{he2023generalizationvitmlpmixergraphs,
title={A Generalization of ViT/MLP-Mixer to Graphs},
author={Xiaoxin He and Bryan Hooi and Thomas Laurent and Adam Perold and Yann LeCun and Xavier Bresson},
year={2023},
eprint={2212.13350},
archivePrefix={arXiv},
primaryClass={cs.CV},
url={https://arxiv.org/abs/2212.13350},
}