SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2007.02622 · 2020

Integrating Distributed Architectures in Highly Modular RL Libraries

arXiv · PDF · Open in the Atlas

Code that ran

4 of 8 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 4 have no contract verdict; 0 failures of our instrument; 4 no recorded run), 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/2007.02622.json · badge: /api/ran/2007.02622.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
PyTorchRL/pytorchrl community (classifier label)
classifier basis not recorded on the link
4 ran · 4 no recorded run
FunctionStatusWhere it lives
average_gradients Ran
ran on a synthesized input
PyTorchRL/pytorchrl/pytorchrl/scheme/utils.py
code served (permissive licence) · get_code("9c88cb72fa692623")
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. 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)

# Construct a list of lists of tensors
# The function iterates over indices with `range(len(grads_list[0]))`
# and accesses `d[grad]` where grad is an integer index
# So grads_list is a list of sequences (lists or tuples) of tensors

# Create 3 worker gradient lists, each containing 2 gradient tensors
grads_list = [
    [torch.randn(2, 4), torch.randn(3, 5)],  # Worker 1 gradients
    [torch.randn(2, 4), torch.randn(3, 5)],  # Worker 2 gradients
    [torch.randn(2, 4), torch.randn(3, 5)],  # Worker 3 gradients
]

ARGS = {
    "grads_list": grads_list
}
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 list — a list 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
bt Ran
ran on a synthesized input
PyTorchRL/pytorchrl/pytorchrl/agent/algorithms/utils.py
code served (permissive licence) · get_code("8a172de9485e8562")
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, 4, 5, 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
import torch.nn as nn

torch.manual_seed(0)

# The function bt(m) calls m.transpose(dim0=-2, dim1=-1)
# This means m must be a tensor (or have a transpose method)
# The transpose swaps the last two dimensions

# Create a small tensor with distinct dimensions for clarity
# Shape: (2, 4, 3, 5) - batch=2, then 4, 3, 5 for distinct probing
m = torch.randn(2, 4, 3, 5)

ARGS = {
    "m": m
}
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, 4, 5, 3) — shape (2, 4, 5, 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
btr Ran
ran on a synthesized input
PyTorchRL/pytorchrl/pytorchrl/agent/algorithms/utils.py
code served (permissive licence) · get_code("72a80ce7592e38cd")
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 2, dtype family float, shape (2, 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 torch.nn as nn

torch.manual_seed(0)

# The function btr takes a parameter 'm' and calls:
# - m.diagonal(dim1=-2, dim2=-1) which requires a tensor with at least 2 dimensions
# - .sum(-1) on the result
# So 'm' needs to be a tensor with at least 2 dimensions (and ideally more to make
# the diagonal operation meaningful)

# Create a small 4D tensor (batch=2, channels=4, height=3, width=3)
# This gives us enough dimensions for diagonal(dim1=-2, dim2=-1) to work
m = torch.randn(2, 4, 3, 3)

ARGS = {
    "m": m
}
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 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
gaussian_kl Ran
ran on a synthesized input
PyTorchRL/pytorchrl/pytorchrl/agent/algorithms/utils.py
code served (permissive licence) · get_code("5ec30e1da221a76e")
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

torch.manual_seed(0)

# Parameters for gaussian_kl function
# mu1: torch.tensor - Mean distribution 1 - (B, n)
# mu2: torch.tensor - Mean distribution 2 - (B, n)
# cov1: torch.tensor - Covariance matrix distribution 1 - (B, n, n)
# cov2: torch.tensor - Covariance matrix distribution 2 - (B, n, n)

batch_size = 2
dim = 4

# Create mean vectors (B, n)
mu1 = torch.randn(batch_size, dim)
mu2 = torch.randn(batch_size, dim)

# Create covariance matrices (B, n, n)
# Use positive definite matrices by construction: L @ L^T
L1 = torch.randn(batch_size, dim, dim)
cov1 = L1 @ L1.transpose(-2, -1) + torch.eye(dim) * 0.1

L2 = torch.randn(batch_size, dim, dim)
cov2 = L2 @ L2.transpose(-2, -1) + torch.eye(dim) * 0.1

ARGS = {
    "mu1": mu1,
    "mu2": mu2,
    "cov1": cov1,
    "cov2": cov2,
}
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
check_message Not yet run
unverified (harvested, no recorded run)
PyTorchRL/pytorchrl/pytorchrl/scheme/utils.py
code served (permissive licence) · get_code("889e1ecd97fa6cbd")
How it ran

no invocation recorded.

clip_grad_norm_ Not yet run
unverified (harvested, no recorded run)
PyTorchRL/pytorchrl/pytorchrl/utils.py
code served (permissive licence) · get_code("c668f382578e3aa4")
How it ran

no invocation recorded.

get_algorithm Not yet run
unverified (harvested, no recorded run)
PyTorchRL/pytorchrl/pytorchrl/trainer.py
code served (permissive licence) · get_code("885df13bf6c29027")
How it ran

no invocation recorded.

ray_get_and_free Not yet run
unverified (harvested, no recorded run)
PyTorchRL/pytorchrl/pytorchrl/scheme/utils.py
code served (permissive licence) · get_code("b3a16c8114ffbb77")
How it ran

no invocation recorded.

Also present in other papers' code

Of 8 samples lifted from this paper's linked repositories, 8 carry a function identity and 0 do not. Of the 8 distinct functions with an identity, 1 are also present in other papers whose code we hold (0 with at least one paper dated earlier, 0 the same month, 1 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
bt 1 other paper
1 later
ijcai2022_0528 (2022 (year only))
Multi-Constraint Deep Reinforcement Learning for Smooth Action Control

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

Advancing reinforcement learning (RL) requires tools that are flexible enough to easily prototype new methods while avoiding impractically slow experimental turnaround times. To match the first requirement, the most popular RL libraries advocate for highly modular agent composability, which facilitates experimentation and development. To solve challenging environments within reasonable time frames, scaling RL to large sampling and computing resources has proved a successful strategy. However, this capability has been so far difficult to combine with modularity. In this work, we explore design choices to allow agent composability both at a local and distributed level of execution. We propose a versatile approach that allows the definition of RL agents at different scales through independent reusable components. We demonstrate experimentally that our design choices allow us to reproduce classical benchmarks, explore multiple distributed architectures, and solve novel and complex environments while giving full control to the user in the agent definition and training scheme definition. We believe this work can provide useful insights to the next generation of RL libraries.

For agents

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

get_harvested_code_for_paper("2007.02622")
get_code_for_paper("2007.02622")
have("2007.02622")

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

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

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

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

Connect an agent — have() is free.