SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2304.14329 · 2023

Learning to Extrapolate: A Transductive Approach

arXiv · PDF · Open in the Atlas

Code that ran

17 of 20 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 15 have no contract verdict; 2 failures of our instrument; 3 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/2304.14329.json · badge: /api/ran/2304.14329.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
avivne/bilinear-transduction canonical (classifier label)
classifier basis: census
8 ran · 1 no recorded run
learningmatter-mit/matex community (classifier label)
classifier basis not recorded on the link
9 ran · 2 no recorded run
FunctionStatusWhere it lives
data_load Ran
ran on a synthesized input
avivne/bilinear-transduction/utils/util.py
code served (permissive licence) · get_code("96ba47411fab30f0")
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 2, 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 os
import tempfile
import pickle

# Create a temporary directory with the required pickle files
tmpdir = tempfile.mkdtemp()

# Create sample data structures
demos = [
    {"observation": [1, 2, 3], "action": [0.1, 0.2]},
    {"observation": [4, 5, 6], "action": [0.3, 0.4]}
]

in_dist_eval_goals = [
    {"goal": [1, 1, 1]},
    {"goal": [2, 2, 2]}
]

ood_eval_goals = [
    {"goal": [10, 10, 10]},
    {"goal": [20, 20, 20]}
]

# Write pickle files to the temporary directory
with open(os.path.join(tmpdir, 'demos.pkl'), 'wb') as f:
    pickle.dump(demos, f)

with open(os.path.join(tmpdir, 'in_dist_goals.pkl'), 'wb') as f:
    pickle.dump(in_dist_eval_goals, f)

with open(os.path.join(tmpdir, 'ood_goals.pkl'), 'wb') as f:
    pickle.dump(ood_eval_goals, f)

ARGS = {
    "loaddir": tmpdir
}
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 tuple, ndim 2, 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
extract_composition Ran
ran on a synthesized input
learningmatter-mit/matex/data_modules/data_process.py
code served (permissive licence) · get_code("8fdc56dd2cb6731a")
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 torch

class Container:
    def __init__(self):
        self.composition = {
            "layer1": torch.tensor([[1.0, 2.0, 3.0, 4.0]]),
            "layer2": torch.tensor([[5.0, 6.0, 7.0, 8.0]])
        }

torch.manual_seed(0)
container = Container()

ARGS = {
    "container": container
}
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_prop_labels Ran
ran on a synthesized input
learningmatter-mit/matex/blt/plot_maker/props_utils.py
code served (permissive licence) · get_code("1378650b374b3a86")
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 numpy as np

torch.manual_seed(0)

# The function get_prop_labels takes a single parameter 'prop' which is a string
# It returns a tuple of (x_label, title) based on the property name
# We need to provide valid arguments that will execute the function

ARGS = {
    'prop': 'bulk_modulus'
}
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 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
get_prop_rep Ran
ran on a synthesized input
learningmatter-mit/matex/blt/plot_maker/props_utils.py
code served (permissive licence) · get_code("cf11fb6095bba44e")
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 torch.nn as nn
import numpy as np

torch.manual_seed(0)

# The function takes a benchmark parameter and returns a string representation
# based on simple string matching. No complex objects needed.

ARGS = {
    'benchmark': 'matbench'
}
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 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
get_results_filename Ran
ran on a synthesized input
learningmatter-mit/matex/blt/plot_maker/props_utils.py
code served (permissive licence) · get_code("085dae6797969122")
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

# Call get_prop_rep and get_results_filename with valid arguments
ARGS = {
    'benchmark': 'aflow',
    'prop': 'bulk_modulus_vrh',
    'model_type': 'bilinear'
}
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
get_split Ran
ran on a synthesized input
learningmatter-mit/matex/baselines/modnet/aflow_mp.py
code served (permissive licence) · get_code("a26982da6e0216ef")
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 numpy as np
import pandas as pd
from sklearn.model_selection import train_test_split

# Create a simple targets object with a .values attribute that has .squeeze() method
targets = pd.Series([1.2, 3.4, 2.1, 5.6, 4.3, 1.9])

ARGS = {
    'n_data': 6,
    'test_size': 0.33,
    'split_type': 'ood',
    'targets': targets
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, pandas, sklearn — 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
get_sym_dict Ran
ran on a synthesized input
learningmatter-mit/matex/data_modules/data_utils.py
code served (permissive licence) · get_code("a655195cd9d3857f")
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.

import collections
import re

class CompositionError(Exception):
    """Exception class for composition errors"""
    pass

def get_sym_dict(f, factor):
    sym_dict = collections.defaultdict(float)
    regex = '([A-Z][a-z]*)\\s*([-*\\.\\d]*)'
    r = re.compile(regex)
    for m in re.finditer(r, f):
        el = m.group(1)
        amt = 1
        if m.group(2).strip() != '':
            amt = float(m.group(2))
        sym_dict[el] += amt * factor
        f = f.replace(m.group(), '', 1)
    if f.strip():
        raise CompositionError(f'{f} is an invalid formula!')
    return sym_dict

ARGS = {
    'f': 'H2O',
    'factor': 2.5
}
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 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
label_with_model_dist Ran
ran on a synthesized input
avivne/bilinear-transduction/render_videos.py
code served (permissive licence) · get_code("99d97d743f9a2aac")
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 ndarray, ndim 3, dtype family int, shape (48, 64, 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 numpy as np
from PIL import Image
import PIL.ImageDraw as ImageDraw

# Create a small frame (numpy array representing an image)
# Using a 64x48 RGB image with values in range [0, 255]
frame = np.random.randint(0, 256, size=(48, 64, 3), dtype=np.uint8)

# Create a tag string
tag = "demos_bc_biLinear"

ARGS = {
    "frame": frame,
    "tag": tag,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
PIL, numpy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type ndarray, ndim 3, dtype family int, shape (48, 64, 3) — shape (48, 64, 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
load_eval_data Ran
ran on a synthesized input
learningmatter-mit/matex/blt/plot_maker/plots.py
code served (permissive licence) · get_code("842c29ed353636df")
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.

import pickle as pkl
import tempfile
import os
from collections import defaultdict

# Create a temporary directory for pickle files
temp_dir = tempfile.mkdtemp()

# Create sample evaluation data
sample_ood_data = {
    'preds': [[0.1, 0.9], [0.8, 0.2]],
    'gt': [1, 0]
}

sample_in_dist_data = {
    'preds': [[0.2, 0.8], [0.7, 0.3]],
    'gt': [1, 0]
}

# Write pickle files for bilinear method
bilinear_ood_file = os.path.join(temp_dir, 'bilinear_eval_ood.pkl')
bilinear_in_dist_file = os.path.join(temp_dir, 'bilinear_eval_in_dist.pkl')

with open(bilinear_ood_file, 'wb') as f:
    pkl.dump(sample_ood_data, f)

with open(bilinear_in_dist_file, 'wb') as f:
    pkl.dump(sample_in_dist_data, f)

# Define arguments for the function
ARGS = {
    'prop': 'accuracy',
    'path': temp_dir,
    'method': 'bilinear'
}
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 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
load_pkl Ran
ran on a synthesized input
avivne/bilinear-transduction/envs/adroit_wrapper.py
code served (permissive licence) · get_code("d370d73ba78229f9")
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 tempfile
import os

# Create a temporary pickle file with some test data
test_data = {
    'model_weights': [1, 2, 3, 4],
    'config': {'lr': 0.001, 'epochs': 10},
    'results': [0.95, 0.97, 0.98]
}

# Write the pickle file to a temporary location
temp_dir = tempfile.gettempdir()
temp_pkl_path = os.path.join(temp_dir, 'test_load_pkl.pkl')

with open(temp_pkl_path, 'wb') as f:
    pickle.dump(test_data, f)

ARGS = {
    'logpath': temp_pkl_path
}
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
load_pkl Ran
ran on a synthesized input
avivne/bilinear-transduction/utils/util.py
code served (permissive licence) · get_code("2b1c0d4b4deb30fb")
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 tempfile
import os

# Create a temporary pickle file with some test data
test_data = {
    'model_state': [1, 2, 3, 4],
    'metrics': {'loss': 0.5, 'accuracy': 0.95},
    'epoch': 10
}

# Create a temporary file and write pickle data to it
temp_file = tempfile.NamedTemporaryFile(mode='wb', delete=False, suffix='.pkl')
pickle.dump(test_data, temp_file)
temp_file.close()
logpath = temp_file.name

ARGS = {
    'logpath': logpath
}
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
mlp Ran
ran; our contract draft was wrong, not the code
avivne/bilinear-transduction/utils/networks.py
pointer only (licence: MIT); the stored copy get_code serves, from tianyucodings/diffusion_trusted_q_learning, is pointer only (licence: NONE) · get_code("db00dda8b96201d3")
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 tianyucodings/diffusion_trusted_q_learning, 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.

mlp Ran
ran; our contract draft was wrong, not the code
learningmatter-mit/matex/blt/utils/networks.py
code served (permissive licence) · get_code("ebb5e4d5764029a8")
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
import torch.nn as nn

torch.manual_seed(0)

ARGS = {
    "input_dim": 4,
    "hidden_dim": 8,
    "output_dim": 3,
    "hidden_depth": 2
}
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
parse_formula Ran
ran on a synthesized input
learningmatter-mit/matex/data_modules/data_utils.py
code served (permissive licence) · get_code("c6d7b87034c95886")
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.

import collections
import re

class CompositionError(Exception):
    """Exception class for composition errors"""
    pass

def get_sym_dict(f, factor):
    sym_dict = collections.defaultdict(float)
    regex = '([A-Z][a-z]*)\\s*([-*\\.\\d]*)'
    r = re.compile(regex)
    for m in re.finditer(r, f):
        el = m.group(1)
        amt = 1
        if m.group(2).strip() != '':
            amt = float(m.group(2))
        sym_dict[el] += amt * factor
        f = f.replace(m.group(), '', 1)
    if f.strip():
        raise CompositionError(f'{f} is an invalid formula!')
    return sym_dict

def parse_formula(formula):
    """
    Parameters
    ----------
        formula: str
            A string formula, e.g. Fe2O3, Li3Fe2(PO4)3.
    Return
    ----------
        sym_dict: dict
            A dictionary recording the composition of that formula.
    Notes
    ----------
        In the case of Metallofullerene formula (e.g. Y3N@C80),
        the @ mark will be dropped and passed to parser.
    """
    formula = formula.replace('@', '')
    formula = formula.replace('[', '(')
    formula = formula.replace(']', ')')
    regex = '\\(([^\\(\\)]+)\\)\\s*([\\.\\d]*)'
    r = re.compile(regex)
    m = re.search(r, formula)
    if m:
        factor = 1
        if m.group(2) != '':
            factor = float(m.group(2))
        unit_sym_dict = get_sym_dict(m.group(1), factor)
        expanded_sym = ''.join(['{}{}'.format(el, amt) for el, amt in unit_sym_dict.items()])
        expanded_formula = formula.replace(m.group(), expanded_sym)
        return parse_formula(expanded_formula)
    sym_dict = get_sym_dict(formula, 1)
    return sym_dict

# Test cases: simple formulas, formulas with numbers, formulas with parentheses
ARGS = {
    "formula": "Fe2O3"
}
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 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
train_policy Ran
ran on a synthesized input
avivne/bilinear-transduction/utils/trainer.py
code served (permissive licence) · get_code("475650877c1f12d0")
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. The image it ran in was not recorded. The code mentions cuda, and the harness aliases cuda to the CPU for every sample; whether this run needed that is 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 temporary directory for logging
logdir = tempfile.gettempdir()

# Define a simple policy for 'bc' model type
class BCPolicy(nn.Module):
    def __init__(self, state_dim=4, action_dim=3):
        super().__init__()
        self.fc = nn.Linear(state_dim, action_dim)
    
    def forward(self, states):
        return self.fc(states)

# Define a bilinear policy for 'bilinear' model type
class BilinearPolicy(nn.Module):
    def __init__(self, state_dim=4, action_dim=3, delta_dim=4):
        super().__init__()
        self.fc_state = nn.Linear(state_dim, 16)
        self.fc_delta = nn.Linear(delta_dim, 16)
        self.fc_out = nn.Linear(16, action_dim)
    
    def forward(self, states, deltas=None):
        if deltas is None:
            return self.fc_out(self.fc_state(states))
        state_feat = self.fc_state(states)
        delta_feat = self.fc_delta(deltas)
        combined = state_feat * delta_feat
        return self.fc_out(combined)

# Create demonstration data
state_dim = 4
action_dim = 3
horizon = 100
num_demos = 5

demos = []
for i in range(num_demos):
    demo = {
        'obs': np.random.randn(horizon, state_dim).astype(np.float32),
        'action': np.random.randn(horizon, action_dim).astype(np.float32)
    }
    demos.append(demo)

# Create policies for both model types
bc_policy = BCPolicy(state_dim=state_dim, action_dim=action_dim)
bilinear_policy = BilinearPolicy(state_dim=state_dim, action_dim=action_dim, delta_dim=state_dim)

ARGS = {
    'model_type': 'bc',
    'demos': demos,
    'policy': bc_policy,
    'logdir': logdir,
    'num_epochs': 2,
    'batch_size': 2,
    'horizon': horizon
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
matplotlib, numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple — a tuple 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
trajectory2vid Ran
ran on a synthesized input
avivne/bilinear-transduction/render_videos.py
code served (permissive licence) · get_code("a26a458b0dafceb3")
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 4, dtype family int; 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 numpy as np
import cv2
from PIL import Image

# Create a minimal mock environment that satisfies the function's usage
class MockEnv:
    def __init__(self, env_name):
        self.env_name = env_name
        self.sim = self
        
    def reset(self):
        return np.zeros(10)
    
    def reset_model_ood(self, goal_pos):
        return np.zeros(10)
    
    def set_goal(self, mass=None, goal_pos=None):
        return np.zeros(10)
    
    def step(self, action):
        obs = np.zeros(10)
        reward = 0.0
        done = False
        info = {}
        return obs, reward, done, info
    
    def render(self, width, height, mode='offscreen', camera_name=None):
        # Return BGR image (HxWx3)
        return np.random.randint(0, 256, (height, width, 3), dtype=np.uint8)

# Create a nested mock environment for adroit_scale case
class MockAdroitEnv:
    def __init__(self):
        self.env = self
        self.sim = self
    
    def reset(self):
        return np.zeros(10)
    
    def set_goal(self, goal_pos=None):
        return np.zeros(10)
    
    def step(self, action):
        obs = np.zeros(10)
        reward = 0.0
        done = False
        info = {}
        return obs, reward, done, info
    
    def render(self, width, height, mode='offscreen', camera_name=None):
        # Return RGB image (HxWx3)
        return np.random.randint(0, 256, (height, width, 3), dtype=np.uint8)

# Create trajectory dict with actions and observations
traj = {
    'action': [np.array([0.1, 0.2, 0.3]) for _ in range(5)],
    'obs': np.random.rand(6, 10)  # 6 timesteps, 10-dim observation
}

# Create environment
env_reach = MockEnv('reach-v2')

# Define ARGS
ARGS = {
    'env': env_reach,
    'traj': traj,
    'tag': 'demos_bc_biLinear',
    'env_name': 'reach-v2',
    'goal_idxs': [0, 1, 2],
    'resolution': (560, 420),
    'flip': False
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
PIL, cv2, numpy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type list, ndim 4, dtype family int — 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
writer_for Ran
ran on a synthesized input
avivne/bilinear-transduction/render_videos.py
code served (permissive licence) · get_code("91cfe51d6844f3a7")
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 VideoWriter. 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

log_dir = tempfile.mkdtemp()
tag = "test_video"
fps = 30
res = (640, 480)

ARGS = {
    "log_dir": log_dir,
    "tag": tag,
    "fps": fps,
    "res": res
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
cv2 — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type VideoWriter — a VideoWriter output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a VideoWriter 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_cbfv Not yet run
unverified (harvested, no recorded run)
learningmatter-mit/matex/data_modules/data_utils.py
code served (permissive licence) · get_code("4612728c27050322")
How it ran

no invocation recorded.

models_load Not yet run
unverified (harvested, no recorded run)
avivne/bilinear-transduction/utils/util.py
code served (permissive licence) · get_code("92bf21f9ae623c70")
How it ran

no invocation recorded.

modnet_preprocess Not yet run
unverified (harvested, no recorded run)
learningmatter-mit/matex/data_modules/data_process.py
code served (permissive licence) · get_code("4a1cb87336c382fe")
How it ran

no invocation recorded.

Also present in other papers' code

Of 20 samples lifted from this paper's linked repositories, 20 carry a function identity and 0 do not. Of the 19 distinct functions with an identity, 2 are also present in other papers whose code we hold (1 with at least one paper dated earlier, 0 the same month, 2 later) and 17 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
mlp 11 other papers
4 dated earlier, 7 later · 2 only as an assembly brick
1812.05905 (2018-12)
Soft Actor-Critic Algorithms and Applications
2004.13649 (2020-04)
Image Augmentation Is All You Need: Regularizing Deep Reinforcement Learning from Pixels
2110.04935 (2021-10)
Learning Temporally-Consistent Representations for Data-Efficient Reinforcement Learning
and 8 more not named here
mlp 1 other paper
1 later
2409.12514 (2024-09)
TinyVLA: Towards Fast, Data-Efficient Vision-Language-Action Models for Robotic Manipulation

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

Machine learning systems, especially with overparameterized deep neural networks, can generalize to novel test instances drawn from the same distribution as the training data. However, they fare poorly when evaluated on out-of-support test points. In this work, we tackle the problem of developing machine learning systems that retain the power of overparameterized function approximators while enabling extrapolation to out-of-support test points when possible. This is accomplished by noting that under certain conditions, a "transductive" reparameterization can convert an out-of-support extrapolation problem into a problem of within-support combinatorial generalization. We propose a simple strategy based on bilinear embeddings to enable this type of combinatorial generalization, thereby addressing the out-of-support extrapolation problem under certain conditions. We instantiate a simple, practical algorithm applicable to various supervised learning and imitation learning tasks.

For agents

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

get_harvested_code_for_paper("2304.14329")
get_code_for_paper("2304.14329")
have("2304.14329")

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

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

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

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

Connect an agent — have() is free.