SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2203.01825 · CVPR · 2022

What Makes Transfer Learning Work for Medical Images: Feature Reuse & Other Factors

Christos Matsoukas, Johan Haslum, Kevin Smith, Moein Sorkhei, Magnus Söderberg

arXiv · PDF · Open in the Atlas

Code that ran

4 of 10 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 4 have no contract verdict; 0 failures of our instrument; 6 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/2203.01825.json · badge: /api/ran/2203.01825.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
ChrisMats/feature-reuse canonical (classifier label)
classifier basis not recorded on the link
4 ran · 6 no recorded run
FunctionStatusWhere it lives
check_type Ran
ran on a synthesized input
ChrisMats/feature-reuse/ablations/layer_importance/trainer.py
code served (permissive licence) · get_code("7938be06505212fe")
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.

import torch

torch.manual_seed(0)

def check_type(_key):
    excluded = ['norm', 'bn']
    return not bool(sum([1 if _k in _key.split('.')[-2] else 0 for _k in excluded]))

# The function takes a string parameter _key
# It splits by '.' and checks the second-to-last component
# It looks for 'norm' or 'bn' substrings in that component
# Let's create a valid test case

ARGS = {
    '_key': 'module.layer.weight'
}
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 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
get_parent_path Ran
ran on a synthesized input
ChrisMats/feature-reuse/utils/helpfuns.py
code served (permissive licence) · get_code("ebde1b5fa87ece83")
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 str. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import os

def get_parent_path(path):
    return os.path.abspath(os.path.join(path, os.pardir))

ARGS = {
    "path": "/home/user/documents/projects"
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type str — a str output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a str output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
is_rank0 Ran
ran on a synthesized input
ChrisMats/feature-reuse/utils/dist_utills.py
code served (permissive licence) · get_code("151173e565d31e90")
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. The code mentions cuda, and the harness aliases cuda to the CPU for every sample; whether this run needed that is not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch

torch.manual_seed(0)

# The function is_rank0 checks if device_id == 0
# It accepts an optional device_id parameter
# If device_id is None, it calls torch.cuda.current_device()
# We'll pass a device_id value to avoid CUDA calls

ARGS = {
    "device_id": 0
}
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 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
load_json Ran
ran on a synthesized input
ChrisMats/feature-reuse/utils/helpfuns.py
code served (permissive licence) · get_code("7107762a922c0736")
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 os
import json
import tempfile

# Create a temporary JSON file with valid data
with tempfile.NamedTemporaryFile(mode='w', suffix='.json', delete=False) as f:
    temp_json_file = f.name
    json.dump({"key": "value", "number": 42}, f)

ARGS = {
    "fname": temp_json_file
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type dict — a dict output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a dict output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
compute_stats Not yet run
unverified (harvested, no recorded run)
ChrisMats/feature-reuse/utils/_utils.py
code served (permissive licence) · get_code("754f4b14895eba35")
How it ran

no invocation recorded.

dir_path Not yet run
unverified (harvested, no recorded run)
ChrisMats/feature-reuse/utils/helpfuns.py
code served (permissive licence) · get_code("69a7c9a0ca590ed4")
How it ran

no invocation recorded.

is_ddp Not yet run
unverified (harvested, no recorded run)
ChrisMats/feature-reuse/utils/dist_utills.py
code served (permissive licence) · get_code("957b396f6e712758")
How it ran

no invocation recorded.

is_dp Not yet run
unverified (harvested, no recorded run)
ChrisMats/feature-reuse/utils/dist_utills.py
code served (permissive licence) · get_code("fa2248c4e49de21b")
How it ran

no invocation recorded.

model_to_CPU_state Not yet run
unverified (harvested, no recorded run)
ChrisMats/feature-reuse/utils/_utils.py
code served (permissive licence) · get_code("15251dc58a466c9f")
How it ran

no invocation recorded.

pil_loader Not yet run
unverified (harvested, no recorded run)
ChrisMats/feature-reuse/utils/_utils.py
code served (permissive licence) · get_code("f8837cdcc2eb415e")
How it ran

no invocation recorded.

Also present in other papers' code

Of 10 samples lifted from this paper's linked repositories, 10 carry a function identity and 0 do not. Of the 10 distinct functions with an identity, 0 are also present in other papers whose code we hold (0 with at least one paper dated earlier, 0 the same month, 0 later) and 10 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.

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

Transfer learning is a standard technique to transfer knowledge from one domain to another. For applications in medical imaging, transfer from ImageNet has become the de-facto approach, despite differences in the tasks and image characteristics between the domains. However, it is unclear what factors determine whether -and to what extenttransfer learning to the medical domain is useful. The longstanding assumption that features from the source domain get reused has recently been called into question. Through a series of experiments on several medical image benchmark datasets, we explore the relationship between transfer learning, data size, the capacity and inductive bias of the model, as well as the distance between the source and target domain. Our findings suggest that transfer learning is beneficial in most cases, and we characterize the important role feature reuse plays in its success.

For agents

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

get_harvested_code_for_paper("2203.01825")
get_code_for_paper("2203.01825")
have("2203.01825")

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

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

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

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

Connect an agent — have() is free.