SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2408.03124 · ICLR · 2025

CL-DiffPhyCon: Closed-loop Diffusion Control of Complex Physical Systems

Tailin Wu, Ruiqi Feng, Long Wei, Tao Zhang, Yuchen Yang, Peiyan Hu, Haodong Feng, Xiang Zheng, Dixia Fan

arXiv · PDF · Open in the Atlas

Code that ran

11 of 15 samples (functions and classes) lifted from this paper's linked repositories executed on a synthesized input in Syntology's jail (1 of them constructed an object rather than computing a result; 3 honoured the contract we drafted, 4 violated it and 1 has no contract verdict; 3 failures of our instrument; 4 no recorded run); 1 of them was also run on the host, not in the jail, by the peer-agreement lane that set its level, measured 2026-11-22; 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/2408.03124.json · badge: /api/ran/2408.03124.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
AI4Science-WestlakeU/CL_DiffPhyCon canonical (classifier label)
classifier basis: census
10 ran · 3 no recorded run
ai4science-westlakeu/cl_diffphycon community
Papers with Code archive
1 ran · 1 no recorded run
FunctionStatusWhere it lives
identity Ran
ran, honoured the contract we drafted
AI4Science-WestlakeU/CL_DiffPhyCon/diffusion/diffusion_2d.py
code served (permissive licence) · get_code("7f1040f5e3991d5e")
How it ran

Ran in Syntology's jail on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1) and returned Tensor, ndim 2, dtype family float, shape (2, 4) as a later run recorded it. The image it ran in was not recorded. The comparison behind this sample's level is a different run: the peer-agreement lane ran it again on the host, not in the jail (report dated 2026-09-05T00:37:21Z). 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 identity function simply returns its first argument
# and ignores all other args and kwargs
# So we need to provide a value for t and can optionally provide other args/kwargs

t = torch.randn(2, 4)
extra_arg_1 = torch.randn(3, 5)
extra_arg_2 = "some_string"
extra_kwarg_1 = 42
extra_kwarg_2 = [1, 2, 3]

ARGS = {
    "t": t,
    "args": (extra_arg_1, extra_arg_2),
    "kwargs": {"key1": extra_kwarg_1, "key2": extra_kwarg_2}
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 2, dtype family float, shape (2, 4) — shape (2, 4) as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
InferencePipeline Ran
ran on a synthesized input · constructed an object; no result was computed
ai4science-westlakeu/cl_diffphycon/inference/inference_2d.py
code served (permissive licence) · get_code("96caecdace827fb4")
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 an instance of its own class, InferencePipeline: the run constructed the object and did not call it, so no result was computed. 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
import numpy as np
import tempfile

torch.manual_seed(0)
np.random.seed(0)

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

model = DummyModel()

# Create args_general config
class ArgsGeneral:
    def __init__(self):
        self.is_condition_control = True
        self.image_size = 64
        self.device = 'cpu'
        self.upsample = 1
        self.total_time_steps = 10
        self.bucket_index = 1
        self.rand_action_p = 0.1
        self.rand_action_std = 1.0
        self.random_sim = False
        self.dataset_path = tempfile.gettempdir()

args_general = ArgsGeneral()

# Create args config
class Args:
    def __init__(self):
        self.some_param = 1.0

args = Args()

# Create RESCALER tensor
RESCALER = torch.ones(1, 1, 6, 64, 64)

# Create results_path
results_path = tempfile.gettempdir()

ARGS = {
    'model': model,
    'args': args,
    'RESCALER': RESCALER,
    'results_path': results_path,
    'args_general': args_general
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, torch, tqdm — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type InferencePipeline — the run constructed an instance of its own class and did not call it; no shape is stated — the instrument coerces any output to an array; for a InferencePipeline 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
default Ran
ran, violated the contract we drafted
AI4Science-WestlakeU/CL_DiffPhyCon/model/video_diffusion_pytorch_conv3d.py
code served (permissive licence) · get_code("d1ef6b8cb9a28a53")
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) 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

torch.manual_seed(0)

def exists(x):
    return x is not None

def default(val, d):
    if exists(val):
        return val
    return d() if callable(d) else d

# Test case 1: val is not None, should return val
val_1 = "test_value"
d_1 = lambda: "default_value"

# Test case 2: val is None, d is callable, should return d()
val_2 = None
d_2 = lambda: "computed_default"

# Test case 3: val is None, d is not callable, should return d
val_3 = None
d_3 = "static_default"

# Test case 4: val is a number
val_4 = 42
d_4 = 100

# Test case 5: val is a tensor
val_5 = torch.tensor([1.0, 2.0, 3.0])
d_5 = lambda: torch.tensor([0.0])

ARGS = {
    "val": val_1,
    "d": d_1
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1
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
display_name Ran
ran; our contract draft was wrong, not the code
AI4Science-WestlakeU/CL_DiffPhyCon/phi/model.py
code served (permissive licence) · get_code("7d3807f597feb193")
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

torch.manual_seed(0)

ARGS = {
    "python_name": "hello_world_example"
}
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
exists Ran
ran, violated the contract we drafted
AI4Science-WestlakeU/CL_DiffPhyCon/model/text.py
pointer only (licence: MIT); the stored copy get_code serves, from ThomasMrY/VCT, is pointer only (licence: NONE) · get_code("aa5486a3650902d8")
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 ThomasMrY/VCT, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

exists Ran
ran, violated the contract we drafted
AI4Science-WestlakeU/CL_DiffPhyCon/model/video_diffusion_pytorch_conv3d.py
code served (permissive licence) · get_code("608e364a9d2376a3")
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) and returned bool, 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

def exists(x):
    return x is not None

ARGS = {
    "x": torch.tensor([1, 2, 3, 4])
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type bool, 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
get_burgers_preprocess Ran
ran; our contract draft was wrong, not the code
AI4Science-WestlakeU/CL_DiffPhyCon/dataset/data_1d.py
code served (permissive licence) · get_code("ebab7abaec014f95")
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 torch
import torch.nn as nn

torch.manual_seed(0)

# Create a mock database dict with 'u' and 'f' tensors
# u shape: (batch, time, spatial) - using (2, 15, 4) for batch=2, time=15, spatial=4
# f shape: (batch, time, spatial) - using (2, 20, 4) for batch=2, time=20, spatial=4
u_tensor = torch.randn(2, 15, 4)
f_tensor = torch.randn(2, 20, 4)

db = {
    'u': u_tensor,
    'f': f_tensor
}

# Create a rescaler value (can be a scalar or tensor)
rescaler_value = 2.0

ARGS = {
    'rescaler': rescaler_value,
    'stack_u_and_f': False,
    'pad_for_2d_conv': False,
    'partially_observed_fill_zero_unobserved': None
}
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 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
is_odd Ran
ran, violated the contract we drafted
AI4Science-WestlakeU/CL_DiffPhyCon/model/video_diffusion_pytorch_conv3d.py
pointer only (licence: MIT); the stored copy get_code serves, from yulewang97/benediff, is pointer only (licence: NONE) · get_code("ebc12c938e7a6b29")
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 yulewang97/benediff, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

normalize_to_neg_one_to_one Ran
ran, honoured the contract we drafted
AI4Science-WestlakeU/CL_DiffPhyCon/utils_1d/model_utils.py
pointer only (licence: MIT); the stored copy get_code serves, from futurexiang/soda, is pointer only (licence: NONE) · get_code("a1229a9f4df127e2")
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 futurexiang/soda, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

synchronized_method Ran
ran; our contract draft was wrong, not the code
AI4Science-WestlakeU/CL_DiffPhyCon/phi/model.py
code served (permissive licence) · get_code("35eb6064f0c2c7a2")
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 threading
import inspect

def synchronized_method(method):
    outer_lock = threading.Lock()
    lock_name = '__' + method.__name__ + '_lock' + '__'

    def sync_method(self, *args, **kws):
        with outer_lock:
            if not hasattr(self, lock_name):
                setattr(self, lock_name, threading.Lock())
            lock = getattr(self, lock_name)
            with lock:
                return method(self, *args, **kws)
    return sync_method


class TestClass:
    @synchronized_method
    def test_method(self, x, y=10):
        return x + y


def sample_function(a, b):
    return a + b


ARGS = {
    'method': sample_function
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, six — 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
unnormalize_to_zero_to_one Ran
ran, honoured the contract we drafted
AI4Science-WestlakeU/CL_DiffPhyCon/utils_1d/model_utils.py
pointer only (licence: MIT); the stored copy get_code serves, from futurexiang/soda, is pointer only (licence: NONE) · get_code("97e1bbd232dfe092")
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 futurexiang/soda, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

bert_embed Not yet run
unverified (harvested, no recorded run)
AI4Science-WestlakeU/CL_DiffPhyCon/model/text.py
code served (permissive licence) · get_code("ac66a9775ac199a0")
How it ran

no invocation recorded.

guidance_fn Not yet run
unverified (harvested, no recorded run)
AI4Science-WestlakeU/CL_DiffPhyCon/inference/inference_2d.py
code served (permissive licence) · get_code("8eb357dddd5f2b3e")
How it ran

no invocation recorded.

solver_env Not yet run
unverified (harvested, no recorded run)
ai4science-westlakeu/cl_diffphycon/inference/inference_2d.py
code served (permissive licence) · get_code("a46646c5c4bab5e8")
How it ran

no invocation recorded.

tokenize Not yet run
unverified (harvested, no recorded run)
AI4Science-WestlakeU/CL_DiffPhyCon/model/text.py
code served (permissive licence) · get_code("03dfcc33eeaff851")
How it ran

no invocation recorded.

Also present in other papers' code

Of 15 samples lifted from this paper's linked repositories, 15 carry a function identity and 0 do not. Of the 15 distinct functions with an identity, 11 are also present in other papers whose code we hold (11 with at least one paper dated earlier, 3 the same month, 11 later) and 4 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
exists 486 other papers
371 dated earlier, 5 the same month, 99 later, 9 same year, order not determinable, 2 undated · 78 only as an assembly brick
1603.08155 (2016-03)
Perceptual Losses for Real-Time Style Transfer and Super-Resolution
1611.07004 (2016-11)
Image-to-Image Translation with Conditional Adversarial Networks
1804.04637 (2018-04)
EMBER: An Open Dataset for Training Static PE Malware Machine Learning Models
and 483 more not named here
exists 144 other papers
96 dated earlier, 2 the same month, 41 later, 5 same year, order not determinable · 40 only as an assembly brick
1611.07004 (2016-11)
Image-to-Image Translation with Conditional Adversarial Networks
1711.11585 (2017-11)
High-Resolution Image Synthesis and Semantic Manipulation with Conditional GANs
2006.11239 (2020-06)
Denoising Diffusion Probabilistic Models
and 141 more not named here
default 79 other papers
49 dated earlier, 1 the same month, 26 later, 3 same year, order not determinable · 15 only as an assembly brick
1611.07004 (2016-11)
Image-to-Image Translation with Conditional Adversarial Networks
2006.11239 (2020-06)
Denoising Diffusion Probabilistic Models
2010.02502 (2020-10)
Denoising Diffusion Implicit Models
and 76 more not named here
identity 54 other papers
37 dated earlier, 16 later, 1 same year, order not determinable · 11 only as an assembly brick
1611.07004 (2016-11)
Image-to-Image Translation with Conditional Adversarial Networks
1907.01470 (2019-07)
Augmenting Self-attention with Persistent Memory
2006.11239 (2020-06)
Denoising Diffusion Probabilistic Models
and 51 more not named here
normalize_to_neg_one_to_one 18 other papers
13 dated earlier, 5 later · 8 only as an assembly brick
1611.07004 (2016-11)
Image-to-Image Translation with Conditional Adversarial Networks
2006.11239 (2020-06)
Denoising Diffusion Probabilistic Models
2209.15571 (2022-09)
Building Normalizing Flows with Stochastic Interpolants
and 15 more not named here
unnormalize_to_zero_to_one 18 other papers
12 dated earlier, 6 later · 9 only as an assembly brick
2006.11239 (2020-06)
Denoising Diffusion Probabilistic Models
2105.05233 (2021-05)
Diffusion Models Beat GANs on Image Synthesis
2209.15571 (2022-09)
Building Normalizing Flows with Stochastic Interpolants
and 15 more not named here
is_odd 4 other papers
3 dated earlier, 1 later
2303.13744 (2023-03)
Conditional Image-to-Video Generation with Latent Flow Diffusion Models
2305.19836 (2023-05)
Inverse-design of nonlinear mechanical metamaterials via video denoising diffusion models
2403.07711 (2024-03)
SSM Meets Video Diffusion Models: Efficient Long-Term Video Generation with Structured State Spaces
and 1 more not named here
bert_embed 3 other papers
2 dated earlier, 1 later · 1 only as an assembly brick
2204.03458 (2022-04)
Video Diffusion Models
2303.13744 (2023-03)
Conditional Image-to-Video Generation with Latent Flow Diffusion Models
2410.13175 (2024-10)
TCP-Diffusion: A Multi-modal Diffusion Model for Global Tropical Cyclone Precipitation Forecasting with Change Awareness
tokenize 3 other papers
2 dated earlier, 1 later · 1 only as an assembly brick
2204.03458 (2022-04)
Video Diffusion Models
2303.13744 (2023-03)
Conditional Image-to-Video Generation with Latent Flow Diffusion Models
2410.13175 (2024-10)
TCP-Diffusion: A Multi-modal Diffusion Model for Global Tropical Cyclone Precipitation Forecasting with Change Awareness
display_name 2 other papers
1 dated earlier, 1 later
2407.06494 (2024-07)
DiffPhyCon: A Generative Approach to Control Complex Physical Systems
2412.04833 (2024-12)
Wavelet Diffusion Neural Operator
synchronized_method 2 other papers
1 dated earlier, 1 later
2407.06494 (2024-07)
DiffPhyCon: A Generative Approach to Control Complex Physical Systems
2412.04833 (2024-12)
Wavelet Diffusion Neural Operator

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

The control problems of complex physical systems have broad applications in science and engineering. Previous studies have shown that generative control methods based on diffusion models offer significant advantages for solving these problems. However, existing generative control approaches face challenges in both performance and efficiency when extended to the closed-loop setting, which is essential for effective control. In this paper, we propose an efficient Closed-Loop Diffusion method for Physical systems Control (CL-DiffPhyCon). By employing an asynchronous denoising framework for different physical time steps, CL-DiffPhyCon generates control signals conditioned on real-time feedback from the system with significantly reduced computational cost during sampling. Additionally, the control process could be further accelerated by incorporating fast sampling techniques, such as DDIM. We evaluate CL-DiffPhyCon on two tasks: 1D Burgers' equation control and 2D incompressible fluid control. The results demonstrate that CL-DiffPhyCon achieves superior control performance with significant improvements in sampling efficiency. The code can be found at https://github.com/AI4Science-WestlakeU/CL_DiffPhyCon.

For agents

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

get_harvested_code_for_paper("2408.03124")
get_code_for_paper("2408.03124")
have("2408.03124")

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

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

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

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

Connect an agent — have() is free.