SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2311.14097 · 2023

ACT-Diffusion: Efficient Adversarial Consistency Training for One-step Diffusion Models

arXiv · PDF · Open in the Atlas

Code that ran

11 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 1 has no contract verdict; 10 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/2311.14097.json · badge: /api/ran/2311.14097.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
kong13661/act canonical (classifier label)
classifier basis: census
11 ran · 1 no recorded run
FunctionStatusWhere it lives
L1Loss Ran
ran; our contract draft was wrong, not the code
kong13661/act/models/loss.py
code served (permissive licence) · get_code("85dfec63f564779e")
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 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 torch

torch.manual_seed(0)

# L1Loss expects two tensors: pred and target
# Both should be tensors that support .flatten(1) and .norm(dim=-1, p=1) operations
# The function flattens to dim 1, computes L1 norm along last dim, then takes mean

pred = torch.randn(2, 4)  # batch size 2, feature dim 4
target = torch.randn(2, 4)  # batch size 2, feature dim 4

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 Tensor, 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
L2Loss Ran
ran; our contract draft was wrong, not the code
kong13661/act/models/loss.py
code served (permissive licence) · get_code("6a2a61c24b01a1a8")
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 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 torch

torch.manual_seed(0)

# Create small tensors for pred and target
# The function flattens to (batch, -1), computes L2 norm across last dim, then means
# Using batch_size=2 and some feature dimensions
pred = torch.randn(2, 4)
target = torch.randn(2, 4)

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 Tensor, 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
L2Loss_ph Ran
ran; our contract draft was wrong, not the code
kong13661/act/models/loss.py
code served (permissive licence) · get_code("946e3c947022f1b7")
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 1, dtype family float, shape (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 torch
import torch.nn as nn

torch.manual_seed(0)

# The function L2Loss_ph takes pred and target tensors
# It flattens them (keeping batch dim), squares differences, sums, adds a constant, takes sqrt, subtracts constant
# Both should be tensors that support flatten, subtraction, squaring, sum operations

pred = torch.randn(2, 4)
target = torch.randn(2, 4)

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 Tensor, ndim 1, dtype family float, shape (2,) — shape (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
create_path_decorator Ran
ran; our contract draft was wrong, not the code
kong13661/act/path_utils.py
code served (permissive licence) · get_code("20c5c05708bdfa87")
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 function. 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

class MockSelf:
    def __init__(self, create_path_flag=True, path_value="/tmp/test_path"):
        self.create_path = create_path_flag
        self.path_value = path_value

def mock_func(self):
    return self.path_value

ARGS = {
    "func": mock_func
}
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 function — a function output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a function 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
get_database_meta_from_funcion_signature Ran
ran; our contract draft was wrong, not the code
kong13661/act/common.py
code served (permissive licence) · get_code("ade5f33fab3df5b9")
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 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 inspect
import typing

torch = None  # Not needed for this function

def sample_function(
    param1: str,
    param2: int,
    param3: float,
    param4: bool,
    param5: list[str],
    param6: tuple[int, ...]
):
    """Sample function to get signature from"""
    pass

# Create a config dict with values matching the parameter names
config = {
    'param1': 'hello',
    'param2': 42,
    'param3': 3.14,
    'param4': True,
    'param5': ['a', 'b', 'c'],
    'param6': (1, 2, 3)
}

# Get the function signature
function_signature = inspect.signature(sample_function)

# Create program_meta_argument - list of parameter names to skip
program_meta_argument = []

ARGS = {
    'config': config,
    'function_signature': function_signature,
    'program_meta_argument': program_meta_argument
}
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 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
get_params_to_record_from_funcion_signature Ran
ran; our contract draft was wrong, not the code
kong13661/act/common.py
code served (permissive licence) · get_code("cfdd09203b275a9f")
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 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 inspect
import torch

# Create a sample function with type annotations
def sample_function(
    learning_rate: float,
    batch_size: int,
    model_name: str,
    num_epochs: int,
    internal_state
):
    pass

# Get the signature of the sample function
function_signature = inspect.signature(sample_function)

# Create a config dict with all parameters
config = {
    "learning_rate": 0.001,
    "batch_size": 32,
    "model_name": "resnet50",
    "num_epochs": 100,
    "internal_state": {"some": "value"}
}

# Define program_meta_argument as a list of parameter names to exclude
program_meta_argument = ["internal_state"]

# Construct ARGS dictionary with all parameters for the function
ARGS = {
    "config": config,
    "function_signature": function_signature,
    "program_meta_argument": program_meta_argument
}
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 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
get_type Ran
ran; our contract draft was wrong, not the code
kong13661/act/common.py
code served (permissive licence) · get_code("72fc04827d75b5b8")
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 typing
import inspect

torch.manual_seed(0)

# Analyze what get_type expects:
# - typing_value: a typing annotation (str, int, float, bool, list, tuple, or inspect._empty)
# The function checks identity with `is` and uses typing.get_origin() and typing.get_args()

# Test cases for the function
ARGS = {
    'typing_value': str  # A simple type that will return 'text'
}
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 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
loads_pyarrow Ran
ran; our contract draft was wrong, not the code
kong13661/act/convert_imagenet_lmdb.py
code served (permissive licence) · get_code("75f6b4b2d3a0cd47")
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 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 torch

torch.manual_seed(0)

# The function loads_pyarrow takes a buffer (bytes) that is the output of pickle.dumps
# We need to create a valid pickled object to pass in

# Create some test data to pickle
test_data = {
    "tensor": torch.randn(2, 4),
    "list": [1, 2, 3],
    "string": "test",
    "number": 42
}

# Pickle the test data to create a valid buffer
buf = pickle.dumps(test_data)

ARGS = {
    "buf": buf
}
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 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
raw_reader Ran
ran; our contract draft was wrong, not the code
kong13661/act/convert_imagenet_lmdb.py
code served (permissive licence) · get_code("51738010a21f76a1")
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 bytes. 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 tempfile
import os

# Create a temporary binary file with some test data
temp_dir = tempfile.mkdtemp()
test_file = os.path.join(temp_dir, "test_data.bin")

# Write some binary data to the file
with open(test_file, 'wb') as f:
    f.write(b'\x00\x01\x02\x03\x04\x05')

ARGS = {
    'path': test_file
}
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 bytes — a bytes output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a bytes 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
translate_mat Ran
ran; our contract draft was wrong, not the code
kong13661/act/augmentation.py
code served (permissive licence) · get_code("1d8a8391fc4d7389")
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 3, dtype family float, shape (2, 3, 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 torch

torch.manual_seed(0)

# Create small tensors for translation values
# t_x and t_y should have shape (batch,) where batch=2
batch_size = 2
t_x = torch.randn(batch_size)
t_y = torch.randn(batch_size)
device = 'cpu'

ARGS = {
    't_x': t_x,
    't_y': t_y,
    'device': device
}
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 3, dtype family float, shape (2, 3, 3) — shape (2, 3, 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
upfirdn2d_native Ran
ran on a synthesized input
kong13661/act/augmentation.py
code served (permissive licence) · get_code("6f6832bdac56cd3b")
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 4, dtype family float, shape (2, 3, 8, 10) 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)

# Create input tensor: (batch=2, channels=3, height=4, width=5)
input_tensor = torch.randn(2, 3, 4, 5)

# Create kernel tensor: (kernel_h=3, kernel_w=3)
kernel = torch.randn(3, 3)

# Upsampling factors
up_x = 2
up_y = 2

# Downsampling factors
down_x = 1
down_y = 1

# Padding parameters
pad_x0 = 1
pad_x1 = 1
pad_y0 = 1
pad_y1 = 1

ARGS = {
    "input": input_tensor,
    "kernel": kernel,
    "up_x": up_x,
    "up_y": up_y,
    "down_x": down_x,
    "down_y": down_y,
    "pad_x0": pad_x0,
    "pad_x1": pad_x1,
    "pad_y0": pad_y0,
    "pad_y1": pad_y1,
}
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 4, dtype family float, shape (2, 3, 8, 10) — shape (2, 3, 8, 10) 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
read_txt Not yet run
unverified (harvested, no recorded run)
kong13661/act/convert_imagenet_lmdb.py
code served (permissive licence) · get_code("b514c1d4d0c0e302")
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, 3 are also present in other papers whose code we hold (2 with at least one paper dated earlier, 0 the same month, 2 later) and 9 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
raw_reader 8 other papers
3 dated earlier, 5 later
2202.07800 (2022-02)
Not All Patches are What You Need: Expediting Vision Transformers via Token Reorganizations
2209.04996 (2022-09)
Switchable Online Knowledge Distillation
2210.05958 (2022-10)
Bridging the Gap Between Vision Transformers and Convolutional Neural Networks on Small Datasets
and 5 more not named here
upfirdn2d_native 2 other papers
2 dated earlier
2304.03119 (2023-04)
Zero-shot Generative Model Adaptation via Image-specific Prompt Learning
2305.00942 (2023-05)
StyleAvatar: Real-time Photo-realistic Portrait Avatar from a Single Video
translate_mat 1 other paper
1 later
2408.09458 (2024-08)
G2Face: High-Fidelity Reversible Face Anonymization via Generative and Geometric Priors

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

Though diffusion models excel in image generation, their step-by-step denoising leads to slow generation speeds. Consistency training addresses this issue with single-step sampling but often produces lower-quality generations and requires high training costs. In this paper, we show that optimizing consistency training loss minimizes the Wasserstein distance between target and generated distributions. As timestep increases, the upper bound accumulates previous consistency training losses. Therefore, larger batch sizes are needed to reduce both current and accumulated losses. We propose Adversarial Consistency Training (ACT), which directly minimizes the Jensen-Shannon (JS) divergence between distributions at each timestep using a discriminator. Theoretically, ACT enhances generation quality, and convergence. By incorporating a discriminator into the consistency training framework, our method achieves improved FID scores on CIFAR10 and ImageNet 64$\times$64 and LSUN Cat 256$\times$256 datasets, retains zero-shot image inpainting capabilities, and uses less than $1/6$ of the original batch size and fewer than $1/2$ of the model parameters and training steps compared to the baseline method, this leads to a substantial reduction in resource consumption. Our code is available:https://github.com/kong13661/ACT

For agents

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

get_harvested_code_for_paper("2311.14097")
get_code_for_paper("2311.14097")
have("2311.14097")

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

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

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

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

Connect an agent — have() is free.