SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2004.09144 · 2020

Transformer Reasoning Network for Image-Text Matching and Retrieval

arXiv · PDF · Open in the Atlas

Code that ran

12 of 14 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; 1 honoured the contract we drafted, 1 violated it and 9 have no contract verdict; 1 failure of our instrument; 2 no recorded run), measured 2026-11-22; 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/2004.09144.json · badge: /api/ran/2004.09144.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
mesnico/TERN canonical (classifier label)
classifier basis: census
12 ran · 2 no recorded run
FunctionStatusWhere it lives
dcg_score Ran
ran on a synthesized input
mesnico/TERN/evaluate_utils/dcg.py
code served (permissive licence) · get_code("f6b4594fd6677dbe")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned float64, ndim 0, dtype family float; no output shape is stated. 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

# Set random seed for reproducibility
np.random.seed(0)

# Create sample data for dcg_score
# y_true: ground truth relevance labels (binary or graded relevance)
y_true = np.array([1, 0, 1, 1, 0, 1, 0, 0, 1, 1])

# y_score: predicted scores/ranking scores
y_score = np.array([0.9, 0.2, 0.8, 0.7, 0.1, 0.95, 0.3, 0.15, 0.85, 0.75])

# k: rank cutoff
k = 5

# gains: type of gain calculation
gains = 'exponential'

ARGS = {
    'y_true': y_true,
    'y_score': y_score,
    'k': k,
    'gains': gains
}
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
dot_sim Ran
ran on a synthesized input
mesnico/TERN/models/loss.py
code served (permissive licence) · get_code("6a49bab714ec6122")
How it ran

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

# The function performs im.mm(s.t())
# im needs to support .mm() method (matrix multiply)
# s needs to support .t() method (transpose)
# Both should be 2D tensors for this operation to make sense

# Create image embedding matrix: shape (2, 4) - 2 images, 4-dim embeddings
im = torch.randn(2, 4)

# Create sentence embedding matrix: shape (3, 4) - 3 sentences, 4-dim embeddings
s = torch.randn(3, 4)

ARGS = {
    "im": im,
    "s": s,
}
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
encode_data Ran
ran on a synthesized input
mesnico/TERN/evaluation.py
code served (permissive licence) · get_code("0919fda55c323689")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned tuple, ndim 3, dtype family float; no output shape is stated. 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 and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import numpy as np
from collections import OrderedDict
import torch.nn as nn

torch.manual_seed(0)

class MockWordEmbedding(nn.Module):
    def __init__(self, vocab_size=100, embedding_dim=4):
        super().__init__()
        self.embedding = nn.Embedding(vocab_size, embedding_dim)
    
    def forward(self, x):
        return self.embedding(x)

class MockTextEncoder(nn.Module):
    def __init__(self):
        super().__init__()
        self.word_embeddings = MockWordEmbedding(vocab_size=100, embedding_dim=4)
    
    def forward(self, x):
        return self.word_embeddings(x)

class MockImgTxtEnc(nn.Module):
    def __init__(self):
        super().__init__()
        self.txt_enc = MockTextEncoder()
    
    def forward(self, img, txt):
        return img, txt

class MockModel(nn.Module):
    def __init__(self, emb_dim=4):
        super().__init__()
        self.img_txt_enc = MockImgTxtEnc()
        self.logger = None
        self.emb_dim = emb_dim
    
    def eval(self):
        super().eval()
        return self
    
    def forward_emb(self, images, text, img_lengths, cap_lengths, boxes):
        batch_size = images.size(0)
        img_emb = torch.randn(batch_size, self.emb_dim)
        cap_emb = torch.randn(batch_size, self.emb_dim)
        return img_emb, cap_emb, None, None
    
    def forward_loss(self, img_emb, cap_emb):
        return torch.tensor(0.0)

class MockDataset:
    def __init__(self, size=10):
        self.size = size
    
    def __len__(self):
        return self.size

class MockDataLoader:
    def __init__(self, batch_size=2, num_batches=2, emb_dim=4):
        self.batch_size = batch_size
        self.num_batches = num_batches
        self.emb_dim = emb_dim
        self.dataset = MockDataset(size=batch_size * num_batches)
    
    def __iter__(self):
        for batch_idx in range(self.num_batches):
            images = torch.randn(self.batch_size, 3, 8, 8)
            targets = torch.randint(0, 100, (self.batch_size, 5))
            img_lengths = torch.tensor([4] * self.batch_size)
            cap_lengths = torch.tensor([5] * self.batch_size)
            boxes = torch.randn(self.batch_size, 4, 4)
            ids = torch.arange(batch_idx * self.batch_size, (batch_idx + 1) * self.batch_size)
            yield images, targets, img_lengths, cap_lengths, boxes, ids
    
    def __len__(self):
        return self.num_batches

model = MockModel(emb_dim=4)
data_loader = MockDataLoader(batch_size=2, num_batches=2, emb_dim=4)

ARGS = {
    "model": model,
    "data_loader": data_loader,
    "log_step": 1,
    "logging": print,
}
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 3, 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
find_nhead Ran
ran on a synthesized input
mesnico/TERN/models/visual.py
code served (permissive licence) · get_code("6e963f0bd8b4ec0f")
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 int, ndim 0, dtype family int, 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
import numpy as np

torch.manual_seed(0)

def find_nhead(feat_dim, higher=8):
    for i in reversed(range(higher + 1)):
        if feat_dim % i == 0:
            return i
    return 1

ARGS = {
    'feat_dim': 12,
    'higher': 8
}
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 int, ndim 0, dtype family int, 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
generate_square_subsequent_mask Ran
ran, violated the contract we drafted
mesnico/TERN/models/utils.py
pointer only (licence: Apache-2.0); the stored copy get_code serves, from chend-vl/instructocr, is pointer only (licence: NONE) · get_code("894b253f35765276")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (Apache-2.0), but get_code serves the stored copy, first harvested from chend-vl/instructocr, 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.

get_paths Ran
ran on a synthesized input
mesnico/TERN/data.py
code served (permissive licence) · get_code("ae1d8e2720a00989")
How it ran

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

import os
import numpy as np
import tempfile

# Create a temporary directory structure to avoid actual file I/O
tmpdir = tempfile.mkdtemp()

# Create necessary subdirectories
dataset_name = 'coco'
data_root = os.path.join(tmpdir, 'data')
dataset_path = os.path.join(data_root, dataset_name)
annotations_path = os.path.join(dataset_path, 'annotations')
images_path = os.path.join(tmpdir, 'images')

os.makedirs(annotations_path, exist_ok=True)
os.makedirs(os.path.join(images_path, 'train2014'), exist_ok=True)
os.makedirs(os.path.join(images_path, 'val2014'), exist_ok=True)

# Create dummy numpy files that the function tries to load
np.save(os.path.join(annotations_path, 'coco_train_ids.npy'), np.array([0, 1, 2, 3, 4]))
np.save(os.path.join(annotations_path, 'coco_dev_ids.npy'), np.array(list(range(6000))))
np.save(os.path.join(annotations_path, 'coco_test_ids.npy'), np.array([100, 101, 102]))
np.save(os.path.join(annotations_path, 'coco_restval_ids.npy'), np.array([200, 201, 202, 203]))

# Create dummy caption annotation files
open(os.path.join(annotations_path, 'captions_train2014.json'), 'w').close()
open(os.path.join(annotations_path, 'captions_val2014.json'), 'w').close()

config = {
    'dataset': {
        'name': 'coco',
        'data': data_root,
        'images-path': images_path,
        'restval': False
    }
}

ARGS = {
    'config': config
}
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 tuple, ndim 1, dtype family float — a tuple output has no array shape of its own; none is stated
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
get_transform Ran
ran on a synthesized input
mesnico/TERN/data.py
code served (permissive licence) · get_code("e7518699cbc1bd68")
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 Compose. 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 torchvision.transforms as transforms

torch.manual_seed(0)

ARGS = {
    "data_name": "cifar10",
    "split_name": "train",
    "config": {
        "image_size": 224,
        "crop_size": 224,
        "augmentation": True
    }
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch, torchvision — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Compose — a Compose output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a Compose 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
l2norm Ran
ran; our contract draft was wrong, not the code
mesnico/TERN/models/utils.py
pointer only (licence: Apache-2.0); the stored copy get_code serves, from Maryeon/asen, is pointer only (licence: NONE) · get_code("f92e514b398e75d8")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (Apache-2.0), but get_code serves the stored copy, first harvested from Maryeon/asen, 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.

my_collate Ran
ran on a synthesized input
mesnico/TERN/evaluate_utils/compute_relevance.py
code served (permissive licence) · get_code("d9047caaedf4aadb")
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

torch.manual_seed(0)

# my_collate takes a batch and transposes it using zip(*batch)
# This typically works with a list of tuples/lists
# Let's create a simple batch of (input, target) pairs

batch = [
    (torch.randn(4), torch.tensor(1)),
    (torch.randn(4), torch.tensor(0)),
]

ARGS = {
    "batch": batch
}
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
my_lcs Ran
ran, honoured the contract we drafted
mesnico/TERN/evaluate_utils/rouge.py
code served (permissive licence) · get_code("8e177567218199c4")
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 int, ndim 0, dtype family int, 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.

# Setup code for my_lcs function

ARGS = {
    "string": ["the", "quick", "brown", "fox"],
    "sub": ["quick", "fox"]
}
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 int, ndim 0, dtype family int, 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
order_sim Ran
ran on a synthesized input
mesnico/TERN/models/loss.py
code served (permissive licence) · get_code("da16023b8239c604")
How it ran

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

# Based on the function body, it expects:
# - im: a tensor that will be unsqueezed at dimension 0, so needs shape (num_images, embedding_dim)
# - s: a tensor that will be unsqueezed at dimension 1, so needs shape (num_sentences, embedding_dim)
# Both tensors are used in broadcasting and arithmetic operations

# Create small tensors with distinct dimensions
# im: (2, 4) - 2 images, 4-dim embeddings
# s: (3, 4) - 3 sentences, 4-dim embeddings
im = torch.randn(2, 4)
s = torch.randn(3, 4)

ARGS = {
    "im": im,
    "s": s,
}
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
ranking_precision_score Ran
ran on a synthesized input
mesnico/TERN/evaluate_utils/dcg.py
code served (permissive licence) · get_code("8183b31354ef5eef")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned float64, ndim 0, dtype family float; no output shape is stated. 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

# Set random seed for reproducibility
np.random.seed(0)

# Create simple test data for ranking_precision_score
# y_true: binary relevance labels (0 or 1)
# y_score: predicted scores for ranking

# Create a small dataset with 10 samples
y_true = np.array([0, 1, 0, 1, 1, 0, 1, 0, 1, 0])
y_score = np.array([0.1, 0.9, 0.2, 0.8, 0.85, 0.15, 0.75, 0.25, 0.95, 0.05])

ARGS = {
    'y_true': y_true,
    'y_score': y_score,
    'k': 5
}
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
EncoderText Not yet run
unverified (harvested, no recorded run)
mesnico/TERN/models/text.py
code served (permissive licence) · get_code("ef1f72eefcd0fcda")
How it ran

no invocation recorded.

average_precision_score Not yet run
unverified (harvested, no recorded run)
mesnico/TERN/evaluate_utils/dcg.py
code served (permissive licence) · get_code("c9ccc8160ca8229a")
How it ran

no invocation recorded.

Also present in other papers' code

Of 14 samples lifted from this paper's linked repositories, 14 carry a function identity and 0 do not. Of the 14 distinct functions with an identity, 11 are also present in other papers whose code we hold (3 with at least one paper dated earlier, 0 the same month, 11 later) and 3 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
generate_square_subsequent_mask 8 other papers
8 later · 1 only as an assembly brick
2008.05231 (2020-08)
Fine-grained Visual Textual Alignment for Cross-Modal Retrieval using Transformer Encoders
2107.03377 (2021-07)
Long Short-Term Transformer for Online Action Detection
2109.10852 (2021-09)
Pix2seq: A Language Modeling Framework for Object Detection
and 5 more not named here
my_lcs 7 other papers
3 dated earlier, 4 later
1503.01817 (2015-03)
YFCC100M: The New Data in Multimedia Research
1608.00272 (2016-08)
Modeling Context in Referring Expressions
1802.06842 (2018-02)
Zero-Shot Question Generation from Knowledge Graphs for Unseen Predicates and Entity Types
and 4 more not named here
order_sim 7 other papers
1 dated earlier, 6 later
1809.06181 (2018-09)
Dual Encoding for Zero-Example Video Retrieval
2008.05231 (2020-08)
Fine-grained Visual Textual Alignment for Cross-Modal Retrieval using Transformer Encoders
2104.00650 (2021-04)
Frozen in Time: A Joint Video and Image Encoder for End-to-End Retrieval
and 4 more not named here
l2norm 6 other papers
3 dated earlier, 3 later
1707.05612 (2017-07)
VSE++: Improving Visual-Semantic Embeddings with Hard Negatives
1809.06181 (2018-09)
Dual Encoding for Zero-Example Video Retrieval
2002.02814 (2020-02)
Fine-Grained Fashion Similarity Learning by Attribute-Specific Embedding Network
and 3 more not named here
dot_sim 3 other papers
3 later
2008.05231 (2020-08)
Fine-grained Visual Textual Alignment for Cross-Modal Retrieval using Transformer Encoders
2203.09138 (2022-03)
MuKEA: Multimodal Knowledge Extraction and Accumulation for Knowledge-based Visual Question Answering
2306.08789 (2023-06)
Efficient Token-Guided Image-Text Retrieval with Consistent Multimodal Contrastive Training
find_nhead 2 other papers
2 later
2008.05231 (2020-08)
Fine-grained Visual Textual Alignment for Cross-Modal Retrieval using Transformer Encoders
2306.08789 (2023-06)
Efficient Token-Guided Image-Text Retrieval with Consistent Multimodal Contrastive Training
get_transform 2 other papers
2 later
2008.05231 (2020-08)
Fine-grained Visual Textual Alignment for Cross-Modal Retrieval using Transformer Encoders
2306.08789 (2023-06)
Efficient Token-Guided Image-Text Retrieval with Consistent Multimodal Contrastive Training
my_collate 2 other papers
2 later
2008.05231 (2020-08)
Fine-grained Visual Textual Alignment for Cross-Modal Retrieval using Transformer Encoders
2306.08789 (2023-06)
Efficient Token-Guided Image-Text Retrieval with Consistent Multimodal Contrastive Training
average_precision_score 1 other paper
1 later
2008.05231 (2020-08)
Fine-grained Visual Textual Alignment for Cross-Modal Retrieval using Transformer Encoders
dcg_score 1 other paper
1 later
2008.05231 (2020-08)
Fine-grained Visual Textual Alignment for Cross-Modal Retrieval using Transformer Encoders
ranking_precision_score 1 other paper
1 later
2008.05231 (2020-08)
Fine-grained Visual Textual Alignment for Cross-Modal Retrieval using Transformer Encoders

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-22.

Repositories linked to this paper

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

Abstract

Image-text matching is an interesting and fascinating task in modern AI research. Despite the evolution of deep-learning-based image and text processing systems, multi-modal matching remains a challenging problem. In this work, we consider the problem of accurate image-text matching for the task of multi-modal large-scale information retrieval. State-of-the-art results in image-text matching are achieved by inter-playing image and text features from the two different processing pipelines, usually using mutual attention mechanisms. However, this invalidates any chance to extract separate visual and textual features needed for later indexing steps in large-scale retrieval systems. In this regard, we introduce the Transformer Encoder Reasoning Network (TERN), an architecture built upon one of the modern relationship-aware self-attentive architectures, the Transformer Encoder (TE). This architecture is able to separately reason on the two different modalities and to enforce a final common abstract concept space by sharing the weights of the deeper transformer layers. Thanks to this design, the implemented network is able to produce compact and very rich visual and textual features available for the successive indexing step. Experiments are conducted on the MS-COCO dataset, and we evaluate the results using a discounted cumulative gain metric with relevance computed exploiting caption similarities, in order to assess possibly non-exact but relevant search results. We demonstrate that on this metric we are able to achieve state-of-the-art results in the image retrieval task. Our code is freely available at https://github.com/mesnico/TERN.

For agents

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

get_harvested_code_for_paper("2004.09144")
get_code_for_paper("2004.09144")
have("2004.09144")

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

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

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

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

Connect an agent — have() is free.