SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2309.13944 · NeurIPS · 2023

Provable Training for Graph Contrastive Learning

Yue Yu, Xiao Wang, Chuan Shi, Nian Liu, Mengmei Zhang

arXiv · PDF · Open in the Atlas

Code that ran

10 of 11 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, 1 violated it and 0 have no contract verdict; 9 failures of our instrument; 1 no recorded run); 1 of them was also run on the host, not in the jail, by the peer-agreement lane that set its level, measured 2026-11-23; 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/2309.13944.json · badge: /api/ran/2309.13944.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
VoidHaruhi/POT-GCL canonical (classifier label)
classifier basis: census
10 ran · 1 no recorded run
FunctionStatusWhere it lives
weighted_mean Ran
ran; our contract draft was wrong, not the code
VoidHaruhi/POT-GCL/ProGCL/pGRACE/model.py
pointer only (licence: MIT); the stored copy get_code serves, from junxia97/ProGCL, is pointer only (licence: NONE) · get_code("2dff6e858d437842")
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 junxia97/ProGCL, 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.

Ztrans Ran
ran; our contract draft was wrong, not the code
VoidHaruhi/POT-GCL/COSTA/src/util/helper.py
code served (permissive licence) · get_code("c8bbf5537361b210")
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, ndim 2, dtype family float, shape (2, 4) 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 torch

torch.manual_seed(0)

# The function Ztrans takes a tensor x and performs z-score normalization
# It calls .mean(dim=0), .std(dim=0) on the tensor
# So we need a 2D tensor with batch dimension 0 and feature dimension 1

x = torch.randn(2, 4)  # batch_size=2, num_features=4

ARGS = {
    "x": x
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 2, dtype family float, shape (2, 4) — shape (2, 4) 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
drop_feature Ran
ran; our contract draft was wrong, not the code
VoidHaruhi/POT-GCL/GRACE/model.py
pointer only (licence: MIT); the stored copy get_code serves, from HKUDS/GraphST, is pointer only (licence: NONE) · get_code("22bfb6129463d322")
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 HKUDS/GraphST, 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.

drop_feature_weighted Ran
ran; our contract draft was wrong, not the code
VoidHaruhi/POT-GCL/GCA/pGRACE/functional.py
pointer only (licence: MIT); the stored copy get_code serves, from junxia97/ProGCL, is pointer only (licence: NONE) · get_code("867c9382144672b7")
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 junxia97/ProGCL, 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.

drop_feature_weighted_2 Ran
ran; our contract draft was wrong, not the code
VoidHaruhi/POT-GCL/GCA/pGRACE/functional.py
code served (permissive licence) · get_code("2694bcf35c3d7b93")
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, ndim 2, dtype family float, shape (2, 4) 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 torch

torch.manual_seed(0)

# x: tensor with shape (batch_size, num_features)
# Should be float tensor for arithmetic operations
x = torch.randn(2, 4)

# w: weight tensor that will be normalized and thresholded
# Should have same number of features as x's second dimension
w = torch.randn(4).abs() + 0.1  # ensure positive values for bernoulli

# p: drop probability scaling factor (float between 0 and 1)
p = 0.5

# threshold: maximum drop probability allowed (float)
threshold = 0.7

ARGS = {
    "x": x,
    "w": w,
    "p": p,
    "threshold": threshold,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 2, dtype family float, shape (2, 4) — shape (2, 4) 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
fit_beta_weighted Ran
ran; our contract draft was wrong, not the code
VoidHaruhi/POT-GCL/ProGCL/pGRACE/model.py
pointer only (licence: MIT); the stored copy get_code serves, from junxia97/ProGCL, is pointer only (licence: NONE) · get_code("300e84c6b99cb7f4")
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 junxia97/ProGCL, 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.

generate_split Ran
ran, violated the contract we drafted
VoidHaruhi/POT-GCL/GRACE/my_utils.py
code served (permissive licence) · get_code("b6b75b8c990299ac")
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, ndim 2, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim 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
from torch.utils.data import random_split

torch.manual_seed(0)

ARGS = {
    "num_samples": 10,
    "train_ratio": 0.6,
    "val_ratio": 0.2,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple, ndim 2, dtype family float — a tuple output has no array shape of its own; none is stated
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
get_alpha_beta Ran
ran; our contract draft was wrong, not the code
VoidHaruhi/POT-GCL/GRACE/my_utils.py
code served (permissive licence) · get_code("3b63e93e7a542afb")
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, ndim 3, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim 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

torch.manual_seed(0)

# Construct small tensors for l, u, and alpha
# l and u should have the same shape and contain bounds
# alpha is a scalar parameter
l = torch.tensor([[-1.0, 0.5, -2.0, 1.0],
                   [0.0, -0.5, 2.0, -1.5]], dtype=torch.float32)

u = torch.tensor([[1.0, 2.0, 1.0, 3.0],
                   [2.0, 1.0, 4.0, 0.5]], dtype=torch.float32)

alpha = 0.1

ARGS = {
    "l": l,
    "u": u,
    "alpha": alpha,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple, ndim 3, dtype family float — a tuple output has no array shape of its own; none is stated
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
get_batch Ran
ran; our contract draft was wrong, not the code
VoidHaruhi/POT-GCL/COSTA/src/model/utils.py
code served (permissive licence) · get_code("06aaec706bf52e17")
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 list, ndim 1, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim 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

torch.manual_seed(0)

# Construct node_list - the function uses len() and slicing operations
# Nodes can be any objects; here we'll use simple integers or small dicts as stand-ins
node_list = [
    {"id": 0, "data": "node_0"},
    {"id": 1, "data": "node_1"},
    {"id": 2, "data": "node_2"},
    {"id": 3, "data": "node_3"},
    {"id": 4, "data": "node_4"},
    {"id": 5, "data": "node_5"},
]

batch_size = 2
epoch = 1

ARGS = {
    "node_list": node_list,
    "batch_size": batch_size,
    "epoch": epoch,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type list, ndim 1, dtype family float — a list output has no array shape of its own; none is stated
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
get_path Ran
ran; our contract draft was wrong, not the code
VoidHaruhi/POT-GCL/GCA/pGRACE/dataset.py
pointer only (licence: MIT); the stored copy get_code serves, from somebodyhh1/GRACEIS, is pointer only (licence: NONE) · get_code("5b18ad957d4c29e1")
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 somebodyhh1/GRACEIS, 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.

get_crown_weights Not yet run
unverified (harvested, no recorded run)
VoidHaruhi/POT-GCL/COSTA/src/model/utils.py
code served (permissive licence) · get_code("ec9355b99f54bc56")
How it ran

no invocation recorded.

Also present in other papers' code

Of 11 samples lifted from this paper's linked repositories, 11 carry a function identity and 0 do not. Of the 11 distinct functions with an identity, 6 are also present in other papers whose code we hold (3 with at least one paper dated earlier, 0 the same month, 5 later) and 5 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
drop_feature 7 other papers
3 dated earlier, 4 later
2006.04131 (2020-06)
Deep Graph Contrastive Representation Learning
2110.14038 (2021-10)
Robustness of Graph Neural Networks at Scale
2306.10683 (2023-06)
Spatial-Temporal Graph Learning with Adversarial Contrastive Adaptation
and 4 more not named here
fit_beta_weighted 3 other papers
2 dated earlier, 1 later · 1 only as an assembly brick
2110.02027 (2021-10)
ProGCL: Rethinking Hard Negative Mining in Graph Contrastive Learning
2206.07551 (2022-06)
Unknown-Aware Domain Adversarial Learning for Open-Set Domain Adaptation
2310.05424 (2023-10)
Fast and Robust Early-Exiting Framework for Autoregressive Language Models with Synchronized Parallel Decoding
drop_feature_weighted 1 other paper
1 later
2606.10284 (2026-06)
Revisiting Positive Samples in Graph Contrastive Learning: From the Perspective of Message Passing
drop_feature_weighted_2 1 other paper
1 later
2606.10284 (2026-06)
Revisiting Positive Samples in Graph Contrastive Learning: From the Perspective of Message Passing
get_path 1 other paper
1 later
2310.03977 (2023-10)
Perfect Alignment May be Poisonous to Graph Contrastive Learning
weighted_mean 1 other paper
1 dated earlier
2110.02027 (2021-10)
ProGCL: Rethinking Hard Negative Mining in Graph Contrastive Learning

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

Repositories linked to this paper

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

Abstract

Graph Contrastive Learning (GCL) has emerged as a popular training approach for learning node embeddings from augmented graphs without labels. Despite the key principle that maximizing the similarity between positive node pairs while minimizing it between negative node pairs is well established, some fundamental problems are still unclear. Considering the complex graph structure, are some nodes consistently well-trained and following this principle even with different graph augmentations? Or are there some nodes more likely to be untrained across graph augmentations and violate the principle? How to distinguish these nodes and further guide the training of GCL? To answer these questions, we first present experimental evidence showing that the training of GCL is indeed imbalanced across all nodes. To address this problem, we propose the metric "node compactness", which is the lower bound of how a node follows the GCL principle related to the range of augmentations. We further derive the form of node compactness theoretically through bound propagation, which can be integrated into binary cross-entropy as a regularization. To this end, we propose the PrOvable Training (POT 1 ) for GCL, which regularizes the training of GCL to encode node embeddings that follows the GCL principle better. Through extensive experiments on various benchmarks, POT consistently improves the existing GCL approaches, serving as a friendly plugin.

For agents

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

get_harvested_code_for_paper("2309.13944")
get_code_for_paper("2309.13944")
have("2309.13944")

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

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

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

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

Connect an agent — have() is free.