SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2109.06024 · 2021

Formalizing and Estimating Distribution Inference Risks

arXiv · PDF · Open in the Atlas

Code that ran

13 of 14 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 10 have no contract verdict; 3 failures of our instrument; 1 no recorded run), 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/2109.06024.json · badge: /api/ran/2109.06024.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
iamgroot42/form_est_dist_risks canonical (classifier label)
classifier basis: census
10 ran · 1 no recorded run
iamgroot42/formestdistrisks canonical (classifier label)
classifier basis: classifier_2025
3 ran · 0 no recorded run
FunctionStatusWhere it lives
chord Ran
ran on a synthesized input
iamgroot42/form_est_dist_risks/botnets/data_utils.py
code served (permissive licence) · get_code("02d577039741f33c")
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 ndarray, ndim 2, dtype family int, shape (8, 2) 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 random
import numpy as np

# Set seed for reproducibility
random.seed(0)
np.random.seed(0)

ARGS = {
    "num_node": 10,
    "num_edge": 8,
    "interval": 3
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type ndarray, ndim 2, dtype family int, shape (8, 2) — shape (8, 2) 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
epoch Ran
ran on a synthesized input
iamgroot42/form_est_dist_risks/botnets/model_utils.py
code served (permissive licence) · get_code("af78cce3251607a4")
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 1, dtype family float; no output shape is stated. The image it ran in was not recorded. The code mentions cuda, and the harness aliases cuda to the CPU for every sample; whether this run needed that is 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 torch.nn as nn

torch.manual_seed(0)

# Create a minimal model that takes a batch and returns logits
class MinimalModel(nn.Module):
    def __init__(self):
        super().__init__()
        self.linear = nn.Linear(4, 2)
    
    def forward(self, batch):
        # The function expects model(batch) to return logits
        # batch has ndata['y'] attribute, so it's a graph batch object
        # We'll just return dummy logits of shape [batch_size, 2]
        return self.linear(batch.x)

# Create a minimal batch class that mimics DGL graph batch
class MinimalBatch:
    def __init__(self, batch_size, num_features=4):
        self.batch_size = batch_size
        # ndata is a dict with 'y' containing labels
        self.ndata = {'y': torch.randint(0, 2, (batch_size,))}
        # x contains node features for the model
        self.x = torch.randn(batch_size, num_features)

# Create a data loader (list of batches)
loader = [
    MinimalBatch(batch_size=2, num_features=4),
    MinimalBatch(batch_size=2, num_features=4),
]

# Create model and optimizer
model = MinimalModel()
optimizer = torch.optim.SGD(model.parameters(), lr=0.01)

ARGS = {
    'model': model,
    'loader': loader,
    'gpu': False,
    'optimizer': optimizer,
    'verbose': False,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch, tqdm — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple, ndim 1, 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
find_to_prune_for_mean_degree Ran
ran; our contract draft was wrong, not the code
iamgroot42/formestdistrisks/arxiv/data_utils.py
code served (permissive licence) · get_code("6eff479cbea3e29a")
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 int; 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

class MockGraph:
    def __init__(self, num_nodes=6):
        # Create a simple graph with edges
        # L contains source node indices, R contains target node indices
        self.L = torch.tensor([0, 0, 1, 1, 2, 3, 4, 5], dtype=torch.long)
        self.R = torch.tensor([1, 2, 2, 3, 4, 4, 5, 0], dtype=torch.long)
    
    def edges(self):
        return self.L, self.R

torch.manual_seed(0)

g = MockGraph(num_nodes=6)

# Create degree array - one degree value per node
# Degrees should be integer values or np.nan
degs = np.array([2, 3, 2, 2, 2, 1], dtype=np.float32)

# Target mean degree to prune down to or up to
wanted_deg = 1.5

# Optional pre-pruning list (nodes to remove before main loop)
pre_prune = []

ARGS = {
    "g": g,
    "degs": degs,
    "wanted_deg": wanted_deg,
    "pre_prune": pre_prune
}
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 int — 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
find_to_prune_for_threshold_degree Ran
ran; our contract draft was wrong, not the code
iamgroot42/formestdistrisks/arxiv/data_utils.py
code served (permissive licence) · get_code("f40e50279ebbef17")
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 int; 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

# Create a small graph object that has edges() method
class SimpleGraph:
    def __init__(self, edges_left, edges_right):
        self.edges_left = edges_left
        self.edges_right = edges_right
    
    def edges(self):
        return self.edges_left, self.edges_right

# Create a small graph with 5 nodes
# Edge list: (source, target)
torch.manual_seed(0)

# Create edges as tensors on CPU
# Let's have edges pointing to various neighbors
edges_left = torch.tensor([0, 1, 2, 0, 1, 3], dtype=torch.long)  # source nodes
edges_right = torch.tensor([1, 2, 3, 4, 4, 2], dtype=torch.long)  # target nodes

g = SimpleGraph(edges_left, edges_right)

# Create degree array with 5 nodes
# Initialize with some degrees
degs = np.array([2, 3, 2, 1, 2], dtype=np.int64)

# Set threshold degree to prune nodes with degree >= 2
threshold_degree = 2

# Optional pre-prune list (can be empty or contain node indices to prune first)
pre_prune = []

ARGS = {
    'g': g,
    'degs': degs,
    'threshold_degree': threshold_degree,
    'pre_prune': pre_prune
}
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 int — 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_metrics Ran
ran on a synthesized input
iamgroot42/form_est_dist_risks/botnets/model_utils.py
code served (permissive licence) · get_code("1aae7e9452a19897")
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 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 as ch

ch.manual_seed(0)

# Construct valid arguments for get_metrics
# y: target labels (binary), shape [batch_size]
# y_pred: predicted probabilities, shape [batch_size]
# threshold: threshold for converting probabilities to binary predictions

y = ch.tensor([0.0, 1.0, 1.0, 0.0])
y_pred = ch.tensor([0.1, 0.8, 0.9, 0.3])
threshold = 0.5

ARGS = {
    "y": y,
    "y_pred": y_pred,
    "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 tuple, ndim 1, 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_model_folder_path Ran
ran on a synthesized input
iamgroot42/form_est_dist_risks/boneage/model_utils.py
code served (permissive licence) · get_code("a185c02cd89bef2e")
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 str. 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 os
import tempfile

# Create a temporary directory to use as BASE_MODELS_DIR
BASE_MODELS_DIR = tempfile.mkdtemp()

# Define ARGS with all parameters for get_model_folder_path
ARGS = {
    'split': 'train',
    'ratio': '0.8',
    'full_model': False
}
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 str — a str output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a str 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
load_all_loader_data Ran
ran on a synthesized input
iamgroot42/form_est_dist_risks/botnets/utils.py
code served (permissive licence) · get_code("744d18d79255848c")
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 as ch

ch.manual_seed(0)

# Create a simple data loader as a list of (image, label) tuples
# The function iterates over data_loader and unpacks (image, label) pairs,
# then concatenates them with ch.cat()

# Create small tensors: batch size 2, distinct dimensions for images vs labels
images_batch_1 = ch.randn(2, 3, 4, 5)  # 2 images, 3 channels, 4x5 spatial dims
labels_batch_1 = ch.randint(0, 10, (2,))  # 2 labels

images_batch_2 = ch.randn(2, 3, 4, 5)
labels_batch_2 = ch.randint(0, 10, (2,))

# Create data loader as an iterable of (image, label) tuples
data_loader = [
    (images_batch_1, labels_batch_1),
    (images_batch_2, labels_batch_2),
]

ARGS = {
    'data_loader': data_loader,
}
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 — 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
log_string Ran
ran on a synthesized input
iamgroot42/form_est_dist_risks/botnets/utils.py
code served (permissive licence) · get_code("ca00012e2a738b06")
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 str. 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 colorama import Fore, Style

# The function takes two parameters:
# - x: a string to be colored and logged
# - ttype: a string indicating the type ('train', 'val', or other)

ARGS = {
    'x': 'This is a test log message',
    'ttype': 'train'
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
colorama, numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type str — a str output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a str 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
neighbor_removal Ran
ran; our contract draft was wrong, not the code
iamgroot42/formestdistrisks/arxiv/data_utils.py
code served (permissive licence) · get_code("aff1bea8d51561a3")
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 ndarray, ndim 1, dtype family int, shape (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
import numpy as np

torch.manual_seed(0)

# Create a mock graph object with edges() method
class MockGraph:
    def __init__(self, L, R):
        self._L = L
        self._R = R
    
    def edges(self):
        return self._L, self._R

# Create edge indices
# L contains source node indices, R contains target node indices
L = torch.tensor([0, 1, 2, 0, 1], dtype=torch.long)
R = torch.tensor([1, 2, 3, 3, 0], dtype=torch.long)

g = MockGraph(L, R)

# pick is the node index to pick neighbors for
pick = 0

# degs is a degree array for nodes
# We need at least 4 nodes (indices 0-3) based on the edge indices above
degs = np.array([2, 2, 1, 2], dtype=np.int64)

# inf_val is a special value to mark infinite degrees
inf_val = -1

ARGS = {
    "g": g,
    "pick": pick,
    "degs": degs,
    "inf_val": inf_val
}
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 ndarray, ndim 1, dtype family int, shape (4,) — shape (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
overlay_botnet_on_graph Ran
ran on a synthesized input
iamgroot42/form_est_dist_risks/botnets/data_utils.py
code served (permissive licence) · get_code("0e10610f727fef31")
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 random
import numpy as np
import networkx as nx

# Create a small graph with enough nodes
graph = nx.Graph()
graph.add_nodes_from(range(10))
graph.add_edges_from([(0, 1), (1, 2), (2, 3)])

# Create botnet edges as a list of tuples
# These represent connections between nodes that will be remapped
botnet_edges = [(0, 1), (1, 2), (2, 0)]

ARGS = {
    "graph": graph,
    "botnet_edges": botnet_edges,
}
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 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
scaled_values Ran
ran on a synthesized input
iamgroot42/form_est_dist_risks/botnets/utils.py
code served (permissive licence) · get_code("0d35d1ccf120ef81")
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 ndarray, ndim 2, dtype family float, shape (4, 3) 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 numpy as np

# Analyze the function:
# - val: numpy array with shape (D, N) where D is dimension and N is number of samples
# - mean: numpy array with shape (D,) - will be expanded to (D, 1) then repeated to (D, N)
# - std: numpy array with shape (D,) - will be expanded to (D, 1)
# - eps: scalar (default 1e-10)

# Create small test data
# Using distinct dimensions: 4 features, 3 samples
val = np.random.randn(4, 3).astype(np.float32)
mean = np.random.randn(4).astype(np.float32)
std = np.abs(np.random.randn(4)).astype(np.float32) + 0.1  # ensure positive

ARGS = {
    "val": val,
    "mean": mean,
    "std": std,
    "eps": 1e-10
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type ndarray, ndim 2, dtype family float, shape (4, 3) — shape (4, 3) 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
test Ran
ran on a synthesized input
iamgroot42/form_est_dist_risks/arxiv/model_utils.py
code served (permissive licence) · get_code("402b17de9d91f42e")
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 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 as ch
import torch.nn as nn

ch.manual_seed(0)

# Define a simple model that takes input and produces logits
class SimpleModel(nn.Module):
    def __init__(self, input_dim, num_classes):
        super().__init__()
        self.linear = nn.Linear(input_dim, num_classes)
    
    def forward(self, x):
        return self.linear(x)

# Define a simple dataset class with get_features and get_labels methods
class SimpleDataset:
    def __init__(self, num_samples, num_features, num_classes):
        self.X = ch.randn(num_samples, num_features)
        self.Y = ch.randint(0, num_classes, (num_samples, 1))
    
    def get_features(self):
        return self.X
    
    def get_labels(self):
        return self.Y

# Define a simple evaluator with eval method
class SimpleEvaluator:
    def eval(self, data_dict):
        y_true = data_dict['y_true']
        y_pred = data_dict['y_pred']
        # Simple accuracy calculation
        correct = (y_true == y_pred).float().mean()
        return {'acc': correct.item()}

# Create instances
model = SimpleModel(input_dim=4, num_classes=3)
ds = SimpleDataset(num_samples=2, num_features=4, num_classes=3)
train_idx = ch.tensor([0])
test_idx = ch.tensor([1])
evaluator = SimpleEvaluator()

ARGS = {
    'model': model,
    'ds': ds,
    'train_idx': train_idx,
    'test_idx': test_idx,
    'evaluator': evaluator
}
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 1, 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
true_positive Ran
ran on a synthesized input
iamgroot42/form_est_dist_risks/botnets/model_utils.py
code served (permissive licence) · get_code("439ee18af6ad4263")
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 int, ndim 0, dtype family int, 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 torch

torch.manual_seed(0)

# The function expects:
# - pred: a tensor that can be indexed with == 1 and used as a boolean index
# - target: a tensor that can be indexed with the result of pred == 1, and compared with == 1

pred = torch.tensor([0, 1, 1, 0])
target = torch.tensor([0, 1, 1, 0])

ARGS = {
    "pred": pred,
    "target": target,
}
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 int, ndim 0, dtype family int, 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
train Not yet run
unverified (harvested, no recorded run)
iamgroot42/form_est_dist_risks/arxiv/model_utils.py
code served (permissive licence) · get_code("5e91ee8bb1615456")
How it ran

no invocation recorded.

Also present in other papers' code

Of 14 samples lifted from this paper's linked repositories, 14 carry a function identity and 0 do not. Of the 14 distinct functions with an identity, 7 are also present in other papers whose code we hold (7 with at least one paper dated earlier, 0 the same month, 0 later) and 7 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
find_to_prune_for_mean_degree 1 other paper
1 dated earlier
2106.03699 (2021-06)
Formalizing Distribution Inference Risks
find_to_prune_for_threshold_degree 1 other paper
1 dated earlier
2106.03699 (2021-06)
Formalizing Distribution Inference Risks
load_all_loader_data 1 other paper
1 dated earlier
2106.03699 (2021-06)
Formalizing Distribution Inference Risks
neighbor_removal 1 other paper
1 dated earlier
2106.03699 (2021-06)
Formalizing Distribution Inference Risks
scaled_values 1 other paper
1 dated earlier
2106.03699 (2021-06)
Formalizing Distribution Inference Risks
test 1 other paper
1 dated earlier
2106.03699 (2021-06)
Formalizing Distribution Inference Risks
train 1 other paper
1 dated earlier
2106.03699 (2021-06)
Formalizing Distribution Inference Risks

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

Distribution inference, sometimes called property inference, infers statistical properties about a training set from access to a model trained on that data. Distribution inference attacks can pose serious risks when models are trained on private data, but are difficult to distinguish from the intrinsic purpose of statistical machine learning -- namely, to produce models that capture statistical properties about a distribution. Motivated by Yeom et al.'s membership inference framework, we propose a formal definition of distribution inference attacks that is general enough to describe a broad class of attacks distinguishing between possible training distributions. We show how our definition captures previous ratio-based property inference attacks as well as new kinds of attack including revealing the average node degree or clustering coefficient of a training graph. To understand distribution inference risks, we introduce a metric that quantifies observed leakage by relating it to the leakage that would occur if samples from the training distribution were provided directly to the adversary. We report on a series of experiments across a range of different distributions using both novel black-box attacks and improved versions of the state-of-the-art white-box attacks. Our results show that inexpensive attacks are often as effective as expensive meta-classifier attacks, and that there are surprising asymmetries in the effectiveness of attacks. Code is available at https://github.com/iamgroot42/FormEstDistRisks

For agents

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

get_harvested_code_for_paper("2109.06024")
get_code_for_paper("2109.06024")
have("2109.06024")

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

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

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

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

Connect an agent — have() is free.