SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2302.02941 · ICML · 2023

On Over-Squashing in Message Passing Neural Networks: The Impact of Width, Depth, and Topology

Michael Bronstein, Pietro Liò, Giulia Luise, Francesco Giovanni, Francesco Di, Federico Barbero, Lorenzo Giusti

arXiv · PDF · Open in the Atlas

Code that ran

6 of 6 samples (functions and classes) lifted from this paper's linked repositories executed on a synthesized input in Syntology's jail (0 of them constructed an object rather than computing a result; 0 honoured the contract we drafted, 0 violated it and 4 have no contract verdict; 2 failures of our instrument; 0 no recorded run), measured 2026-11-24; repository links from the Papers with Code archive attributed under CC BY-SA, no affiliation; bodies inline only under a permissive licence as GitHub detects it. Not a reproduction of the paper's results.

"Ran" means the function executed on a synthesized input and returned a value. It is not a reproduction of the paper's results. This record, dated, as JSON: /api/ran/2302.02941.json · badge: /api/ran/2302.02941.svg

Each repository's role is a label: a classifier's output recorded on the link, or, where no role is recorded, what the Papers with Code archive marked. The line under it names its basis. Neither says who wrote the code.

RepositoryRoleRan
lrnzgiusti/on-oversquashing canonical (classifier label)
classifier basis not recorded on the link
6 ran · 0 no recorded run
FunctionStatusWhere it lives
build_model Ran
ran on a synthesized input
lrnzgiusti/on-oversquashing/utils/factory.py
code served (permissive licence) · get_code("d2c64d908a1f0afb")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned GIN. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import torch.nn as nn
from argparse import Namespace

torch.manual_seed(0)

ARGS = {
    'args': Namespace(
        model='gin',
        input_dim=8,
        hidden_dim=16,
        output_dim=4,
        mpnn_layers=3,
        norm='batch_norm'
    )
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch, torch_geometric — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type GIN — a GIN output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a GIN output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
coo2tensor Ran
ran on a synthesized input
lrnzgiusti/on-oversquashing/utils/utils.py
code served (permissive licence) · get_code("f5b07715ddf4e242")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned Tensor. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import numpy as np
import scipy.sparse as sp

torch.manual_seed(0)

# Create a small COO sparse matrix
# The function expects a scipy.sparse COO matrix
rows = np.array([0, 1, 2, 1], dtype=np.int32)
cols = np.array([0, 1, 2, 2], dtype=np.int32)
data = np.array([1.0, 2.0, 3.0, 4.0], dtype=np.float32)

# Construct COO matrix with shape 4x3
A = sp.coo_matrix((data, (rows, cols)), shape=(4, 3))

ARGS = {
    "A": A
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, scipy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, shape (4, 3) — shape (4, 3) as a later run recorded it
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
get_graph_from_adj Ran
ran on a synthesized input
lrnzgiusti/on-oversquashing/effective_resistance_plot.py
code served (permissive licence) · get_code("fbdd5a42469fdc7c")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned Graph. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import networkx as nx
import numpy as np

# Create a small adjacency matrix
# This is a 4x4 matrix representing a simple graph
adjacency_matrix = np.array([
    [0, 1, 0, 1],
    [1, 0, 1, 0],
    [0, 1, 0, 1],
    [1, 0, 1, 0]
], dtype=int)

ARGS = {
    "adjacency_matrix": adjacency_matrix
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
networkx, numpy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Graph — a Graph output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a Graph output the recorded ndim 1 and dtype family int describe that coercion, not the output, and are not stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
normalize_adj Ran
ran; our contract draft was wrong, not the code
lrnzgiusti/on-oversquashing/utils/utils.py
pointer only (licence: MIT); the stored copy get_code serves, from songw-sw/x-fnc, is pointer only (licence: NONE) · get_code("21b0199200507ff0")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (MIT), but get_code serves the stored copy, first harvested from songw-sw/x-fnc, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

sparse_to_tuple Ran
ran; our contract draft was wrong, not the code
lrnzgiusti/on-oversquashing/utils/utils.py
code served (permissive licence) · get_code("eaa82e9c7a22e930")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned tuple. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import numpy as np
import scipy.sparse as sp

# Create a small sparse matrix
row = np.array([0, 1, 2, 3])
col = np.array([1, 2, 0, 3])
data = np.array([1.0, 2.0, 3.0, 4.0])
sparse_matrix = sp.coo_matrix((data, (row, col)), shape=(4, 4))

# Test with single sparse matrix
ARGS = {
    "sparse_mx": sparse_matrix
}

# Also test with a list of sparse matrices to verify the list branch
sparse_matrix_2 = sp.csr_matrix(([5.0, 6.0], ([0, 1], [1, 2])), shape=(3, 4))
sparse_matrix_3 = sp.lil_matrix((2, 5))
sparse_matrix_3[0, 1] = 7.0
sparse_matrix_3[1, 3] = 8.0

ARGS_list = {
    "sparse_mx": [sparse_matrix, sparse_matrix_2, sparse_matrix_3]
}

# Use the single matrix version as default
ARGS = {
    "sparse_mx": sparse_matrix
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, scipy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple — a tuple output has no array shape of its own; none is stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
str2bool Ran
ran on a synthesized input
lrnzgiusti/on-oversquashing/exp/parser.py
code served (permissive licence) · get_code("788ae6d601c05bf2")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned bool, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

from distutils.util import strtobool

def str2bool(x):
    if type(x) == bool:
        return x
    elif type(x) == str:
        return bool(strtobool(x))
    else:
        raise ValueError(f'Unrecognised type {type(x)}')

ARGS = {
    'x': 'true'
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
distutils — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type bool, ndim 0, dtype family float, shape () — shape () as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block

Also present in other papers' code

Of 6 samples lifted from this paper's linked repositories, 6 carry a function identity and 0 do not. Of the 6 distinct functions with an identity, 3 are also present in other papers whose code we hold (3 with at least one paper dated earlier, 0 the same month, 2 later) and 3 are only here among the 52,977 papers whose code Syntology holds (as of 2026-09-26).

Only here means: among the 52,977 papers whose code Syntology holds (51,887 with lifted samples, 1,090 through their assemblies only), as of 2026-09-26, no other paper's lifted samples or current assembly bricks contain an identical function body after normalisation.

FunctionAlso present inEarliest-datedOthers named
normalize_adj 14 other papers
10 dated earlier, 4 later
1812.00971 (2018-12)
Learning to Learn How to Learn: Self-Adaptive Visual Navigation Using Meta-Learning
2003.06749 (2020-03)
Learning hierarchical relationships for object-goal navigation
2104.09807 (2021-04)
Visual Navigation with Spatial Attention
and 11 more not named here
sparse_to_tuple 7 other papers
4 dated earlier, 3 later
1903.04154 (2019-03)
Fisher-Bures Adversary Graph Convolutional Networks
aaai_20388 (2022 (year only))
RepBin: Constraint-Based Graph Representation Learning for Metagenomic Binning
ijcai2022_0310 (2022 (year only))
Beyond Homophily: Structure-aware Path Aggregation Graph Neural Network
and 4 more not named here
coo2tensor 1 other paper
1 dated earlier
2010.03633 (2020-10)
Simplicial Neural Networks

Presence, not direction: an identical function body in two papers' repositories does not say who wrote it, which came from which, or that either paper's method rests on it. Matching is exact after normalisation, so a renamed or edited function is not matched. Dates are when papers appeared, not when code was written. Only .py files the harvester lifted are covered; notebooks are not read. A new-style arXiv id YYMM.NNNN dates a paper to the month 20YY-MM; otherwise Paper.year dates it to the year; otherwise it is undated. Dates are when the paper appeared, not when the code was written. Read 2026-11-24.

Repositories linked to this paper

Some links come from the archived Papers with Code dataset (CC BY-SA 4.0): attribution and licence.

Abstract

Message Passing Neural Networks (MPNNs) are instances of Graph Neural Networks that leverage the graph to send messages over the edges. This inductive bias leads to a phenomenon known as over-squashing, where a node feature is insensitive to information contained at distant nodes. Despite recent methods introduced to mitigate this issue, an understanding of the causes for oversquashing and of possible solutions are lacking. In this theoretical work, we prove that: (i) Neural network width can mitigate over-squashing, but at the cost of making the whole network more sensitive; (ii) Conversely, depth cannot help mitigate over-squashing: increasing the number of layers leads to over-squashing being dominated by vanishing gradients; (iii) The graph topology plays the greatest role, since over-squashing occurs between nodes at high commute time. Our analysis provides a unified framework to study different recent methods introduced to cope with over-squashing and serves as a justification for a class of methods that fall under graph rewiring.

For agents

The same record, over MCP at https://syntology.ai/mcp:

get_harvested_code_for_paper("2302.02941")
get_code_for_paper("2302.02941")
have("2302.02941")

The run record, dated, one paper per request, free:

curl https://syntology.ai/api/ran/2302.02941.json

A badge for a README (the split and the date, never a ratio):

[![Syntology run record](https://syntology.ai/api/ran/2302.02941.svg)](https://syntology.ai/paper/2302.02941)

Connect an agent — have() is free.