SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2009.11094 · NeurIPS · 2020

Sanity-Checking Pruning Methods: Random Tickets can Win the Jackpot

Liwei Wang, Jason Lee, Tianle Cai, Jingtong Su, Yihang Chen, Tianhao Wu, Ruiqi Gao

arXiv · PDF · Open in the Atlas

Code that ran

4 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; 2 honoured the contract we drafted, 0 violated it and 1 has no contract verdict; 1 failure of our instrument; 3 no recorded run), measured 2026-11-22; 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/2009.11094.json · badge: /api/ran/2009.11094.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
Eric-mingjie/rethinking-network-pruning canonical (classifier label)
classifier basis: census
1 ran · 2 no recorded run
alecwangcq/GraSP community
Papers with Code archive
3 ran · 1 no recorded run
FunctionStatusWhere it lives
GraSP_fetch_data Ran
ran; our contract draft was wrong, not the code
alecwangcq/GraSP/pruner/GraSP.py
code served (permissive licence) · get_code("029647da91b3ee45")
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

torch.manual_seed(0)

# Create a small dataloader with batches of (inputs, targets)
# The function expects to iterate through it and collect samples per class
batch_size = 2
num_features = 4
num_classes = 3
samples_per_class = 2

# Create sample data: batches of (inputs, targets)
# We need enough batches to collect samples_per_class for each class
dataloader = []
sample_count = [0] * num_classes

# Generate batches until we have enough samples per class
for batch_idx in range(5):  # Create enough batches
    batch_inputs = torch.randn(batch_size, num_features)
    # Create targets cycling through classes
    batch_targets = torch.tensor([batch_idx % num_classes, (batch_idx + 1) % num_classes])
    dataloader.append((batch_inputs, batch_targets))

ARGS = {
    "dataloader": dataloader,
    "num_classes": num_classes,
    "samples_per_class": samples_per_class,
}
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
count_fc_parameters Ran
ran, honoured the contract we drafted
alecwangcq/GraSP/pruner/GraSP.py
code served (permissive licence) · get_code("dd41a92a0afa4fd7")
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
import torch.nn as nn

torch.manual_seed(0)

# Build a simple neural network with Linear layers
class SimpleNet(nn.Module):
    def __init__(self):
        super().__init__()
        self.fc1 = nn.Linear(4, 3)
        self.fc2 = nn.Linear(3, 2)
        self.conv1 = nn.Conv2d(1, 1, 3)  # non-Linear layer to test filtering
    
    def forward(self, x):
        x = self.fc1(x)
        x = self.fc2(x)
        return x

net = SimpleNet()

ARGS = {
    "net": net
}
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
count_total_parameters Ran
ran, honoured the contract we drafted
alecwangcq/GraSP/pruner/GraSP.py
code served (permissive licence) · get_code("155c0c245324ce36")
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
import torch.nn as nn

torch.manual_seed(0)

class SimpleNet(nn.Module):
    def __init__(self):
        super().__init__()
        self.linear1 = nn.Linear(4, 3)
        self.linear2 = nn.Linear(3, 2)
        self.conv1 = nn.Conv2d(2, 5, kernel_size=3)
    
    def forward(self, x):
        return x

net = SimpleNet()

ARGS = {
    'net': net
}
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
print_model_param_nums Ran
ran on a synthesized input
Eric-mingjie/rethinking-network-pruning/cifar/network-slimming/compute_flops.py
code served (permissive licence) · get_code("929c091d6fd3e526")
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; no output shape is stated. It ran in syntology-harvest-sandbox:v5-deps (sha256:6a292aa1aed1) at 2026-09-27T00:55:33Z. 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
import torchvision

torch.manual_seed(0)

# Create a minimal model with some parameters
class MinimalModel(nn.Module):
    def __init__(self):
        super().__init__()
        self.linear = nn.Linear(4, 3)
        self.conv = nn.Conv2d(3, 16, kernel_size=3)
    
    def forward(self, x):
        return x

model = MinimalModel()

ARGS = {
    'model': model
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch, torchvision — 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 — no output shape is stated: no later run recorded an output shape for this sample (observed_output and metamorphic_properties carry none; shape_contract and output_contract record ndim only)
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 syntology-harvest-sandbox:v5-deps (sha256:6a292aa1aed1); 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
GraSP Not yet run
unverified (harvested, no recorded run)
alecwangcq/GraSP/pruner/GraSP.py
code served (permissive licence) · get_code("bc77b97e85fefaa4")
How it ran

no invocation recorded.

count_model_param_flops Not yet run
unverified (harvested, no recorded run)
Eric-mingjie/rethinking-network-pruning/imagenet/l1-norm-pruning/compute_flops.py
code served (permissive licence) · get_code("6f215c4ac07fc796")
How it ran

no invocation recorded.

print_model_param_flops Not yet run
unverified (harvested, no recorded run)
Eric-mingjie/rethinking-network-pruning/cifar/network-slimming/compute_flops.py
code served (permissive licence) · get_code("dbcc7f02b0356238")
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 (4 with at least one paper dated earlier, 0 the same month, 1 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
count_fc_parameters
brick of this paper's assembly: helper
2 other papers
2 dated earlier · 2 only as an assembly brick
1803.03635 (2018-03)
The Lottery Ticket Hypothesis: Finding Sparse, Trainable Neural Networks
1810.02340 (2018-10)
SNIP: Single-shot Network Pruning based on Connection Sensitivity
count_total_parameters
brick of this paper's assembly: helper
2 other papers
2 dated earlier · 2 only as an assembly brick
1803.03635 (2018-03)
The Lottery Ticket Hypothesis: Finding Sparse, Trainable Neural Networks
1810.02340 (2018-10)
SNIP: Single-shot Network Pruning based on Connection Sensitivity
print_model_param_flops 2 other papers
1 dated earlier, 1 later
1909.11957 (2019-09)
Drawing Early-Bird Tickets: Towards More Efficient Training of Deep Networks
2010.01242 (2020-10)
Improving Network Slimming with Nonconvex Regularization
print_model_param_nums 1 other paper
1 dated earlier
1909.11957 (2019-09)
Drawing Early-Bird Tickets: Towards More Efficient Training of Deep 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-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

Network pruning is a method for reducing test-time computational resource requirements with minimal performance degradation. Conventional wisdom of pruning algorithms suggests that: (1) Pruning methods exploit information from training data to find good subnetworks; (2) The architecture of the pruned network is crucial for good performance. In this paper, we conduct sanity checks for the above beliefs on several recent unstructured pruning methods and surprisingly find that: (1) A set of methods which aims to find good subnetworks of the randomly-initialized network (which we call "initial tickets"), hardly exploits any information from the training data; (2) For the pruned networks obtained by these methods, randomly changing the preserved weights in each layer, while keeping the total number of preserved weights unchanged per layer, does not affect the final performance. These findings inspire us to choose a series of simple data-independent prune ratios for each layer, and randomly prune each layer accordingly to get a subnetwork (which we call "random tickets"). Experimental results show that our zero-shot random tickets outperform or attain a similar performance compared to existing "initial tickets". In addition, we identify one existing pruning method that passes our sanity checks. We hybridize the ratios in our random ticket with this method and propose a new method called "hybrid tickets", which achieves further improvement. 2 * Equal Contribution, reverse alphabetical order. 2 Our code is publicly available at https://github.com/JingtongSu/sanity-checking-pruning.

For agents

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

get_harvested_code_for_paper("2009.11094")
get_code_for_paper("2009.11094")
have("2009.11094")

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

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

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

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

Connect an agent — have() is free.