| average_score |
Ran ran on a synthesized input |
eric-ai-lab/dsd/dsd_infer.py code served (permissive licence) · get_code("4294cf0378461ad2") How it ranRan 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 float, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.
import torch
torch.manual_seed(0)
# The function expects tensor_lists: a list of lists of tensor containers
# Each tensor_container should support indexing with [0] to get a tensor
# The tensor will have torch.mean() called on it
# Create some simple tensor containers (can be lists or tuples)
tensor_container_1 = [torch.randn(2, 4)]
tensor_container_2 = [torch.randn(2, 4)]
tensor_container_3 = [torch.randn(2, 4)]
# Create inner lists containing these containers
inner_list_1 = [tensor_container_1, tensor_container_2]
inner_list_2 = [tensor_container_3]
# Create the main tensor_lists structure
tensor_lists = [inner_list_1, inner_list_2]
ARGS = {
"tensor_lists": tensor_lists
}
- 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 float, 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
|
| average_score |
Ran ran on a synthesized input |
eric-ai-lab/dsd/dsd_train.py code served (permissive licence) · get_code("0ca47b5cf6386db5") How it ranRan in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned Tensor, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.
import torch
torch.manual_seed(0)
# Analyzing the function:
# - tensor_lists is iterated over (outer loop)
# - For each inner_list in tensor_lists, we iterate
# - For each tensors in inner_list, we iterate
# - For each tensor in tensors, we call torch.mean(tensor[0])
# - tensor[0] means we need tensors to be indexable and have at least 1 element
# - We need to build a nested structure: list of lists of lists of tensors
# Structure: tensor_lists -> list
# inner_list -> list
# tensors -> list
# tensor -> torch.Tensor with at least 1 element
# Creating small tensors
tensor1 = torch.randn(2, 4) # 2D tensor
tensor2 = torch.randn(3, 4) # different first dim
tensor3 = torch.randn(2, 5) # different second dim
# Building the nested structure
# tensor_lists is a list of inner_lists
# Each inner_list is a list of tensors_lists
# Each tensors_list is a list of tensors
tensor_lists = [
[ # inner_list 1
[tensor1, tensor2], # tensors 1
[tensor3], # tensors 2
],
[ # inner_list 2
[torch.randn(4, 3)], # tensors 3
],
]
ARGS = {
"tensor_lists": tensor_lists
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- torch — import names as written, not package names to install; a name the repository itself provides is not a package
- Returned
- type Tensor, ndim 0, dtype family float, shape () — shape () as a later run recorded it
- dtype family
- int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
- Environment
- image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
|
| compute_loss |
Ran ran on a synthesized input |
eric-ai-lab/dsd/utils/losses.py code served (permissive licence) · get_code("2aa969a20b25a144") How it ranRan in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned Tensor, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.
import torch
torch.manual_seed(0)
# Construct valid arguments for compute_loss function
# The function expects:
# - args: some object (not directly used in function body)
# - scores: a tensor of shape (batch_size, num_items) with scores
# - img_idx: an integer (though it's overwritten to 0 in function)
# - margin: a float (default 0.2)
# Create a small scores tensor: batch_size=2, num_items=4
scores = torch.randn(2, 4)
# args is not used in the function body, so we can pass any object
args = None
# img_idx is overwritten to 0 in the function, but we provide it anyway
img_idx = 1
# margin has a default value, but we can explicitly set it
margin = 0.2
ARGS = {
"args": args,
"scores": scores,
"img_idx": img_idx,
"margin": margin,
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- torch — import names as written, not package names to install; a name the repository itself provides is not a package
- Returned
- type Tensor, ndim 0, dtype family float, shape () — shape () as a later run recorded it
- dtype family
- int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
- Environment
- image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
|
| compute_score |
Ran ran on a synthesized input |
eric-ai-lab/dsd/utils/losses.py code served (permissive licence) · get_code("5bc35c622beca1cc") How it ranRan 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. 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, 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)
class MockModel(nn.Module):
def __init__(self):
super().__init__()
self.linear = nn.Linear(4, 2)
def forward(self, prompt, image, guidance_scale, sampling_steps, layer_mask, use_bias, sampled_timestep, level):
# Return a score tensor of shape (batch_size,)
batch_size = image.shape[0]
return torch.randn(batch_size)
class MockArgs:
def __init__(self):
self.guidance_scale = 7.5
self.sampling_time_steps = 50
self.bias = True
# Create mock batch with structure: (imgs, texts)
# imgs = (img_names, imgs_resize)
# imgs_resize is a list of tensors
# texts is a list of tuples, each containing text strings
img_names = ["image_1.jpg", "image_2.jpg"]
imgs_resize = [
torch.randn(2, 3, 32, 32), # batch_size=2, channels=3, height=32, width=32
torch.randn(2, 3, 64, 64), # different size for distinction
]
texts = [
("hello world",),
("another test",),
]
imgs = (img_names, imgs_resize)
batch = (imgs, texts)
ARGS = {
"i": 0,
"args": MockArgs(),
"batch": batch,
"model": MockModel(),
"save_path": "./saved_images"
}
- 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
|
| evaluate_comvg |
Ran ran on a synthesized input |
eric-ai-lab/dsd/eval_score.py code served (permissive licence) · get_code("61dde694c9bb23c2") How it ranRan 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 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 torch
import numpy as np
torch.manual_seed(0)
# Construct arguments for evaluate_comvg
# The function takes args, scores, and img_idx
# args: appears to be unused in the function body, so a simple dict works
args = {}
# scores: can be either a list of arrays or a torch tensor
# The function checks type(scores) != list
# If not a list, it calls .detach().cpu().numpy() and .cpu().numpy()
# Then it does np.stack(scores, axis=0)
# For each row i, it compares img_idx[i] with np.argmax(scores[i])
# Let's create scores as a torch tensor (batch_size=2, num_classes=4)
scores = torch.randn(2, 4)
# img_idx: should be a tensor or array that can be indexed
# It needs to have length matching scores.shape[0]
# Values should be class indices (0 to 3 for 4 classes)
img_idx = torch.tensor([0, 2])
ARGS = {
'args': args,
'scores': scores,
'img_idx': img_idx
}
- 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 list, ndim 1, 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
|
| evaluate_retrieval |
Ran ran on a synthesized input |
eric-ai-lab/dsd/eval_score.py code served (permissive licence) · get_code("3c5ed43dcafc5436") How it ranRan 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 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 torch
import numpy as np
torch.manual_seed(0)
# Create sample arguments for evaluate_retrieval
# args: can be any object, the function doesn't use it
args = {}
# scores: can be either a list of arrays or a torch tensor
# The function checks `if type(scores) != list`, so we'll test with a tensor
# Shape: (batch_size=2, num_candidates=4)
scores = torch.randn(2, 4)
# img_idx: indices that will be compared with argmax/argsort results
# Should be array-like or tensor with shape (batch_size=2,)
img_idx = torch.tensor([1, 2])
ARGS = {
"args": args,
"scores": scores,
"img_idx": img_idx,
}
- 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 2, dtype family int — 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
|
| evaluate_vqa |
Ran ran on a synthesized input |
eric-ai-lab/dsd/eval_score.py code served (permissive licence) · get_code("e1b88fc15ff00272") How it ranRan 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 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 torch
import numpy as np
torch.manual_seed(0)
# Construct arguments for evaluate_vqa
args = {}
# scores: can be a list of numpy arrays or a torch tensor
scores = torch.randn(2, 5) # batch_size=2, num_scores=5
# img_idx: indices that should match argmax or be in top-5
img_idx = torch.tensor([1, 3])
ARGS = {
'args': args,
'scores': scores,
'img_idx': img_idx
}
- 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 2, dtype family int — 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_timesteps |
Ran ran on a synthesized input |
eric-ai-lab/dsd/dsd_train.py code served (permissive licence) · get_code("9f228a3f87edcf83") How it ranRan 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. 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)
class MockScheduler:
def __init__(self):
# Create timesteps tensor - the function indexes into this
self.timesteps = torch.tensor([999, 799, 599, 399, 199, 99, 49, 0])
self.order = 1
class MockPipeline:
def __init__(self):
self.scheduler = MockScheduler()
def get_timesteps(self, num_inference_steps, strength, device):
init_timestep = min(int(num_inference_steps * strength), num_inference_steps)
t_start = max(num_inference_steps - init_timestep, 0)
timesteps = self.scheduler.timesteps[t_start * self.scheduler.order:]
return (timesteps, num_inference_steps - t_start)
# Create instance and prepare arguments
pipeline = MockPipeline()
ARGS = {
"self": pipeline,
"num_inference_steps": 50,
"strength": 0.75,
"device": "cpu"
}
- 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 — 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
|
| get_train_dataset |
Ran ran on a synthesized input |
eric-ai-lab/dsd/custom_datasets.py code served (permissive licence) · get_code("be7a240b9dcc2368") How it ranRan 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. 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 pandas as pd
import numpy as np
from PIL import Image
import io
import torchvision.transforms as transforms
torch.manual_seed(0)
# Create stand-in functions that are called in the dataset
def tokenize(text):
return torch.tensor([1, 2, 3])
class Relation:
def __init__(self):
self.predicate = "on"
def get_sub_name(self):
return "cat"
def get_obj_name(self):
return "table"
def get_predicate(self):
return "on"
def read_relation(relation_filename, image_id, relation_idx):
return Relation()
def prepare_cropped_image(image, relation, with_black):
# Return cropped images
if with_black:
return image, image, image, None
else:
return image, image
# Create minimal pickle file content - a DataFrame with required columns
def create_test_dataframe():
data = {
'text': ["cat on table"],
'image_id': [1],
'relation_json_path': ["dummy_path.json"],
'relation_idx': [0]
}
return pd.DataFrame(data)
# Create a small test image
def create_test_image():
img = Image.new('RGB', (64, 64), color='red')
return img
# Create mock pickle file by storing DataFrame
text_df = create_test_dataframe()
# Create temporary directories and files
import tempfile
import os
temp_dir = tempfile.mkdtemp()
relationship_dir = os.path.join(temp_dir, "relationships")
image_dir = os.path.join(temp_dir, "images")
os.makedirs(relationship_dir, exist_ok=True)
os.makedirs(image_dir, exist_ok=True)
# Save test image
test_img = create_test_image()
test_img.save(os.path.join(image_dir, "1.jpg"))
# Save DataFrame as pickle
text_csv_path = os.path.join(temp_dir, "text_data.pkl")
text_df.to_pickle(text_csv_path)
# Create args object
class Args:
def __init__(self):
self.relation_folder = relationship_dir
self.text_path = text_csv_path
self.image_folder = image_dir
self.with_black = True
ARGS = {
'args': Args()
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- PIL, numpy, pandas, torch, torchvision — 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
|
| image_preprocess |
Ran ran on a synthesized input |
eric-ai-lab/dsd/playground.py code served (permissive licence) · get_code("3cacd5275cbd348c") How it ranRan in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned Tensor, ndim 3, dtype family float, shape (3, 96, 96) 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
from PIL import Image
import numpy as np
torch.manual_seed(0)
# Create a small test image using PIL
# The function expects a PIL Image object
# Make it slightly larger than 32 pixels so the resize logic has an effect
test_image = Image.new('RGB', (100, 96), color=(128, 64, 200))
ARGS = {
'image': test_image
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- PIL, numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
- Returned
- type Tensor, ndim 3, dtype family float, shape (3, 96, 96) — shape (3, 96, 96) 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
|
| image_preprocess |
Ran ran on a synthesized input |
eric-ai-lab/dsd/utils/process_dataset.py code served (permissive licence) · get_code("831f5bc2bdeba8c9") How it ranRan in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned Tensor, ndim 3, dtype family float, shape (3, 96, 128) 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
import numpy as np
import PIL.Image
torch.manual_seed(0)
# Create a small test image using PIL
# The function expects a PIL Image object with .size attribute and .resize method
image_array = np.random.randint(0, 256, (96, 128, 3), dtype=np.uint8)
image = PIL.Image.fromarray(image_array, mode='RGB')
ARGS = {
'image': image
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- PIL, numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
- Returned
- type Tensor, ndim 3, dtype family float, shape (3, 96, 128) — shape (3, 96, 128) 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_json |
Ran ran on a synthesized input |
eric-ai-lab/dsd/utils/helper_functions.py code served (permissive licence) · get_code("02a978e30e225398") How it ranRan 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 json
import tempfile
import os
# Create a temporary JSON file with sample content
temp_dir = tempfile.mkdtemp()
temp_file = os.path.join(temp_dir, "test.json")
sample_data = {
"key1": "value1",
"key2": 42,
"key3": [1, 2, 3],
"nested": {"inner": "data"}
}
with open(temp_file, 'w') as f:
json.dump(sample_data, f)
ARGS = {
"filename": temp_file
}
- 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
|
| next_available_dirpath |
Ran ran on a synthesized input |
eric-ai-lab/dsd/dsd_infer.py code served (permissive licence) · get_code("03616619ada8dbef") How it ranRan 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 os
import tempfile
import shutil
# Create a temporary directory for testing
temp_base = tempfile.mkdtemp()
# The function takes a target_dir parameter (string path)
# It checks if the directory exists using os.path.exists()
# and constructs new directory paths by appending indices
# We need to provide a path that may or may not exist
target_dir = os.path.join(temp_base, "test_dir")
ARGS = {
"target_dir": target_dir
}
- 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 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
|
| read_svo |
Ran ran on a synthesized input |
eric-ai-lab/dsd/utils/helper_functions.py code served (permissive licence) · get_code("248696bec32990b5") How it ranRan 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.
from nltk.stem import PorterStemmer
svo = "running,jumps,quickly"
stemmer = PorterStemmer()
ARGS = {
"svo": svo,
"stemmer": stemmer
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- nltk — 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
|
| sanitize_text |
Ran ran on a synthesized input |
eric-ai-lab/dsd/dsd_infer.py code served (permissive licence) · get_code("fc89a1b3e420c811") How it ranRan 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 re
def sanitize_text(text):
text = re.sub('[^\\w\\s]', '', text)
text = text.replace(' ', '_')
return text[:50]
ARGS = {
'text': 'Hello, World! This is a test string with special characters @#$%.'
}
- 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 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
|
| show_cropped_image |
Ran ran on a synthesized input |
eric-ai-lab/dsd/utils/helper_functions.py code served (permissive licence) · get_code("42c588f76987fa6f") How it ranRan 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 Image. 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 tempfile
from PIL import Image
import os
# Create a temporary image file for testing
temp_dir = tempfile.mkdtemp()
temp_image_path = os.path.join(temp_dir, "test_image.png")
# Create a simple test image (100x100 RGB image)
test_image = Image.new('RGB', (100, 100), color='red')
test_image.save(temp_image_path)
# Define arguments for the function
ARGS = {
'path': temp_image_path,
'location': (10, 20, 30, 40), # x=10, y=20, w=30, h=40
'show': False
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- PIL — import names as written, not package names to install; a name the repository itself provides is not a package
- Returned
- type Image — a Image output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a Image output the recorded ndim 3 and dtype family int 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_full_repo_name |
Not yet run unverified (harvested, no recorded run) |
eric-ai-lab/dsd/dsd_train.py pointer only (licence: MIT); the stored copy get_code serves, from isno0907/isodiff, is pointer only (licence: NONE) · get_code("6431708d8f3ff177") How it ranThe 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 isno0907/isodiff, 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. No invocation recorded. |
| normalize_word |
Not yet run unverified (harvested, no recorded run) |
eric-ai-lab/dsd/utils/glossary.py code served (permissive licence) · get_code("8f1a44ab20956301") How it ran |
| preprocess |
Not yet run unverified (harvested, no recorded run) |
eric-ai-lab/dsd/diffusers/src/diffusers/pipelines/stable_diffusion/pipeline_dsd.py code served (permissive licence) · get_code("be2fda5ca6ae10b0") How it ran |
| process_word |
Not yet run unverified (harvested, no recorded run) |
eric-ai-lab/dsd/utils/glossary.py code served (permissive licence) · get_code("c04400bfa2c2f6e0") How it ran |