SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2104.08271 · ICCV · 2021

TEACHTEXT: CrossModal Generalized Distillation for Text-Video Retrieval

Yang Liu, Andrew Zisserman, Hailin Jin, Samuel Albanie, Ioana Croitoru, Simion-Vlad Bogolin, Marius Leordeanu

arXiv · PDF · Open in the Atlas

Code that ran

3 of 5 samples (functions and classes) lifted from this paper's linked repositories executed on a synthesized input in Syntology's jail (0 of them constructed an object rather than computing a result; 0 honoured the contract we drafted, 0 violated it and 0 have no contract verdict; 3 failures 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/2104.08271.json · badge: /api/ran/2104.08271.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
albanie/collaborative-experts canonical (classifier label)
classifier basis: census
3 ran · 2 no recorded run
FunctionStatusWhere it lives
retrieval_as_classification Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
albanie/collaborative-experts/model/metric.py
code served (permissive licence) · get_code("7ccb106acb20a26e")
How it ran

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

import numpy as np
import scipy.stats

# Create a small similarity matrix (2 queries, 3 items)
# sims will be transposed to (3, 2) in the function
sims = np.array([
    [0.9, 0.7],
    [0.5, 0.8],
    [0.3, 0.6]
], dtype=np.float32)

# Create query masks indicating which items are relevant for each query
# query_masks will be transposed to (3, 2) in the function
# For query 0: items 0 and 1 are relevant
# For query 1: items 1 and 2 are relevant
query_masks = np.array([
    [1, 0],
    [1, 1],
    [0, 1]
], dtype=np.float32)

ARGS = {
    'sims': sims,
    'query_masks': query_masks,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
ipdb, matplotlib, numpy, scipy, zsvision — 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
t2v_metrics Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
albanie/collaborative-experts/model/metric.py
code served (permissive licence) · get_code("7f4ebeefd49432b9")
How it ran

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

import numpy as np
import scipy.stats

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

# Create a similarity matrix
# sims should be N x M where N is num_queries and M is num_vids
# For this test: 4 queries, 2 videos
# Since queries_per_video = num_queries // num_vids, we need num_queries to be divisible by num_vids
num_queries = 4
num_vids = 2
queries_per_video = num_queries // num_vids

# Create a random similarity matrix
sims = np.random.randn(num_queries, num_vids).astype(np.float32)

# Create query_masks (optional parameter)
# Should be same size as num_queries
query_masks = np.ones(num_queries, dtype=np.bool_)

ARGS = {
    'sims': sims,
    'query_masks': query_masks,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
ipdb, matplotlib, numpy, scipy, zsvision — 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
v2t_metrics Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
albanie/collaborative-experts/model/metric.py
code served (permissive licence) · get_code("0ce3d614411abce7")
How it ran

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

import torch
import numpy as np

torch.manual_seed(0)

# Create a small similarity matrix for testing
# sims will be transposed in the function, so we create it accordingly
# We want num_queries=2, num_caps=6 (3 caps per video)
# After transpose: 2x6 matrix (num_queries x num_caps)
sims = torch.tensor([
    [0.9, 0.5, 0.3, 0.8, 0.2, 0.1],
    [0.1, 0.2, 0.95, 0.3, 0.4, 0.7]
], dtype=torch.float32)

# No query_masks needed for basic test
query_masks = None

ARGS = {
    "sims": sims,
    "query_masks": query_masks,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
matplotlib, numpy, scipy, torch, zsvision — 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
kronecker_prod Not yet run
unverified (harvested, no recorded run)
albanie/collaborative-experts/model/model.py
pointer only (licence: Apache-2.0); the stored copy get_code serves, from hbzhang/cvpr2020, is pointer only (licence: NONE) · get_code("fc6aa51656b4be1e")
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 hbzhang/cvpr2020, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. No invocation recorded.

sent_feat Not yet run
unverified (harvested, no recorded run)
albanie/collaborative-experts/sent_feat_demo.py
code served (permissive licence) · get_code("ba4c695148436f05")
How it ran

no invocation recorded.

Also present in other papers' code

Of 5 samples lifted from this paper's linked repositories, 5 carry a function identity and 0 do not. Of the 5 distinct functions with an identity, 5 are also present in other papers whose code we hold (5 with at least one paper dated earlier, 2 the same month, 3 later) and 0 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
v2t_metrics 5 other papers
1 dated earlier, 1 the same month, 3 later
1907.13487 (2019-07)
Use What You Have: Video Retrieval Using Representations From Collaborative Experts
2104.00650 (2021-04)
Frozen in Time: A Joint Video and Image Encoder for End-to-End Retrieval
2305.03347 (2023-05)
A Large Cross-Modal Video Retrieval Dataset with Reading Comprehension
and 2 more not named here
retrieval_as_classification 4 other papers
1 dated earlier, 1 the same month, 2 later
1907.13487 (2019-07)
Use What You Have: Video Retrieval Using Representations From Collaborative Experts
2104.00650 (2021-04)
Frozen in Time: A Joint Video and Image Encoder for End-to-End Retrieval
2105.02192 (2021-05)
Audio Retrieval with Natural Language Queries
and 1 more not named here
kronecker_prod 2 other papers
1 dated earlier, 1 later
1907.13487 (2019-07)
Use What You Have: Video Retrieval Using Representations From Collaborative Experts
2105.02192 (2021-05)
Audio Retrieval with Natural Language Queries
sent_feat 1 other paper
1 dated earlier
1907.13487 (2019-07)
Use What You Have: Video Retrieval Using Representations From Collaborative Experts
t2v_metrics 1 other paper
1 dated earlier
1907.13487 (2019-07)
Use What You Have: Video Retrieval Using Representations From Collaborative Experts

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

In recent years, considerable progress on the task of text-video retrieval has been achieved by leveraging largescale pretraining on visual and audio datasets to construct powerful video encoders. By contrast, despite the natural symmetry, the design of effective algorithms for exploiting large-scale language pretraining remains under-explored. In this work, we are the first to investigate the design of such algorithms and propose a novel generalized distillation method, TEACHTEXT, which leverages complementary cues from multiple text encoders to provide an enhanced supervisory signal to the retrieval model. Moreover, we extend our method to video side modalities and show that we can effectively reduce the number of used modalities at test time without compromising performance. Our approach advances the state of the art on several video retrieval benchmarks by a significant margin and adds no computational overhead at test time. Last but not least, we show an effective application of our method for eliminating noise from retrieval datasets. Code and data can be found at https://www.robots.ox.ac.uk/ ˜vgg/ research/teachtext/.

For agents

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

get_harvested_code_for_paper("2104.08271")
get_code_for_paper("2104.08271")
have("2104.08271")

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

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

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

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

Connect an agent — have() is free.