SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2311.02142 · 2023

Sparse Training of Discrete Diffusion Models for Graph Generation

arXiv · PDF · Open in the Atlas

Code that ran

6 of 7 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; 1 honoured the contract we drafted, 1 violated it and 0 have no contract verdict; 4 failures of our instrument; 1 no recorded run), measured 2026-11-22; 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/2311.02142.json · badge: /api/ran/2311.02142.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
qym7/sparsediff canonical (classifier label)
classifier basis: census
6 ran · 1 no recorded run
FunctionStatusWhere it lives
compare_hash Ran
ran, violated the contract we drafted
qym7/sparsediff/sparse_diffusion/datasets/guacamol_dataset.py
code served (permissive licence) · get_code("ab10f4ba7e15c9c9")
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.

import hashlib
import tempfile
import os

# Create a temporary file with known content
temp_dir = tempfile.mkdtemp()
output_file = os.path.join(temp_dir, "test_smiles.txt")

# Write some test content to the file
test_content = b"CCO\nCC(C)O\nc1ccccc1"
with open(output_file, 'wb') as f:
    f.write(test_content)

# Compute the correct hash of this content
correct_hash = hashlib.md5(test_content).hexdigest()

ARGS = {
    "output_file": output_file,
    "correct_hash": correct_hash
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
none outside the standard library — 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
l2 Ran
ran, honoured the contract we drafted
qym7/sparsediff/sparse_diffusion/analysis/dist_helper.py
pointer only (licence: MIT); the stored copy get_code serves, from lf-wen/hgdm, is pointer only (licence: NONE) · get_code("039fc6561a9516bc")
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 lf-wen/hgdm, 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.

load_pickle Ran
ran; our contract draft was wrong, not the code
qym7/sparsediff/sparse_diffusion/datasets/dataset_utils.py
code served (permissive licence) · get_code("70db7c9cbe9e680d")
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) and returned dict. 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 pickle
import tempfile
import os

# Create a temporary file with pickled data
temp_dir = tempfile.mkdtemp()
temp_path = os.path.join(temp_dir, "test.pkl")

# Create some sample data to pickle
sample_data = {
    "key1": "value1",
    "key2": [1, 2, 3],
    "key3": {"nested": "dict"}
}

# Write the pickled data to the temporary file
with open(temp_path, 'wb') as f:
    pickle.dump(sample_data, f)

ARGS = {
    "path": temp_path
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1
Imports
none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type dict — a dict output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a dict 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
setup_wandb Ran
ran; our contract draft was wrong, not the code
qym7/sparsediff/sparse_diffusion/utils.py
code served (permissive licence) · get_code("938ae36c029d92da")
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 DictConfig. 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
from omegaconf import OmegaConf

# Build a minimal config that satisfies setup_wandb's requirements
cfg_dict = {
    'dataset': {
        'name': 'qm9',
        'remove_h': False,
    },
    'general': {
        'name': 'test_experiment',
        'wandb': 'offline',  # Use offline mode to avoid actual wandb connection
    }
}

cfg = OmegaConf.create(cfg_dict)

ARGS = {
    'cfg': cfg
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, omegaconf, torch, wandb — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type DictConfig — a DictConfig output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a DictConfig output the recorded ndim 1 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
to_dense Ran
ran; our contract draft was wrong, not the code
qym7/sparsediff/sparse_diffusion/utils.py
code served (permissive licence) · get_code("fbba1d3a8b6cab5a")
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 torch
import torch.nn as nn

torch.manual_seed(0)

# Create small tensors for node features
# x: node features, shape (num_nodes, feature_dim)
x = torch.randn(8, 4)

# edge_index: shape (2, num_edges)
edge_index = torch.tensor([
    [0, 1, 2, 3, 4, 5, 6, 7],
    [1, 2, 3, 4, 5, 6, 7, 0]
], dtype=torch.long)

# edge_attr: edge features, shape (num_edges, edge_feature_dim)
edge_attr = torch.randn(8, 3)

# batch: which graph each node belongs to, shape (num_nodes,)
batch = torch.tensor([0, 0, 0, 0, 1, 1, 1, 1], dtype=torch.long)

# charge: node charges, shape (num_nodes, charge_dim)
charge = torch.randn(8, 2)

ARGS = {
    'x': x,
    'edge_index': edge_index,
    'edge_attr': edge_attr,
    'batch': batch,
    'charge': charge
}
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 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
to_dense_node Ran
ran; our contract draft was wrong, not the code
qym7/sparsediff/sparse_diffusion/utils.py
code served (permissive licence) · get_code("861782c3a73e36ba")
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 torch
import torch.nn as nn
from torch_geometric.utils import to_dense_batch

torch.manual_seed(0)

# Create node features tensor
# Shape: (num_nodes, feature_dim)
x = torch.randn(6, 4)

# Create batch assignment tensor
# This tells which graph each node belongs to
# 3 nodes in graph 0, 3 nodes in graph 1
batch = torch.tensor([0, 0, 0, 1, 1, 1])

ARGS = {
    "x": x,
    "batch": batch
}
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 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
remove_hydrogens Not yet run
unverified (harvested, no recorded run)
qym7/sparsediff/sparse_diffusion/datasets/dataset_utils.py
code served (permissive licence) · get_code("dc5bc1ae656e5ea3")
How it ran

no invocation recorded.

Also present in other papers' code

Of 7 samples lifted from this paper's linked repositories, 7 carry a function identity and 0 do not. Of the 7 distinct functions with an identity, 4 are also present in other papers whose code we hold (2 with at least one paper dated earlier, 0 the same month, 4 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
l2 10 other papers
4 dated earlier, 6 later
1910.00760 (2019-10)
Efficient Graph Generation with Graph Recurrent Attention Networks
2204.01613 (2022-04)
SPECTRE: Spectral Conditioning Helps to Overcome the Expressivity Limits of One-shot Graph Generators
2305.19337 (2023-05)
HiGen: Hierarchical Graph Generative Networks
and 7 more not named here
load_pickle 9 other papers
5 dated earlier, 4 later
1907.00456 (2019-07)
Way Off-Policy Batch Deep Reinforcement Learning of Implicit Human Preferences in Dialog
2005.03545 (2020-05)
MISA: Modality-Invariant and -Specific Representations for Multimodal Sentiment Analysis
and 6 more not named here
compare_hash 3 other papers
3 later
2312.17397 (2023-12)
Classifier-free graph diffusion for molecular property targeting
2410.04263 (2024-10)
DeFoG: Discrete Flow Matching for Graph Generation
2603.28572 (2026-03)
Unrestrained Simplex Denoising for Discrete Data A Non-Markovian Approach Applied to Graph Generation
remove_hydrogens 1 other paper
1 later
2410.04263 (2024-10)
DeFoG: Discrete Flow Matching for Graph Generation

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-22.

Repositories linked to this paper

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

Abstract

Generative graph models struggle to scale due to the need to predict the existence or type of edges between all node pairs. To address the resulting quadratic complexity, existing scalable models often impose restrictive assumptions such as a cluster structure within graphs, thus limiting their applicability. To address this, we introduce SparseDiff, a novel diffusion model based on the observation that almost all large graphs are sparse. By selecting a subset of edges, SparseDiff effectively leverages sparse graph representations both during the noising process and within the denoising network, which ensures that space complexity scales linearly with the number of chosen edges. During inference, SparseDiff progressively fills the adjacency matrix with the selected subsets of edges, mirroring the training process. Our model demonstrates state-of-the-art performance across multiple metrics on both small and large datasets, confirming its effectiveness and robustness across varying graph sizes. It also ensures faster convergence, particularly on larger graphs, achieving a fourfold speedup on the large Ego dataset compared to dense models, thereby paving the way for broader applications.

For agents

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

get_harvested_code_for_paper("2311.02142")
get_code_for_paper("2311.02142")
have("2311.02142")

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

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

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

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

Connect an agent — have() is free.