SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2210.10195 · 2022

Curriculum Reinforcement Learning using Optimal Transport via Gradual Domain Adaptation

arXiv · PDF · Open in the Atlas

Code that ran

7 of 11 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, 1 violated it and 6 have no contract verdict; 0 failures of our instrument; 4 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/2210.10195.json · badge: /api/ran/2210.10195.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
peidehuang/gradient canonical (classifier label)
classifier basis not recorded on the link
7 ran · 4 no recorded run
FunctionStatusWhere it lives
cityblock Ran
ran on a synthesized input
peidehuang/gradient/helpers/w_encode.py
code served (permissive licence) · get_code("5811f6be9208407e")
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 float64, ndim 0, dtype family float; no output shape is stated. It ran in syntology-harvest-sandbox:v5-deps (sha256:6a292aa1aed1) at 2026-09-26T22:57:59Z. 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 numpy as np
from scipy.spatial import distance

torch.manual_seed(0)

# Create two small 1D vectors for cityblock distance calculation
x1 = np.array([1.0, 2.0, 3.0, 4.0])
x2 = np.array([5.0, 6.0, 7.0, 8.0])

ARGS = {
    "x1": x1,
    "x2": x2,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, scipy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type float64, ndim 0, dtype family float — 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
compute_V Ran
ran on a synthesized input
peidehuang/gradient/helpers/bary_utils.py
code served (permissive licence) · get_code("5a64f060f3de135b")
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; no output shape is stated. It ran in syntology-harvest-sandbox:v5-deps (sha256:6a292aa1aed1) at 2026-09-26T22:57:59Z. 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)

class SimpleModel(nn.Module):
    def __init__(self):
        super().__init__()
        self.linear = nn.Linear(2, 3)
    
    def predict(self, x):
        return self.linear(x)

model = SimpleModel()
s = torch.randn(2, 4)

ARGS = {
    "s": s,
    "model": model
}
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 — 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
forward_reward_vabs Ran
ran on a synthesized input
peidehuang/gradient/envs/mujoco-maze/mujoco_maze/ant.py
code served (permissive licence) · get_code("73c18a5a44ec0c8c")
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 float64, ndim 0, dtype family float; no output shape is stated. It ran in syntology-harvest-sandbox:v5-deps (sha256:6a292aa1aed1) at 2026-09-26T22:57:59Z. 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 numpy as np

# The function takes xy_velocity (a float) and returns the sum of absolute values
# We need to construct a valid float argument

xy_velocity_value = 3.5

ARGS = {
    "xy_velocity": xy_velocity_value
}
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 float64, ndim 0, dtype family float — 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
forward_reward_vnorm Ran
ran on a synthesized input
peidehuang/gradient/envs/mujoco-maze/mujoco_maze/ant.py
code served (permissive licence) · get_code("8e246f74a0336453")
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 float64, ndim 0, dtype family float; no output shape is stated. It ran in syntology-harvest-sandbox:v5-deps (sha256:6a292aa1aed1) at 2026-09-26T22:57:59Z. 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 numpy as np

def forward_reward_vnorm(xy_velocity: float) -> float:
    return np.linalg.norm(xy_velocity)

# The function expects xy_velocity which is used with np.linalg.norm()
# np.linalg.norm() can accept a scalar or array-like input
# We'll provide a simple float value as the parameter name suggests

ARGS = {
    "xy_velocity": 5.0
}
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 float64, ndim 0, dtype family float — 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
q_inv Ran
ran, violated the contract we drafted
peidehuang/gradient/envs/mujoco-maze/mujoco_maze/ant.py
code served (permissive licence) · get_code("b518b50864d18ead")
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, 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)

# q_inv takes a quaternion representation as input
# A quaternion is typically [w, x, y, z] or [x, y, z, w]
# The function returns the inverse by negating the imaginary parts (indices 1, 2, 3)
# So we need a list or sequence of 4 elements

a = [1.0, 0.5, -0.3, 0.2]

ARGS = {
    "a": a
}
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, ndim 1, dtype family float — a list 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
visualize_V_2d Ran
ran on a synthesized input
peidehuang/gradient/helpers/bary_utils.py
code served (permissive licence) · get_code("a7c8b9d6e3074420")
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. It ran in syntology-harvest-sandbox:v5-deps (sha256:6a292aa1aed1) at 2026-09-26T22:57:59Z. 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 numpy as np
import matplotlib.pyplot as plt
from matplotlib.figure import Figure
from matplotlib.axes import Axes


class SimpleModel:
    def predict(self, s):
        # s has shape (..., 2) - the last 2 dimensions
        # Return a scalar value for each input point
        return np.sum(s, axis=-1)


# Create figure and axis
fig = plt.figure(figsize=(8, 8))
ax = fig.add_subplot(111)

# Create a simple model
model = SimpleModel()

# Path for saving (not actually used in function, but required)
fig_save_path = "/tmp/visualization.png"

ARGS = {
    "model": model,
    "fig_save_path": fig_save_path,
    "fig": fig,
    "ax": ax
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
matplotlib, numpy — 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 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
wrap_vec_env Ran
ran on a synthesized input
peidehuang/gradient/helpers/utils.py
code served (permissive licence) · get_code("00a63f665d5f7d64")
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 VecEnv. It ran in syntology-harvest-sandbox:v5-deps (sha256:6a292aa1aed1) at 2026-09-26T22:57:59Z. 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 numpy as np
from unittest.mock import Mock

torch.manual_seed(0)

# Create a simple environment wrapper class
class SimpleEnvWrapper:
    def __init__(self, env, **kwargs):
        self.env = env
        self.wrapper_kwargs = kwargs
        self.observation_space = env.observation_space
        self.action_space = env.action_space
    
    def reset(self):
        return self.env.reset()
    
    def step(self, action):
        return self.env.step(action)

# Create a simple mock environment
class SimpleEnv:
    def __init__(self):
        self.observation_space = Mock()
        self.action_space = Mock()
    
    def reset(self):
        return np.zeros(4, dtype=np.float32)
    
    def step(self, action):
        obs = np.zeros(4, dtype=np.float32)
        reward = 0.0
        done = False
        info = {}
        return obs, reward, done, info

# Create a mock vectorized environment
class VecEnv:
    def __init__(self, num_envs=2):
        self.envs = [SimpleEnv() for _ in range(num_envs)]
        self.num_envs = num_envs

ARGS = {
    "venv": VecEnv(num_envs=2),
    "wrapper": SimpleEnvWrapper,
    "wrapper_kwargs": {"normalize": True, "clip_reward": 1.0}
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type VecEnv — a VecEnv output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a VecEnv output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
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
compute_barycenter Not yet run
unverified (harvested, no recorded run)
peidehuang/gradient/helpers/bary_utils.py
code served (permissive licence) · get_code("56aafecf3558c170")
How it ran

no invocation recorded.

cos Not yet run
unverified (harvested, no recorded run)
peidehuang/gradient/helpers/w_encode.py
code served (permissive licence) · get_code("3bd505e2b52a827a")
How it ran

no invocation recorded.

l2_func Not yet run
unverified (harvested, no recorded run)
peidehuang/gradient/helpers/w_encode.py
code served (permissive licence) · get_code("2bd74a06579c1185")
How it ran

no invocation recorded.

linear_schedule Not yet run
unverified (harvested, no recorded run)
peidehuang/gradient/helpers/utils.py
code served (permissive licence) · get_code("7d7285fe24c34a81")
How it ran

no invocation recorded.

Also present in other papers' code

Of 11 samples lifted from this paper's linked repositories, 11 carry a function identity and 0 do not. Of the 11 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, 1 later) and 10 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
q_inv 3 other papers
1 dated earlier, 2 later
2004.12974 (2020-04)
Emergent Real-World Robotic Skills via Unsupervised Off-Policy Reinforcement Learning
2401.09870 (2024-01)
Reconciling Spatial and Temporal Abstractions for Goal Representation
2403.03181 (2024-03)
Behavior Generation with Latent Actions

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

Curriculum Reinforcement Learning (CRL) aims to create a sequence of tasks, starting from easy ones and gradually learning towards difficult tasks. In this work, we focus on the idea of framing CRL as interpolations between a source (auxiliary) and a target task distribution. Although existing studies have shown the great potential of this idea, it remains unclear how to formally quantify and generate the movement between task distributions. Inspired by the insights from gradual domain adaptation in semi-supervised learning, we create a natural curriculum by breaking down the potentially large task distributional shift in CRL into smaller shifts. We propose GRADIENT, which formulates CRL as an optimal transport problem with a tailored distance metric between tasks. Specifically, we generate a sequence of task distributions as a geodesic interpolation (i.e., Wasserstein barycenter) between the source and target distributions. Different from many existing methods, our algorithm considers a task-dependent contextual distance metric and is capable of handling nonparametric distributions in both continuous and discrete context settings. In addition, we theoretically show that GRADIENT enables smooth transfer between subsequent stages in the curriculum under certain conditions. We conduct extensive experiments in locomotion and manipulation tasks and show that our proposed GRADIENT achieves higher performance than baselines in terms of learning efficiency and asymptotic performance.

For agents

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

get_harvested_code_for_paper("2210.10195")
get_code_for_paper("2210.10195")
have("2210.10195")

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

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

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

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

Connect an agent — have() is free.