SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2307.12045 · 2023

Revisiting Distillation for Continual Learning on Visual Question Localized-Answering in Robotic Surgery

arXiv · PDF · Open in the Atlas

Code that ran

11 of 11 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; 4 honoured the contract we drafted, 0 violated it and 0 have no contract verdict; 7 failures of our instrument; 0 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/2307.12045.json · badge: /api/ran/2307.12045.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
longbai1006/cs-vqla canonical (classifier label)
classifier basis: census
11 ran · 0 no recorded run
FunctionStatusWhere it lives
accuracy Ran
ran; our contract draft was wrong, not the code
longbai1006/cs-vqla/utils/vqla.py
code served (permissive licence) · get_code("53daad1d7b99fbdf")
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 float, 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)

# Construct small tensors for the function
batch_size = 2
num_classes = 4
k = 2

# scores: model predictions with shape (batch_size, num_classes)
scores = torch.randn(batch_size, num_classes)

# targets: true labels with shape (batch_size,)
targets = torch.randint(0, num_classes, (batch_size,))

ARGS = {
    "scores": scores,
    "targets": targets,
    "k": k,
}
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 float, 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
calc_acc Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
longbai1006/cs-vqla/utils/vqla.py
code served (permissive licence) · get_code("19988d5d6c4a4d7c")
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 float, 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
import numpy as np
from sklearn.metrics import accuracy_score

torch.manual_seed(0)

# The function calc_acc takes y_true and y_pred and computes accuracy_score
# accuracy_score expects array-like inputs of class labels (integers or strings)
# and returns a float between 0 and 1

# Create ground truth labels (small batch of 2 samples with 3 classes: 0, 1, 2)
y_true = np.array([0, 1, 2, 1])

# Create predictions (same shape as y_true)
y_pred = np.array([0, 1, 1, 1])

ARGS = {
    "y_true": y_true,
    "y_pred": y_pred,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, sklearn, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type float, 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
calc_classwise_acc Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
longbai1006/cs-vqla/utils/vqla.py
code served (permissive licence) · get_code("9fd07c1d7cd49c46")
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 1, dtype family float, shape (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 numpy as np
from sklearn.metrics import confusion_matrix

# Create simple ground truth and predictions
# Using 3 classes with 6 samples total
y_true = np.array([0, 1, 2, 0, 1, 2])
y_pred = np.array([0, 1, 2, 0, 1, 1])

ARGS = {
    "y_true": y_true,
    "y_pred": y_pred,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, sklearn — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type ndarray, ndim 1, dtype family float, shape (3,) — shape (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
count_parameters Ran
ran, honoured the contract we drafted
longbai1006/cs-vqla/utils/toolkit.py
pointer only (licence: MIT); the stored copy get_code serves, from wangkiw/iclr23-memo, is pointer only (licence: NONE) · get_code("6bdbe3d6368c4cde")
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 wangkiw/iclr23-memo, 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.

default_loader Ran
ran, honoured the contract we drafted
longbai1006/cs-vqla/utils/data_manager.py
code served (permissive licence) · get_code("075c2cf9f6abfa28")
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 Image. 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 tempfile
import os
from PIL import Image
import numpy as np

# Create a temporary directory and a dummy image file
temp_dir = tempfile.mkdtemp()
image_path = os.path.join(temp_dir, "test_image.jpg")

# Create a simple RGB image and save it
img_array = np.random.randint(0, 256, (100, 100, 3), dtype=np.uint8)
img = Image.fromarray(img_array, 'RGB')
img.save(image_path)

ARGS = {
    "path": image_path
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
PIL, numpy, torchvision — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Image — a Image output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a Image output the recorded ndim 3 and dtype family int 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
extract_logits Ran
ran; our contract draft was wrong, not the code
longbai1006/cs-vqla/models/continual.py
code served (permissive licence) · get_code("1dfddce24ed63101")
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)

# Analyze the function:
# - class_list_name: iterated over with "for i in class_list_name", so a list/iterable of class indices
# - fake_classification: indexed with torch.index_select(fake_classification, 0, index_tool), so a 1D or 2D tensor
# - output1_logits: compared with == operator, indexed with torch.index_select, so a 1D tensor of class indices

# Create small test tensors
# output1_logits: 1D tensor of class labels (batch_size=5)
output1_logits = torch.tensor([0, 1, 0, 2, 1])

# fake_classification: 2D tensor of logits (batch_size=5, num_classes=4)
fake_classification = torch.randn(5, 4)

# class_list_name: list of class indices to extract
class_list_name = [0, 1]

ARGS = {
    "class_list_name": class_list_name,
    "fake_classification": fake_classification,
    "output1_logits": output1_logits,
}
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
loss_kd_regularization Ran
ran; our contract draft was wrong, not the code
longbai1006/cs-vqla/models/continual.py
code served (permissive licence) · get_code("d910800310424873")
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 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
from torch import nn
import torch.nn.functional as F

torch.manual_seed(0)

# Create small tensors for the function
batch_size = 2
num_classes = 4

# outputs: logits tensor of shape (batch_size, num_classes)
outputs = torch.randn(batch_size, num_classes)

# labels: class indices tensor of shape (batch_size,)
labels = torch.tensor([0, 2])

# T: temperature parameter (scalar)
T = 2.0

# multiplier: scaling factor (scalar)
multiplier = 0.5

ARGS = {
    "outputs": outputs,
    "labels": labels,
    "T": T,
    "multiplier": multiplier,
}
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 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
pil_loader Ran
ran, honoured the contract we drafted
longbai1006/cs-vqla/utils/data_manager.py
pointer only (licence: MIT); the stored copy get_code serves, from sun-hailong/aaai25-mos, is pointer only (licence: NONE) · get_code("66b63ed4f327a712")
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 sun-hailong/aaai25-mos, 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.

reduce_proxies Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
longbai1006/cs-vqla/utils/linears.py
pointer only (licence: MIT); the stored copy get_code serves, from sun-hailong/cvpr24-ease, is pointer only (licence: NONE) · get_code("4072283c98270784")
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 sun-hailong/cvpr24-ease, 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.

target2onehot Ran
ran; our contract draft was wrong, not the code
longbai1006/cs-vqla/utils/toolkit.py
pointer only (licence: MIT); the stored copy get_code serves, from liangzu/loranpac, is pointer only (licence: NONE) · get_code("284e2e0345abe291")
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 liangzu/loranpac, 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.

tensor2numpy Ran
ran, honoured the contract we drafted
longbai1006/cs-vqla/utils/toolkit.py
pointer only (licence: MIT); the stored copy get_code serves, from wangkiw/iclr23-memo, is pointer only (licence: NONE) · get_code("929c76a2fa2e8c42")
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 wangkiw/iclr23-memo, 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.

Also present in other papers' code

Of 11 samples lifted from this paper's linked repositories, 11 carry a function identity and 0 do not. Of the 11 distinct functions with an identity, 9 are also present in other papers whose code we hold (7 with at least one paper dated earlier, 7 the same month, 9 later) and 2 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
pil_loader 66 other papers
28 dated earlier, 2 the same month, 33 later, 3 same year, order not determinable
1502.03044 (2015-02)
Show, Attend and Tell: Neural Image Caption Generation with Visual Attention
1710.10196 (2017-10)
Progressive Growing of GANs for Improved Quality, Stability, and Variation
1711.02512 (2017-11)
Fine-tuning CNN Image Retrieval with No Human Annotation
and 63 more not named here
default_loader 28 other papers
10 dated earlier, 17 later, 1 same year, order not determinable
1907.02665 (2019-07)
Blind Image Quality Assessment Using A Deep Bilinear Convolutional Neural Network
2003.05033 (2020-03)
Generalized Energy Based Models
2003.13659 (2020-03)
Exploiting Deep Generative Prior for Versatile Image Restoration and Manipulation
and 25 more not named here
tensor2numpy 15 other papers
3 dated earlier, 1 the same month, 10 later, 1 same year, order not determinable · 9 only as an assembly brick
2204.04662 (2022-04)
FOSTER: Feature Boosting and Compression for Class-Incremental Learning
2205.13218 (2022-05)
A Model or 603 Exemplars: Towards Memory-Efficient Class-Incremental Learning
aaai_26216 (2023 (year only))
Isolation and Impartial Aggregation: A Paradigm of Incremental Learning without Interference
and 12 more not named here
accuracy 8 other papers
3 dated earlier, 1 the same month, 4 later
1502.03044 (2015-02)
Show, Attend and Tell: Neural Image Caption Generation with Visual Attention
1606.02960 (2016-06)
Sequence-to-Sequence Learning as Beam-Search Optimization
2305.11692 (2023-05)
Surgical-VQLA: Transformer with Gated Vision-Language Embedding for Visual Question Localized-Answering in Robotic Surgery
and 5 more not named here
count_parameters 8 other papers
2 dated earlier, 1 the same month, 4 later, 1 same year, order not determinable · 2 only as an assembly brick
2204.04662 (2022-04)
FOSTER: Feature Boosting and Compression for Class-Incremental Learning
2205.13218 (2022-05)
A Model or 603 Exemplars: Towards Memory-Efficient Class-Incremental Learning
aaai_26216 (2023 (year only))
Isolation and Impartial Aggregation: A Paradigm of Incremental Learning without Interference
and 5 more not named here
target2onehot 8 other papers
1 the same month, 6 later, 1 same year, order not determinable · 1 only as an assembly brick
aaai_26216 (2023 (year only))
Isolation and Impartial Aggregation: A Paradigm of Incremental Learning without Interference
2307.02251 (2023-07)
RanPAC: Random Projections and Pre-trained Models for Continual Learning
2312.08888 (2023-12)
Read Between the Layers: Leveraging Multi-Layer Representations for Rehearsal-Free Continual Learning with Pre-Trained Models
and 5 more not named here
reduce_proxies 7 other papers
7 later · 1 only as an assembly brick
2403.12030 (2024-03)
Expandable Subspace Ensemble for Pre-Trained Model-Based Class-Incremental Learning
2404.06622 (2024-04)
Calibrating Higher-Order Statistics for Few-Shot Class-Incremental Learning with Pre-trained Vision Transformers
2405.19074 (2024-05)
Resurrecting Old Classes with New Data for Exemplar-Free Continual Learning
and 4 more not named here
calc_acc 4 other papers
1 dated earlier, 1 the same month, 2 later
2305.11692 (2023-05)
Surgical-VQLA: Transformer with Gated Vision-Language Embedding for Visual Question Localized-Answering in Robotic Surgery
2307.05182 (2023-07)
CAT-ViL: Co-Attention Gated Vision-Language Embedding for Visual Question Localized-Answering in Robotic Surgery
2312.10251 (2023-12)
Advancing Surgical VQA with Scene Graph Knowledge
and 1 more not named here
calc_classwise_acc 4 other papers
1 dated earlier, 1 the same month, 2 later
2305.11692 (2023-05)
Surgical-VQLA: Transformer with Gated Vision-Language Embedding for Visual Question Localized-Answering in Robotic Surgery
2307.05182 (2023-07)
CAT-ViL: Co-Attention Gated Vision-Language Embedding for Visual Question Localized-Answering in Robotic Surgery
2312.10251 (2023-12)
Advancing Surgical VQA with Scene Graph Knowledge
and 1 more not named here

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

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

Abstract

The visual-question localized-answering (VQLA) system can serve as a knowledgeable assistant in surgical education. Except for providing text-based answers, the VQLA system can highlight the interested region for better surgical scene understanding. However, deep neural networks (DNNs) suffer from catastrophic forgetting when learning new knowledge. Specifically, when DNNs learn on incremental classes or tasks, their performance on old tasks drops dramatically. Furthermore, due to medical data privacy and licensing issues, it is often difficult to access old data when updating continual learning (CL) models. Therefore, we develop a non-exemplar continual surgical VQLA framework, to explore and balance the rigidity-plasticity trade-off of DNNs in a sequential learning paradigm. We revisit the distillation loss in CL tasks, and propose rigidity-plasticity-aware distillation (RP-Dist) and self-calibrated heterogeneous distillation (SH-Dist) to preserve the old knowledge. The weight aligning (WA) technique is also integrated to adjust the weight bias between old and new tasks. We further establish a CL framework on three public surgical datasets in the context of surgical settings that consist of overlapping classes between old and new surgical VQLA tasks. With extensive experiments, we demonstrate that our proposed method excellently reconciles learning and forgetting on the continual surgical VQLA over conventional CL methods. Our code is publicly accessible.

For agents

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

get_harvested_code_for_paper("2307.12045")
get_code_for_paper("2307.12045")
have("2307.12045")

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

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

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

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

Connect an agent — have() is free.