| corrcoef |
Ran ran on a synthesized input |
ibm/multimodal-3d-image-segmentation/nets/custom_losses.py code served (permissive licence) · get_code("7e174dc6b463a5df") 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. 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 computes Pearson correlation coefficients
# It expects y_pred and y_true tensors with ndim in (3, 4, 5)
# The function reduces over dimensions [2:], so we need at least 3 dimensions
# batch_size=2, num_labels=4, and spatial dimensions for reduction
batch_size = 2
num_labels = 4
spatial_dim1 = 3
spatial_dim2 = 5
# Create 4D tensors (batch_size, num_labels, spatial_dim1, spatial_dim2)
y_pred = torch.randn(batch_size, num_labels, spatial_dim1, spatial_dim2)
y_true = torch.randn(batch_size, num_labels, spatial_dim1, spatial_dim2)
ARGS = {
"y_pred": y_pred,
"y_true": y_true,
}
- 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
|
| corrcoef |
Ran ran on a synthesized input |
ibm/multimodal-3d-image-segmentation/tensorflow/nets/custom_losses.py code served (permissive licence) · get_code("8c0f4545f7eb5aa7") 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 EagerTensor, ndim 2, dtype family float, shape (2, 5) 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 tensorflow as tf
import numpy as np
# Set seed for reproducibility
tf.random.set_seed(0)
np.random.seed(0)
# Create test tensors with shape (batch_size, spatial_dim1, spatial_dim2, num_labels)
# This is a 4D tensor as expected by the function (ndim=4 is valid per assertion)
batch_size = 2
spatial_dim1 = 3
spatial_dim2 = 4
num_labels = 5
y_true = tf.constant(
np.random.randn(batch_size, spatial_dim1, spatial_dim2, num_labels).astype(np.float32)
)
y_pred = tf.constant(
np.random.randn(batch_size, spatial_dim1, spatial_dim2, num_labels).astype(np.float32)
)
ARGS = {
"y_true": y_true,
"y_pred": y_pred,
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- numpy, tensorflow — import names as written, not package names to install; a name the repository itself provides is not a package
- Returned
- type EagerTensor, ndim 2, dtype family float, shape (2, 5) — shape (2, 5) 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
|
| dht2 |
Ran ran on a synthesized input |
ibm/multimodal-3d-image-segmentation/nets/dht.py code served (permissive licence) · get_code("a35f5fa643476fe2") 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 (2, 4, 3) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.
import torch
torch.manual_seed(0)
# Create a small input tensor with shape (batch=2, height=4, width=3)
# The function applies FFT over the last two dimensions (-2, -1)
x = torch.randn(2, 4, 3)
# is_inverse parameter: test with False (forward transform)
is_inverse = False
ARGS = {
'x': x,
'is_inverse': is_inverse,
}
- 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 3, dtype family float, shape (2, 4, 3) — shape (2, 4, 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
|
| dht3 |
Ran ran on a synthesized input |
ibm/multimodal-3d-image-segmentation/nets/dht.py code served (permissive licence) · get_code("9cdf8a087accb760") 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 4, dtype family float, shape (2, 4, 5, 6) 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 dht3 takes:
# - x: Input tensor (will be transformed over last 3 dimensions)
# - is_inverse: Boolean flag for inverse transform
# Create a small tensor with shape suitable for 3D transform
# Using distinct sizes: batch=2, then 3 spatial dims of sizes 4, 5, 6
x = torch.randn(2, 4, 5, 6)
ARGS = {
'x': x,
'is_inverse': False
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- torch — import names as written, not package names to install; a name the repository itself provides is not a package
- Returned
- type Tensor, ndim 4, dtype family float, shape (2, 4, 5, 6) — shape (2, 4, 5, 6) 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
|
| dhtn |
Ran ran on a synthesized input |
ibm/multimodal-3d-image-segmentation/nets/dht.py code served (permissive licence) · get_code("bb9a2c9ca1e9ce68") 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 (2, 4, 3) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.
import torch
torch.manual_seed(0)
# Create a small input tensor
# Shape: (batch=2, dim1=4, dim2=3) to have distinct dimensions
x = torch.randn(2, 4, 3)
# Dimensions to transform - can be a tuple of dimension indices
dim = (1, 2)
# Boolean flag for inverse transform
is_inverse = False
ARGS = {
'x': x,
'dim': dim,
'is_inverse': is_inverse
}
- 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 3, dtype family float, shape (2, 4, 3) — shape (2, 4, 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
|
| dice_binary |
Ran ran on a synthesized input |
ibm/multimodal-3d-image-segmentation/experiments/metrics.py code served (permissive licence) · get_code("69cccec0515e3734") 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 float64, ndim 0, 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 numpy as np
# Create two binary arrays for testing dice_binary
# y_true_bin: ground truth binary mask
# y_pred_bin: predicted binary mask
# Example 1: Some overlap between true and predicted
y_true_bin = np.array([1, 1, 0, 0, 1, 0], dtype=np.int32).reshape(2, 3)
y_pred_bin = np.array([1, 0, 0, 1, 1, 0], dtype=np.int32).reshape(2, 3)
ARGS = {
"y_true_bin": y_true_bin,
"y_pred_bin": y_pred_bin,
}
- 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: observe_signature.py recorded float ndim 0, which disagrees with the fixture run
- 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
|
| dice_coef |
Ran ran on a synthesized input |
ibm/multimodal-3d-image-segmentation/nets/custom_losses.py code served (permissive licence) · get_code("c0f7dcb15e62da45") 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, 3) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.
import torch
torch.manual_seed(0)
# Create small tensors for testing dice_coef
# The function expects y_pred and y_true to have ndim in (3, 4, 5)
# It sums over dimensions [2:], so we need at least 3 dimensions
# Let's use 4D tensors: (batch_size, num_labels, height, width)
batch_size = 2
num_labels = 3
height = 4
width = 5
# y_pred: prediction scores, shape (batch_size, num_labels, height, width)
y_pred = torch.rand(batch_size, num_labels, height, width)
# y_true: one-hot ground truth labels, same shape as y_pred
y_true = torch.randint(0, 2, (batch_size, num_labels, height, width)).float()
ARGS = {
"y_pred": y_pred,
"y_true": y_true,
}
- 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, 3) — shape (2, 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
|
| dice_coef |
Ran ran on a synthesized input |
ibm/multimodal-3d-image-segmentation/tensorflow/nets/custom_losses.py code served (permissive licence) · get_code("a28ccf455345f250") 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 EagerTensor, ndim 2, dtype family float, shape (2, 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 tensorflow as tf
import numpy as np
# Set seed for reproducibility
tf.random.set_seed(0)
# Create small tensors for testing
batch_size = 2
num_labels = 3
spatial_dim = 4
# For a 3D case (ndim=3): shape should be (batch_size, spatial, num_labels)
y_true = tf.constant(
np.random.randint(0, 2, size=(batch_size, spatial_dim, num_labels)),
dtype=tf.float32
)
y_pred = tf.constant(
np.random.uniform(0, 1, size=(batch_size, spatial_dim, num_labels)),
dtype=tf.float32
)
ARGS = {
"y_true": y_true,
"y_pred": y_pred,
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- numpy, tensorflow — import names as written, not package names to install; a name the repository itself provides is not a package
- Returned
- type EagerTensor, ndim 2, dtype family float, shape (2, 3) — shape (2, 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
|
| get_reverse |
Ran ran on a synthesized input |
ibm/multimodal-3d-image-segmentation/nets/hartley_operator.py code served (permissive licence) · get_code("438db1ab4cce15b9") 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 (2, 4, 3) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.
import torch
torch.manual_seed(0)
# Create a small input tensor
x = torch.randn(2, 4, 3)
# Define dims as a list of dimensions to reverse and roll
dims = [1, 2]
ARGS = {
"x": x,
"dims": dims
}
- 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 3, dtype family float, shape (2, 4, 3) — shape (2, 4, 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
|
| get_spatial_padcrop |
Ran ran on a synthesized input |
ibm/multimodal-3d-image-segmentation/nets/nets_utils.py code served (permissive licence) · get_code("54c46b96c5bc7e74") 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
torch.manual_seed(0)
# Create a small tensor with batch and spatial dimensions
# Shape: (batch=2, channels=3, height=4, width=5)
x = torch.randn(2, 3, 4, 5)
# Define target shape for spatial dimensions only (height, width)
target_shape = [6, 7]
ARGS = {
"x": x,
"target_shape": target_shape,
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- torch — import names as written, not package names to install; a name the repository itself provides is not a package
- Returned
- type tuple, ndim 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
|
| grouping2d |
Ran ran on a synthesized input |
ibm/multimodal-3d-image-segmentation/nets/hartley_mha.py code served (permissive licence) · get_code("5eb6566103ab65ba") 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 5, dtype family float, shape (2, 3, 24, 4, 2) 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 arguments for grouping2d function
# x: Input tensor of shape (batch_size, num_heads, num_channels, height, width)
# patch_size: Tuple of (patch_h, patch_w)
batch_size = 2
num_heads = 3
num_channels = 4
height = 8
width = 6
patch_h = 2
patch_w = 3
x = torch.randn(batch_size, num_heads, num_channels, height, width)
patch_size = (patch_h, patch_w)
ARGS = {
"x": x,
"patch_size": patch_size,
}
- 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 5, dtype family float, shape (2, 3, 24, 4, 2) — shape (2, 3, 24, 4, 2) 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
|
| grouping3d |
Ran ran on a synthesized input |
ibm/multimodal-3d-image-segmentation/nets/hartley_mha.py code served (permissive licence) · get_code("19d38b4c1b50a3dd") 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 6, dtype family float, shape (2, 3, 120, 4, 2, 2) 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:
# - x: tensor of shape (batch_size, num_heads, num_channels, depth, height, width)
# - patch_size: tuple/list of 3 integers (patch_d, patch_h, patch_w)
# Create a small input tensor
# Using distinct sizes: batch=2, num_heads=3, channels=4, depth=8, height=6, width=10
batch_size = 2
num_heads = 3
num_channels = 4
depth = 8
height = 6
width = 10
x = torch.randn(batch_size, num_heads, num_channels, depth, height, width)
# Patch size must divide the spatial dimensions evenly
# depth=8 divisible by 2, height=6 divisible by 3, width=10 divisible by 5
patch_size = (2, 3, 5)
ARGS = {
"x": x,
"patch_size": patch_size
}
- 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 6, dtype family float, shape (2, 3, 120, 4, 2, 2) — shape (2, 3, 120, 4, 2, 2) 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
|
| hartley_conv |
Ran ran on a synthesized input |
ibm/multimodal-3d-image-segmentation/nets/hartley_operator.py code served (permissive licence) · get_code("21a07b6a8cfc8b0c") 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 (4, 2) 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 numpy as np
torch.manual_seed(0)
# Construct small tensors for Hartley convolution
# The function uses einsum with weight and x, so we need compatible shapes
# Create weight matrix: shape (4, 3) - represents a kernel
weight = torch.randn(4, 3)
# Create weight_reverse: weight with frequency axes reversed
# For a 2D tensor, reverse means flip along the last dimensions
weight_reverse = torch.flip(weight, dims=[-1])
# Create data x: shape (2, 3) - batch of 2, feature dim 3
x = torch.randn(2, 3)
# Create x_reverse: x with frequency axes reversed
x_reverse = torch.flip(x, dims=[-1])
# Create an einsum equation that works with these shapes
# weight: (4, 3), x or x±x_reverse: (2, 3)
# We want output in frequency domain
# A valid equation could be 'ij,kj->ik' which contracts on the j dimension
equation = 'ij,kj->ik'
ARGS = {
'equation': equation,
'weight': weight,
'weight_reverse': weight_reverse,
'x': x,
'x_reverse': x_reverse
}
- 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 Tensor, ndim 2, dtype family float, shape (4, 2) — shape (4, 2) 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
|
| normalize_modalities |
Ran ran on a synthesized input |
ibm/multimodal-3d-image-segmentation/experiments/utils.py code served (permissive licence) · get_code("98138151a337f841") 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 ndarray, ndim 3, dtype family float, shape (3, 4, 5) 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
import torch
torch.manual_seed(0)
# Create multichannel input data in channel-first format
# Shape: (num_channels, height, width) = (3, 4, 5)
data = np.random.randn(3, 4, 5).astype(np.float32)
# Define arguments for normalize_modalities
ARGS = {
"data": data,
"mask_val": None,
"clip_val": None,
}
- 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 ndarray, ndim 3, dtype family float, shape (3, 4, 5) — shape (3, 4, 5) 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
|
| pcc_loss |
Ran ran on a synthesized input |
ibm/multimodal-3d-image-segmentation/tensorflow/nets/custom_losses.py code served (permissive licence) · get_code("21672f9602e64a31") 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 EagerTensor, ndim 1, dtype family float, shape (2,) 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 tensorflow as tf
import numpy as np
# Set seed for reproducibility
tf.random.set_seed(0)
np.random.seed(0)
# Create small test tensors
# y_true and y_pred should have shape (batch_size, spatial_dims..., num_labels)
# For 3D case: (batch_size, depth, height, width, num_labels)
batch_size = 2
num_labels = 4
spatial_dim = 3
# 3D case: shape (batch_size, depth, height, width, num_labels)
y_true = tf.constant(
np.random.randn(batch_size, spatial_dim, spatial_dim, spatial_dim, num_labels),
dtype=tf.float32
)
y_pred = tf.constant(
np.random.randn(batch_size, spatial_dim, spatial_dim, spatial_dim, num_labels),
dtype=tf.float32
)
ARGS = {
"y_true": y_true,
"y_pred": y_pred,
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- numpy, tensorflow — import names as written, not package names to install; a name the repository itself provides is not a package
- Returned
- type EagerTensor, ndim 1, dtype family float, shape (2,) — shape (2,) 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
|
| spatial_padcrop |
Ran ran on a synthesized input |
ibm/multimodal-3d-image-segmentation/nets/nets_utils.py code served (permissive licence) · get_code("478c218f97db90f1") 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 4, dtype family float, shape (2, 4, 6, 8) 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)
# Test case 1: 3D tensor (batch, channel, width) with padding needed
x_3d = torch.randn(2, 4, 5)
target_shape_3d = [8]
# Test case 2: 4D tensor (batch, channel, height, width) with cropping needed
x_4d = torch.randn(2, 4, 10, 12)
target_shape_4d = [6, 8]
# Test case 3: 5D tensor (batch, channel, depth, height, width) with mixed padding/cropping
x_5d = torch.randn(2, 4, 7, 9, 11)
target_shape_5d = [8, 10, 12]
# Use the 4D case as primary test
ARGS = {
"x": x_4d,
"target_shape": target_shape_4d,
}
- Setup block drafted by
- a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
- Imports
- torch — import names as written, not package names to install; a name the repository itself provides is not a package
- Returned
- type Tensor, ndim 4, dtype family float, shape (2, 4, 6, 8) — shape (2, 4, 6, 8) 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
|
| to_categorical |
Ran ran on a synthesized input |
ibm/multimodal-3d-image-segmentation/experiments/utils.py code served (permissive licence) · get_code("c448fb68d0f2e025") 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 5, dtype family float, shape (2, 5, 4, 3, 2) 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)
# Create a small label tensor with shape (B, 1, D, H, W)
# B=2 (batch), 1 (single label), D=4, H=3, W=2
y = torch.randint(0, 5, (2, 1, 4, 3, 2), dtype=torch.int32)
# num_classes can be inferred from max value or explicitly set
num_classes = 5
ARGS = {
'y': y,
'num_classes': num_classes
}
- 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 5, dtype family float, shape (2, 5, 4, 3, 2) — shape (2, 5, 4, 3, 2) 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
|
| upsampling |
Ran ran on a synthesized input |
ibm/multimodal-3d-image-segmentation/nets/architectures.py code served (permissive licence) · get_code("e3e49350747f516f") 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 5, 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 torch.nn as nn
torch.manual_seed(0)
# Create a dict of tensors with different spatial sizes
# Key 0 is the reference (largest) tensor
# The function will upsample all tensors to match its spatial size
tensors = {
0: torch.randn(2, 4, 8, 8), # batch=2, channels=4, height=8, width=8 (reference/largest)
1: torch.randn(2, 4, 4, 4), # batch=2, channels=4, height=4, width=4 (smaller)
2: torch.randn(2, 4, 2, 2), # batch=2, channels=4, height=2, width=2 (smallest)
}
ARGS = {
"tensors": tensors
}
- 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 5, 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
|
| normalize_data |
Not yet run unverified (harvested, no recorded run) |
ibm/multimodal-3d-image-segmentation/experiments/utils.py code served (permissive licence) · get_code("75b9413017c2330b") How it ran |
| ungrouping2d |
Not yet run unverified (harvested, no recorded run) |
ibm/multimodal-3d-image-segmentation/nets/hartley_mha.py code served (permissive licence) · get_code("2ba406a7b5e08d61") How it ran |