SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 1411.4555 · 2014

Show and Tell: A Neural Image Caption Generator

arXiv · PDF · Open in the Atlas

Code that ran

28 of 34 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; 2 honoured the contract we drafted, 4 violated it and 11 have no contract verdict; 11 failures of our instrument; 6 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/1411.4555.json · badge: /api/ran/1411.4555.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
Cathy-t/HELLO_image community (classifier label)
classifier basis not recorded on the link
7 ran · 2 no recorded run
guptakhil12/show-tell community (classifier label)
classifier basis not recorded on the link
3 ran · 0 no recorded run
fanchenyou/deepdiary reimplementation (classifier label)
classifier basis: classifier_2025
3 ran · 0 no recorded run
nicolafan/image-captioning-cnn-rnn community (classifier label)
classifier basis not recorded on the link
2 ran · 2 no recorded run
Djmcflush/Quantum-Hackathon extension (classifier label)
classifier basis: classifier_2025
2 ran · 1 no recorded run
Mrnoorsingh/image-caption reimplementation (classifier label)
classifier basis: classifier_2025
2 ran · 0 no recorded run
NicholasKX/ShowAndTell community (classifier label)
classifier basis not recorded on the link
2 ran · 0 no recorded run
yurayli/image-caption-pytorch reimplementation (classifier label)
classifier basis: classifier_2025
2 ran · 0 no recorded run
kirbiyik/caption-it community (classifier label)
classifier basis not recorded on the link
1 ran · 0 no recorded run
nithishkaviyan/Show-and-Tell-Neural-Network-Image-Caption-Generator- reimplementation (classifier label)
classifier basis: classifier_2025
1 ran · 0 no recorded run
jazzsaxmafia/show_and_tell.tensorflow community (classifier label)
classifier basis not recorded on the link
1 ran · 0 no recorded run
pskrunner14/descriptor reimplementation (classifier label)
classifier basis: classifier_2025
1 ran · 0 no recorded run
yuyay/chainer_nic community (classifier label)
classifier basis not recorded on the link
1 ran · 0 no recorded run
Chloejay/image_caption_app reimplementation (classifier label)
classifier basis: classifier_2025
0 ran · 1 no recorded run
FunctionStatusWhere it lives
allowed_file Ran
ran, violated the contract we drafted
kirbiyik/caption-it/caption.py
code served (permissive licence) · get_code("e8ee54a0610e9634")
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 bool, 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.

# Construct arguments for allowed_file function
# The function takes a filename (string) and checks if its extension is in ALLOWED_EXTENSIONS

ARGS = {
    'filename': 'image.png'
}
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 bool, 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
attention Ran
ran; our contract draft was wrong, not the code
Cathy-t/HELLO_image/model.py
code served (permissive licence) · get_code("d3feb7c8293a8cfd")
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. 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 math

torch.manual_seed(0)

# Build small tensors for attention mechanism
# query, key, value have shape (batch_size, seq_len, d_k)
batch_size = 2
seq_len = 3
d_k = 4

query = torch.randn(batch_size, seq_len, d_k)
key = torch.randn(batch_size, seq_len, d_k)
value = torch.randn(batch_size, seq_len, d_k)

# Optional mask: shape (batch_size, seq_len, seq_len)
# 1 means attend, 0 means mask out
mask = torch.ones(batch_size, seq_len, seq_len)

# Optional dropout layer
dropout = nn.Dropout(p=0.1)

ARGS = {
    "query": query,
    "key": key,
    "value": value,
    "mask": mask,
    "dropout": dropout
}
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
beam_search Ran
ran on a synthesized input
guptakhil12/show-tell/beam_search.py
code served (permissive licence) · get_code("3b20293ce047ab05")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned list, ndim 1, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import numpy as np

def initial_state_fn(X):
    """Returns a 2D numpy array with shape (1, 4) representing decoder state."""
    return np.random.randn(1, 4).astype(np.float32)

def generate_fn(X, Y_tm1, state_tm1):
    """
    Takes X (encoder input), Y_tm1 (previous token ids), state_tm1 (previous states).
    Returns state_t, p_t (probabilities), and extras_t.
    """
    batch_size = len(Y_tm1)
    vocab_size = 10
    
    # state_t: 2D array of shape (batch_size, 4)
    state_t = np.random.randn(batch_size, 4).astype(np.float32)
    
    # p_t: 2D array of shape (batch_size, vocab_size) with probabilities
    p_t = np.random.dirichlet(np.ones(vocab_size), size=batch_size).astype(np.float32)
    
    # extras_t: list of extras (one per batch element)
    extras_t = [None] * batch_size
    
    return state_t, p_t, extras_t

ARGS = {
    'initial_state_function': initial_state_fn,
    'generate_function': generate_fn,
    'X': np.array([1, 2, 3, 4, 5], dtype=np.int32),
    'start_id': 0,
    'end_id': 9,
    'beam_width': 3,
    'num_hypotheses': 1,
    'max_length': 10,
}
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 list, ndim 1, dtype family float — a list output has no array shape of its own; none is stated
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
bleu Ran
ran on a synthesized input
nicolafan/image-captioning-cnn-rnn/src/models/metrics.py
code served (permissive licence) · get_code("f1bf9ccad2d63845")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned list, ndim 1, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import nltk

# Download required NLTK data
nltk.download('punkt', quiet=True)

# Construct arguments for the bleu function
captions_true = [
    "a dog is running in the park",
    "the cat is sleeping on the mat"
]

caption_pred = "a dog is running in the park"

ARGS = {
    "captions_true": captions_true,
    "caption_pred": caption_pred
}
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 list, ndim 1, dtype family float — a list output has no array shape of its own; none is stated
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
build_vocab Ran
ran; our contract draft was wrong, not the code
Mrnoorsingh/image-caption/ImageCaption.py
pointer only (licence: NONE) · get_code("6fa2f3770918589b")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, Mrnoorsingh/image-caption 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.

clones Ran
ran; our contract draft was wrong, not the code
Cathy-t/HELLO_image/model.py
pointer only (licence: MIT); the stored copy get_code serves, from pawn-sxy/DCAMA, is pointer only (licence: NONE) · get_code("84ee72bc513b03f8")
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 pawn-sxy/DCAMA, 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.

collate_fn Ran
ran; our contract draft was wrong, not the code
nithishkaviyan/Show-and-Tell-Neural-Network-Image-Caption-Generator-/COCO_Final_Code.py
pointer only (licence: NONE) · get_code("1332e67cdbc4c88a")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, nithishkaviyan/Show-and-Tell-Neural-Network-Image-Caption-Generator- 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.

collate_fn Ran
ran; our contract draft was wrong, not the code
Cathy-t/HELLO_image/caption/data_loader.py
code served (permissive licence) · get_code("57c560e03a5007e8")
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. 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.utils.data as data

torch.manual_seed(0)

# Create sample data: list of tuples (image, caption)
# image: torch tensor of shape (3, 256, 256)
# caption: torch tensor of shape (variable length)

# Sample 1: image (3, 256, 256), caption length 5
image1 = torch.randn(3, 256, 256)
caption1 = torch.tensor([1, 2, 3, 4, 5])

# Sample 2: image (3, 256, 256), caption length 3
image2 = torch.randn(3, 256, 256)
caption2 = torch.tensor([10, 11, 12])

# Create the data list
sample_data = [(image1, caption1), (image2, caption2)]

ARGS = {
    "data": sample_data
}
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
convert_json_key Ran
ran on a synthesized input
NicholasKX/ShowAndTell/dataset.py
code served (permissive licence) · get_code("49c5d3755926b6ef")
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.

# Analyze the function: convert_json_key takes a dict where keys might be strings
# representing integers, and recursively converts string keys to int keys where possible.
# It handles nested dicts and preserves non-convertible keys as strings.

# Create test cases for the function
ARGS = {
    "param_dict": {
        "1": 100,
        "2": 200,
        "3": {
            "10": "nested_value",
            "11": 999,
            "name": "keep_as_string"
        },
        "regular_string_key": "should_stay_string",
        "4": {
            "50": {
                "100": "deeply_nested"
            }
        }
    }
}
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
create_batch Ran
ran on a synthesized input
guptakhil12/show-tell/utils.py
code served (permissive licence) · get_code("ed75cf97c296beab")
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. 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

torch.manual_seed(0)

# The function expects data to be a list of tuples: (image_path, image_tensor, caption_tensor)
# Each tuple contains:
# - image_path: a string (path to image)
# - image_tensor: a torch tensor of shape (3, H, W) or similar
# - caption_tensor: a torch tensor of token ids

# Create sample data batch
image_paths = ["path/to/image1.jpg", "path/to/image2.jpg"]
images = [
    torch.randn(3, 32, 32),  # 3-channel image, 32x32
    torch.randn(3, 32, 32),
]
captions = [
    torch.tensor([1, 2, 3, 4, 5]),  # caption with 5 tokens
    torch.tensor([6, 7, 8]),         # caption with 3 tokens
]

# Construct data as list of tuples
data = list(zip(image_paths, images, captions))

ARGS = {
    "data": data
}
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
create_caption_word_format Ran
ran on a synthesized input
guptakhil12/show-tell/utils.py
code served (permissive licence) · get_code("d0b88657ee87ce95")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned list. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import numpy as np

class MockVocab:
    """Mock vocabulary class with required methods and attributes."""
    def __init__(self):
        self.words = ["<start>", "<end>", "cat", "dog", "sat", "on", "mat"]
        self.word_to_index = {word: idx for idx, word in enumerate(self.words)}
        self.index_to_word = {idx: word for word, idx in self.word_to_index.items()}
    
    def start_token(self):
        return "<start>"
    
    def end_token(self):
        return "<end>"

# Create a mock vocabulary
vocab = MockVocab()

# Create tokenized data: list of token sequences
# Each token sequence is a list of indices
tokenized = [
    [0, 2, 4, 6, 1],  # <start> cat sat mat <end>
    [0, 3, 5, 1, 1]   # <start> dog on <end> <end>
]

ARGS = {
    "tokenized": tokenized,
    "vocab": vocab,
    "flag_blue": False
}
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 — 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
crop_image Ran
ran on a synthesized input
jazzsaxmafia/show_and_tell.tensorflow/cnn_util.py
code served (permissive licence) · get_code("e222ea9e1518266f")
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 float, shape (227, 227, 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 cv2
import numpy as np
import skimage
import tempfile
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 (RGB, 300x400)
test_image = np.random.randint(0, 256, (300, 400, 3), dtype=np.uint8)
skimage.io.imsave(temp_image_path, test_image)

ARGS = {
    "x": temp_image_path,
    "target_height": 227,
    "target_width": 227,
    "as_float": True,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
cv2, numpy, skimage — 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 (227, 227, 3) — shape (227, 227, 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
encode Ran
ran; our contract draft was wrong, not the code
pskrunner14/descriptor/descriptor/models/cnn_encoder.py
code served (permissive licence) · get_code("9a121ed8c3d15bc5")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Sonnet 4.5, prompt python_fixture_v1) and returned Tensor, ndim 2, dtype family float, shape (2, 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

torch.manual_seed(0)

class StandInCNNEncoder(nn.Module):
    """Stand-in for inception_v3 that returns a tensor when called"""
    def __init__(self):
        super().__init__()
        self.fc = nn.Linear(3 * 299 * 299, 128)
    
    def forward(self, x):
        # Flatten and return some output
        batch_size = x.size(0)
        x_flat = x.view(batch_size, -1)
        # Return a simple embedding
        return torch.randn(batch_size, 128)

# Create a small batch of images
# InceptionV3 typically expects 299x299 images with 3 channels
# But we'll use smaller images for testing
batch_size = 2
channels = 3
height = 299
width = 299

images = torch.randn(batch_size, channels, height, width)

cnn_encoder = StandInCNNEncoder()

ARGS = {
    'images': images,
    'cnn_encoder': cnn_encoder
}
Setup block drafted by
a language model, Claude Sonnet 4.5, prompt python_fixture_v1
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, 128) — shape (2, 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
extract_feature Ran
ran on a synthesized input
Cathy-t/HELLO_image/retrieval/retrieval.py
code served (permissive licence) · get_code("12f6cbc65ecc5156")
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
from torch.autograd import Variable

torch.manual_seed(0)

# Define a minimal model that takes input and returns a tensor
class SimpleFeatureExtractor(nn.Module):
    def __init__(self, input_dim=4, output_dim=3):
        super(SimpleFeatureExtractor, self).__init__()
        self.fc = nn.Linear(input_dim, output_dim)
    
    def forward(self, x):
        return self.fc(x)

# Create model instance
model = SimpleFeatureExtractor(input_dim=4, output_dim=3)
model.eval()

# Create a dataloader as a list of (image_tensor, path) tuples
# Batch size 2, image dimension 4
dataloaders = [
    (torch.randn(2, 4), ('path/to/img1.jpg', 'path/to/img2.jpg')),
    (torch.randn(2, 4), ('path/to/img3.jpg', 'path/to/img4.jpg')),
]

# Set use_gpu to False since we're on CPU-only
use_gpu = False

ARGS = {
    'model': model,
    'dataloaders': dataloaders,
    'use_gpu': use_gpu,
}
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_file_list Ran
ran; our contract draft was wrong, not the code
Cathy-t/HELLO_image/retrieval/retrieval.py
code served (permissive licence) · get_code("1a9ae5954fd68227")
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 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 shutil

# Create temporary directories with some test files
temp_dir_1 = tempfile.mkdtemp()
temp_dir_2 = tempfile.mkdtemp()

# Create some dummy files in the directories
for i in range(3):
    with open(os.path.join(temp_dir_1, f"file_{i}.txt"), "w") as f:
        f.write(f"test {i}")
    with open(os.path.join(temp_dir_2, f"data_{i}.txt"), "w") as f:
        f.write(f"data {i}")

ARGS = {
    "file_path_list": [temp_dir_1, temp_dir_2],
    "sort": True,
}
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 list, ndim 2, 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
km Ran
ran, violated the contract we drafted
fanchenyou/deepdiary/examples/myexp/prediction/lstm_generator.py
code served (permissive licence) · get_code("940455900b9ee75f")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Sonnet 4.5, prompt python_fixture_v1) and returned Tensor, 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 torch
import numpy as np

torch.manual_seed(0)

# The function km takes a single parameter x and computes 2 ** (-x)
# x can be a scalar, numpy array, torch tensor, or any numeric type

x = torch.tensor([1.0, 2.0])

ARGS = {
    'x': x
}
Setup block drafted by
a language model, Claude Sonnet 4.5, prompt python_fixture_v1
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 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
km Ran
ran, violated the contract we drafted
fanchenyou/deepdiary/examples/myexp/prediction/lstm_generator.py
code served (permissive licence) · get_code("d546eb3f62e6ef39")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Sonnet 4.5, prompt python_fixture_v1) and returned Tensor, 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 torch

torch.manual_seed(0)

x = torch.tensor([1.0, 2.0])
shift = 0.5

ARGS = {
    'x': x,
    'shift': shift
}
Setup block drafted by
a language model, Claude Sonnet 4.5, prompt python_fixture_v1
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 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
load_data Ran
ran on a synthesized input
Cathy-t/HELLO_image/retrieval/retrieval.py
code served (permissive licence) · get_code("c53c0bb2023ac902")
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 DataLoader. 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 tempfile
import os
from PIL import Image
from torchvision import transforms

torch.manual_seed(0)

# Create a temporary directory with test images
temp_dir = tempfile.mkdtemp()

# Create a few test image files
for i in range(3):
    img = Image.new('RGB', (50, 50), color=(73, 109, 137))
    img.save(os.path.join(temp_dir, f'test_image_{i}.jpg'))

# Define ARGS dictionary with all parameters for load_data function
ARGS = {
    'data_path': temp_dir,
    'batch_size': 2,
    'shuffle': False,
    'transform': 'default'
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
PIL, torch, torchvision — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type DataLoader — a DataLoader output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a DataLoader 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_image_jpeg Ran
ran on a synthesized input
nicolafan/image-captioning-cnn-rnn/src/models/utils.py
code served (permissive licence) · get_code("e29bef7d2cee141a")
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 EagerTensor, ndim 3, dtype family float, shape (299, 299, 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 tempfile
import os
import numpy as np
from PIL import Image

# Create a temporary JPEG file for testing
temp_dir = tempfile.mkdtemp()
temp_image_path = os.path.join(temp_dir, "test_image.jpg")

# Create a small valid JPEG image (299x299 is what the function expects, but we can use smaller)
# and the function will resize it
img_array = np.random.randint(0, 256, (100, 100, 3), dtype=np.uint8)
img = Image.fromarray(img_array, 'RGB')
img.save(temp_image_path, format='JPEG')

ARGS = {
    'filename': temp_image_path
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
PIL, 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 3, dtype family float, shape (299, 299, 3) — shape (299, 299, 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
max_sequence Ran
ran, honoured the contract we drafted
Mrnoorsingh/image-caption/ImageCaption.py
pointer only (licence: NONE) · get_code("30b6ac17db0d1ce6")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, Mrnoorsingh/image-caption 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.

precook Ran
ran; our contract draft was wrong, not the code
yurayli/image-caption-pytorch/eval_metrics.py
code served (permissive licence) · get_code("ec4448373d72d636")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Sonnet 4.5, prompt python_fixture_v1) 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.

ARGS = {
    "s": "the quick brown fox jumps over the lazy dog",
    "n": 4,
    "out": False
}
Setup block drafted by
a language model, Claude Sonnet 4.5, prompt python_fixture_v1
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 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
qft Ran
ran; our contract draft was wrong, not the code
Djmcflush/Quantum-Hackathon/quantum_edge_detection.py
pointer only (licence: NONE) · get_code("d6f73a39ee4c2493")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, Djmcflush/Quantum-Hackathon 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.

remove_punctuation_from_list Ran
ran on a synthesized input
NicholasKX/ShowAndTell/inference.py
code served (permissive licence) · get_code("73cfd8350786c342")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned list, ndim 1, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import re

def remove_punctuation_from_list(word_list):
    res = [re.sub('[^\\w\\s]', '', word) for word in word_list]
    return [word for word in res if word != '']

ARGS = {
    "word_list": ["hello!", "world?", "test@123", "foo-bar", "!!!"]
}
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 list, ndim 1, dtype family float — a list output has no array shape of its own; none is stated
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
remove_special_tokens Ran
ran; our contract draft was wrong, not the code
yurayli/image-caption-pytorch/eval_metrics.py
code served (permissive licence) · get_code("9bfeeae84da4c830")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Sonnet 4.5, prompt python_fixture_v1) 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.

ARGS = {
    "caption_text": "a <start> photo of a cat <end> sitting on <unk> the mat"
}
Setup block drafted by
a language model, Claude Sonnet 4.5, prompt python_fixture_v1
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
split Ran
ran on a synthesized input
yuyay/chainer_nic/datasets.py
code served (permissive licence) · get_code("bb0b8cedb4bac982")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned list, ndim 1, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch

def split(sentence):
    return sentence.lower().replace('.', ' .').replace(',', ' ,').split()

ARGS = {
    'sentence': 'Hello world. This is a test, with punctuation.'
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type list, ndim 1, dtype family float — a list output has no array shape of its own; none is stated
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
subsequent_mask Ran
ran, violated the contract we drafted
Cathy-t/HELLO_image/model.py
code served (permissive licence) · get_code("e803ca67568776c1")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned Tensor, ndim 3, dtype family float, shape (1, 4, 4) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import numpy as np

torch.manual_seed(0)

# The function takes a single parameter 'size' which is used as:
# 1. attn_shape = (1, size, size) - so it needs to be an integer
# 2. np.triu(np.ones(attn_shape), k=1) - creates upper triangular matrix
# 3. The result is a mask tensor of shape (1, size, size)
# A small size like 4 works well for testing

ARGS = {
    "size": 4
}
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 3, dtype family float, shape (1, 4, 4) — shape (1, 4, 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
swap_registers Ran
ran; our contract draft was wrong, not the code
Djmcflush/Quantum-Hackathon/quantum_edge_detection.py
pointer only (licence: NONE) · get_code("d3ef7591e1d22a18")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, Djmcflush/Quantum-Hackathon 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.

ymax Ran
ran, honoured the contract we drafted
fanchenyou/deepdiary/examples/myexp/prediction/lstm_generator.py
code served (permissive licence) · get_code("dd99f91353354ec4")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Sonnet 4.5, prompt python_fixture_v1) 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 numpy as np

# The function expects y to be an array-like object that can be raveled
# It performs softmax-like operations and returns the index and value of the max

y = np.array([[2.3, 1.5, 0.8, -1.2],
              [3.1, -0.5, 1.9, 0.3]])

ARGS = {
    'y': y
}
Setup block drafted by
a language model, Claude Sonnet 4.5, prompt python_fixture_v1
Imports
numpy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple, ndim 1, dtype family float — a tuple output has no array shape of its own; none is stated
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image 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_image Not yet run
unverified (harvested, no recorded run)
Cathy-t/HELLO_image/src/sample.py
code served (permissive licence) · get_code("d7eeb3c0e4ec601d")
How it ran

no invocation recorded.

masked_sparse_categorical_accuracy Not yet run
unverified (harvested, no recorded run)
nicolafan/image-captioning-cnn-rnn/src/models/metrics.py
code served (permissive licence) · get_code("c1df9623c188caff")
How it ran

no invocation recorded.

qft_rotations Not yet run
unverified (harvested, no recorded run)
Djmcflush/Quantum-Hackathon/quantum_edge_detection.py
pointer only (licence: NONE) · get_code("043f5555303ee47e")
How it ran

The body of this sample is withheld: GitHub detected no licence in this paper's repository, Djmcflush/Quantum-Hackathon 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.

read_split_dataset Not yet run
unverified (harvested, no recorded run)
nicolafan/image-captioning-cnn-rnn/src/models/read_data.py
code served (permissive licence) · get_code("e9aaa80e5a2ae620")
How it ran

no invocation recorded.

resize_image Not yet run
unverified (harvested, no recorded run)
Cathy-t/HELLO_image/caption/resize.py
code served (permissive licence) · get_code("ddccddb3e642d270")
How it ran

no invocation recorded.

run_inference_for_single_image Not yet run
unverified (harvested, no recorded run)
Chloejay/image_caption_app/model/inference.py
code served (permissive licence) · get_code("020c3cce307058ec")
How it ran

no invocation recorded.

Also present in other papers' code

Of 34 samples lifted from this paper's linked repositories, 34 carry a function identity and 0 do not. Of the 33 distinct functions with an identity, 9 are also present in other papers whose code we hold (0 with at least one paper dated earlier, 0 the same month, 9 later) and 24 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
clones 79 other papers
79 later · 11 only as an assembly brick
1612.00563 (2016-12)
Self-critical Sequence Training for Image Captioning
1706.03762 (2017-06)
Attention Is All You Need
1707.07998 (2017-07)
Bottom-Up and Top-Down Attention for Image Captioning and Visual Question Answering
and 76 more not named here
attention 27 other papers
27 later
1609.08144 (2016-09)
Google's Neural Machine Translation System: Bridging the Gap between Human and Machine Translation
1612.00563 (2016-12)
Self-critical Sequence Training for Image Captioning
1706.03762 (2017-06)
Attention Is All You Need
and 24 more not named here
precook 22 other papers
22 later
1502.03044 (2015-02)
Show, Attend and Tell: Neural Image Caption Generation with Visual Attention
1611.09268 (2016-11)
MS MARCO: A Human Generated MAchine Reading COmprehension Dataset
1611.09571 (2016-11)
Predicting Human Eye Fixations via an LSTM-based Saliency Attentive Model
and 19 more not named here
subsequent_mask 21 other papers
21 later
1612.00563 (2016-12)
Self-critical Sequence Training for Image Captioning
1707.07998 (2017-07)
Bottom-Up and Top-Down Attention for Image Captioning and Visual Question Answering
1905.12926 (2019-05)
Controllable Unsupervised Text Attribute Transfer via Editing Entangled Latent Representation
and 18 more not named here
allowed_file 4 other papers
4 later
1609.03605 (2016-09)
Detecting Text in Natural Image with Connectionist Text Proposal Network
1612.01010 (2016-12)
DeepBach: a Steerable Model for Bach Chorales Generation
1911.06311 (2019-11)
Sato: Contextual Semantic Type Detection in Tables
and 1 more not named here
collate_fn 1 other paper
1 later
1611.07810 (2016-11)
A dataset and exploration of models for understanding video data through fill-in-the-blank question-answering
get_file_list 1 other paper
1 later
2310.07716 (2023-10)
PAD: A Dataset and Benchmark for Pose-agnostic Anomaly Detection
remove_special_tokens 1 other paper
1 later
1502.03044 (2015-02)
Show, Attend and Tell: Neural Image Caption Generation with Visual Attention
resize_image 1 other paper
1 later
1611.07810 (2016-11)
A dataset and exploration of models for understanding video data through fill-in-the-blank question-answering

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

More are linked than shown here.

Some links come from the archived Papers with Code dataset (CC BY-SA 4.0): attribution and licence.

Abstract

Automatically describing the content of an image is a fundamental problem in artificial intelligence that connects computer vision and natural language processing. In this paper, we present a generative model based on a deep recurrent architecture that combines recent advances in computer vision and machine translation and that can be used to generate natural sentences describing an image. The model is trained to maximize the likelihood of the target description sentence given the training image. Experiments on several datasets show the accuracy of the model and the fluency of the language it learns solely from image descriptions. Our model is often quite accurate, which we verify both qualitatively and quantitatively. For instance, while the current state-of-the-art BLEU-1 score (the higher the better) on the Pascal dataset is 25, our approach yields 59, to be compared to human performance around 69. We also show BLEU-1 score improvements on Flickr30k, from 56 to 66, and on SBU, from 19 to 28. Lastly, on the newly released COCO dataset, we achieve a BLEU-4 of 27.7, which is the current state-of-the-art.

For agents

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

get_harvested_code_for_paper("1411.4555")
get_code_for_paper("1411.4555")
have("1411.4555")

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

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

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

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

Connect an agent — have() is free.