SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2411.13731 · NeurIPS · 2024

∆-Influence: Unlearning Poisons via Influence Functions

Amartya Sanyal, Christian Schroeder De Witt, Wenjie Li, Jiawei Li, Ameya Prabhu, Pengcheng Zeng

arXiv · PDF · Open in the Atlas

Code that ran

7 of 12 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 0 have no contract verdict; 7 failures of our instrument; 5 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/2411.13731.json · badge: /api/ran/2411.13731.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
Ruby-a07/delta-influence canonical (classifier label)
classifier basis: census
7 ran · 4 no recorded run
andyisokay/delta-influence marked official in Papers with Code
Papers with Code archive
0 ran · 1 no recorded run
FunctionStatusWhere it lives
average_dicts Ran
ran; our contract draft was wrong, not the code
Ruby-a07/delta-influence/forest/utils.py
code served (permissive licence) · get_code("ff0cc040d88bde88")
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 defaultdict. 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.

from collections import defaultdict
import numpy as np

# Construct valid arguments for average_dicts function
# The function expects a list of dictionaries where each dict contains
# stats that are either scalar values or lists of values

running_stats = [
    {
        'loss': 0.5,
        'accuracy': 0.85,
        'per_class_accuracy': [0.80, 0.90, 0.88],
    },
    {
        'loss': 0.45,
        'accuracy': 0.87,
        'per_class_accuracy': [0.82, 0.92, 0.85],
    },
    {
        'loss': 0.48,
        'accuracy': 0.86,
        'per_class_accuracy': [0.81, 0.91, 0.87],
    },
]

ARGS = {
    'running_stats': running_stats,
}
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 defaultdict — a defaultdict output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a defaultdict 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
check_targets Ran
ran; our contract draft was wrong, not the code
Ruby-a07/delta-influence/forest/victims/training.py
code served (permissive licence) · get_code("ccb5c504f069d7e6")
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
import torch.nn as nn

torch.manual_seed(0)

# Build a minimal model that takes images and outputs class predictions
class SimpleModel(nn.Module):
    def __init__(self, num_classes=10):
        super().__init__()
        self.fc = nn.Linear(4, num_classes)
    
    def forward(self, x):
        # Flatten input and pass through linear layer
        x = x.view(x.size(0), -1)
        return self.fc(x)

# Create model instance
model = SimpleModel(num_classes=10)

# Create a simple criterion (loss function)
criterion = nn.CrossEntropyLoss()

# Create a small targetset: list of (image_tensor, label) tuples
# Each image is shape (4,) to match the model's input expectation
targetset = [
    (torch.randn(4), 3),
    (torch.randn(4), 7),
]

# intended_class should be a list/sequence of class indices for each target
intended_class = [5, 5]

# original_class is implicit in targetset labels, but we need to define it
# However, looking at the function, it's not directly used except passed
# The function extracts original_labels from targetset[i][1]
original_class = [3, 7]

# setup dict contains device and potentially other parameters
# The function uses setup['device'] and unpacks setup with **setup in .to(**setup)
setup = {
    'device': 'cpu',
    'dtype': torch.float32
}

ARGS = {
    'model': model,
    'criterion': criterion,
    'targetset': targetset,
    'intended_class': intended_class,
    'original_class': original_class,
    'setup': setup
}
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
convnet Ran
ran; our contract draft was wrong, not the code
Ruby-a07/delta-influence/forest/victims/models.py
code served (permissive licence) · get_code("d2f5607b54df5b75")
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 Sequential. 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
from collections import OrderedDict

torch.manual_seed(0)

# The function signature is:
# def convnet(width=32, in_channels=3, num_classes=10, **kwargs):
# It takes width, in_channels, num_classes as parameters and builds a ConvNet

ARGS = {
    'width': 32,
    'in_channels': 3,
    'num_classes': 10,
}
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 Sequential — a Sequential output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a Sequential 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
cw_loss Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
Ruby-a07/delta-influence/forest/utils.py
pointer only (licence: MIT); the stored copy get_code serves, from JonasGeiping/poisoning-gradient-matching, is pointer only (licence: LGPL-2.1) · get_code("6a5967011bf8de7a")
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 JonasGeiping/poisoning-gradient-matching, and LGPL-2.1, as GitHub detects it on that repository, is not in the permissive set Syntology serves inline. 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_optimizers Ran
ran; our contract draft was wrong, not the code
Ruby-a07/delta-influence/forest/victims/training.py
code served (permissive licence) · get_code("235c22042629630e")
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
import torch.nn as nn

torch.manual_seed(0)

# Create a minimal model
class SimpleModel(nn.Module):
    def __init__(self):
        super().__init__()
        self.linear = nn.Linear(4, 3)
    
    def forward(self, x):
        return self.linear(x)

model = SimpleModel()

# Create a minimal defs object with required attributes
class Defs:
    def __init__(self):
        self.optimizer = 'SGD'
        self.lr = 0.1
        self.weight_decay = 0.0001
        self.scheduler = 'cyclic'
        self.batch_size = 32
        self.epochs = 10

defs = Defs()

# args can be a simple object or dict - the function doesn't use it
args = {}

ARGS = {
    'model': model,
    'args': args,
    'defs': defs
}
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
linear_model Ran
ran; our contract draft was wrong, not the code
Ruby-a07/delta-influence/forest/victims/models.py
code served (permissive licence) · get_code("0fd172b3dd145268")
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 Sequential. 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)

ARGS = {
    'dataset': 'mnist',
    'num_classes': 10
}
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 Sequential — a Sequential output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a Sequential 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
training_strategy Ran
ran; our contract draft was wrong, not the code
Ruby-a07/delta-influence/forest/victims/optimization_strategy.py
code served (permissive licence) · get_code("e6a7a6941d029556")
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 ConservativeStrategy. 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 dataclasses import dataclass

torch.manual_seed(0)

# Create a simple args object with all required attributes
class Args:
    def __init__(self):
        self.epochs = None
        self.noaugment = False
        self.data_aug = True
        self.gradient_noise = None
        self.gradient_clip = None
        self.optimization = 'conservative'

ARGS = {
    'model_name': 'resnet50',
    'args': Args()
}
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 ConservativeStrategy — a ConservativeStrategy output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a ConservativeStrategy 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
_Witch Not yet run
unverified (harvested, no recorded run)
andyisokay/delta-influence/forest/witchcoven/witch_base.py
code served (permissive licence) · get_code("319676f714a216a9")
How it ran

no invocation recorded.

get_model Not yet run
unverified (harvested, no recorded run)
Ruby-a07/delta-influence/forest/victims/models.py
code served (permissive licence) · get_code("d180290beeedbcd1")
How it ran

no invocation recorded.

pgd_step Not yet run
unverified (harvested, no recorded run)
Ruby-a07/delta-influence/forest/victims/utils.py
code served (permissive licence) · get_code("22091a07a2d0facf")
How it ran

no invocation recorded.

run_validation Not yet run
unverified (harvested, no recorded run)
Ruby-a07/delta-influence/forest/victims/training.py
code served (permissive licence) · get_code("b2c584d7212d6446")
How it ran

no invocation recorded.

system_startup Not yet run
unverified (harvested, no recorded run)
Ruby-a07/delta-influence/forest/utils.py
code served (permissive licence) · get_code("120427a416e5f3a1")
How it ran

no invocation recorded.

Also present in other papers' code

Of 12 samples lifted from this paper's linked repositories, 12 carry a function identity and 0 do not. Of the 12 distinct functions with an identity, 1 are also present in other papers whose code we hold (1 with at least one paper dated earlier, 0 the same month, 0 later) and 11 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
cw_loss
brick of this paper's assembly: helper
2 other papers
2 dated earlier · 1 only as an assembly brick
2004.00225 (2020-04)
MetaPoison: Practical General-purpose Clean-label Data Poisoning
2009.02276 (2020-09)
Witches' Brew: Industrial Scale Data Poisoning via Gradient Matching

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

Addressing data integrity challenges, such as unlearning the effects of data poisoning after model training, is necessary for the reliable deployment of machine learning models. State-of-the-art influence functions, such as EK-FAC [Grosse et al., 2023] and TRAK [Park et al., 2023], often fail to accurately attribute abnormal model behavior to specific poisoned training data responsible for the data poisoning attack. In addition, traditional unlearning algorithms often struggle to effectively remove the influence of poisoned samples [Pawelczyk et al., 2024], particularly when only a few affected examples can be identified [Goel et al., 2024]. To address these challenges, we introduce ∆-Influence, a novel approach that leverages influence functions to trace abnormal model behavior back to the responsible poisoned training data using just one poisoned test example, without assuming any prior knowledge of the attack. ∆-Influence applies data transformations that sever the link between poisoned training data and compromised test points without significantly affecting clean data. This allows detecting large negative shifts in influence scores following data transformations, a phenomenon we term as influence collapse, thereby accurately identifying poisoned training data. Unlearning this subset, e.g. through retraining, effectively eliminates the data poisoning. We validate our method across three vision-based poisoning attacks and three datasets, benchmarking against five detection algorithms and five unlearning strategies. We show that ∆-Influence consistently achieves the best unlearning across all settings, showing the promise of influence functions for corrective unlearning.

For agents

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

get_harvested_code_for_paper("2411.13731")
get_code_for_paper("2411.13731")
have("2411.13731")

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

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

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

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

Connect an agent — have() is free.