MICCAI 2026

ReMeDI: Refined Memory for Disambiguation of Identities with SAM3 in Surgical Segmentation

1University of Tübingen, Germany
Teaser figure showing SAM3 vs ReMeDI-SAM3 comparison

SAM3 vs ReMeDI-SAM3 (Ours): The orange-labeled instrument gets occluded after T=153 and re-appears at T=165. While SAM3 produces false positives after its re-appearance, ReMeDI-SAM3 maintains consistent identities across occlusion and re-entry.

Abstract

Accurate surgical instrument segmentation in endoscopy is crucial for computer-assisted interventions, yet remains challenging due to frequent occlusions, rapid motion, and long-term instrument re-entry. While SAM3 provides a powerful spatio-temporal framework for video object segmentation, its performance in surgical scenes is limited by indiscriminate memory updates, fixed memory capacity, and weak identity recovery after occlusions.

We propose ReMeDI-SAM3, a training-free extension of SAM3, that addresses these limitations through three components: (i) relevance-aware memory filtering with a dedicated occlusion-aware memory for storing pre-occlusion frames, (ii) a piecewise interpolation scheme that expands effective memory capacity, and (iii) a feature-based re-identification module with temporal voting for reliable post-occlusion identity disambiguation. Together, these components mitigate error accumulation and enable reliable recovery after occlusions. Evaluations on EndoVis17, EndoVis18, and CholecSeg8k under a zero-shot setting show mcIoU improvements of around 5.8%, 8%, and 2%, respectively, over vanilla SAM3, outperforming even prior training-based approaches.

Method Overview

ReMeDI-SAM3 Pipeline

We propose ReMeDI-SAM3: Refined Memory for Disambiguation of Identities with SAM3, a training-free extension of SAM3 to enhance temporal consistency and identity preservation in surgical videos. The pipeline is shown above. Our approach (1) restructures SAM3 memory into two components: (i) a relevance-aware memory that admits only high-confidence frames to stabilize temporal propagation, and (ii) an occlusion–aware memory that selectively retains pre-occlusion appearance cues to facilitate identity recovery. Building upon this design, we further introduce (2) a novel memory expansion scheme based on piecewise interpolation of temporal positional encodings, enabling larger memory without retraining, and (3) a feature-based re-identification module with temporal voting for robust post-occlusion identity verification and correction. Together, these components improve robustness to occlusions, tracking stability, and reliable instrument re-entry handling in surgical videos.

Among these components, the memory expansion scheme is the least intuitive, so we illustrate it in more detail below. Long surgical procedures require long-horizon temporal context, yet SAM3 is constrained by a fixed set of temporal positional encodings. Our piecewise interpolation scheme preserves the boundary embeddings, which carry distinct temporal priors, and samples new positions only in the interior region, enabling substantially larger memory capacity without retraining. Uniform interpolation, in contrast, distorts the learned boundary temporal priors.

Temporal Position Encoding Visualization

Quantitative Results

Our method achieves state-of-the-art results on the EndoVis17, EndoVis18, and CholecSeg8k benchmarks under zero-shot settings, outperforming both vanilla SAM3 and prior training-based approaches. On EndoVis17, ReMeDI-SAM3 improves over vanilla SAM3 by 6% IoU and 5.8% mcIoU. The improvement is statistically significant (Wilcoxon p=0.023), with ReMeDI-SAM3 outperforming SAM3 on 7 of 8 sequences (95% cluster-bootstrap CI [0.64, 8.13]) and reducing sequence-level standard deviation by 20% (74.50 ± 14.13 vs 69.04 ± 17.75 mcIoU). On EndoVis18, we obtain gains of 3.5% IoU and 8% mcIoU. The larger mcIoU gain reflects improved suppression of false positives for absent instruments via our identity-aware design. On CholecSeg8k, a broader surgical semantic segmentation benchmark, we observe consistent zero-shot gains of 1% IoU and 2% mcIoU. SAM-family methods use a first-appearance ground-truth mask prompt; specialist methods follow their original settings.

EndoVis17

Method Challenge IoU IoU mcIoU
ISINet 55.62 52.20 28.96
S3Net 72.54 71.99 46.55
MATIS Frame 68.79 62.74 37.30
TP-SIS 63.37 63.37 52.74
TrackAnything 67.41 64.50 62.97
PerSAM (Zero-Shot) 42.47 42.47 41.80
SurgicalSAM 69.94 69.94 67.03
SP-SAM 73.94 73.94 71.06
MA-SAM2 (Zero-Shot) 62.49 62.49 59.89
SAM3 (Mask, Zero-Shot) 78.08 70.76 68.42
ReMeDI-SAM3 (Ours) 81.34 76.65 74.29

EndoVis18

Method Challenge IoU IoU mcIoU
ISINet 73.03 70.94 40.21
S3Net 75.81 74.02 42.58
MATIS Frame 82.37 77.01 48.65
TP-SIS 84.92 83.61 65.44
TrackAnything 65.72 60.88 38.60
PerSAM (Zero-Shot) 49.21 49.21 34.55
SurgicalSAM 80.33 80.33 58.87
SP-SAM 84.24 84.24 65.71
SAM3 (Mask, Zero-Shot) 88.04 81.82 66.46
ReMeDI-SAM3 (Ours) 88.10 85.34 74.37

CholecSeg8k

Method Challenge IoU IoU mcIoU
PerSAM (Mask) 33.67 33.54 25.88
SAM3 (Mask) 88.33 87.81 79.37
ReMeDI-SAM3 (Ours) 89.68 89.07 81.25

Qualitative Results

Main results comparison

Qualitative comparison of SAM3 and ReMeDI-SAM3 on a challenging occlusion and reappearance case in EndoVis17. After the orange-labeled instrument becomes fully occluded at T=44, SAM3 exhibits identity drift and incorrectly assigns the orange identity to the visible green instrument, with this mislabeling persisting across subsequent frames. In contrast, ReMeDI-SAM3 suppresses such false-positive identity propagation during the occlusion and correctly re-identifies the true instrument upon reappearance.

EndoVis17 qualitative results

Qualitative comparison on EndoVis17 showing instrument turnover. The yellow instrument (Bipolar Forceps) exits the scene at T=75, and a second blue instrument (Prograsp Forceps) enters later (T=126–132). ReMeDI-SAM3 briefly misses the new instrument at T=126 but correctly assigns the blue identity once sufficient evidence accumulates. In contrast, SAM3 preserves the old yellow identity after occlusion, confusing the new instrument with the occluded yellow one.

Ablation Studies

We analyze the contribution of each component of ReMeDI-SAM3, with all ablation studies conducted on EndoVis17. Relevance-aware memory filtering alone provides a 3.5% mcIoU gain over vanilla SAM3 by suppressing noisy memory updates, and the occlusion-aware memory partition adds a further 0.5% mcIoU. The feature-based re-identification module contributes 1.4% IoU by correcting post-occlusion identity drift, while expanding the memory adds another 0.8% IoU, for a total improvement of 6.0% IoU and 5.9% mcIoU — confirming that the components are jointly essential for robust long-horizon segmentation. Expanding the memory to 15 frames improves all metrics, whereas further expansion slightly degrades performance, suggesting that an overly large memory introduces less informative context. Finally, replacing the proposed piecewise interpolation with uniform interpolation causes a drop of about 1.2% Challenge IoU and 1% IoU, since uniform resampling distorts the learned boundary temporal priors that piecewise interpolation preserves.

Impact of Individual Components

Method Challenge IoU IoU mcIoU
Vanilla SAM378.0870.7668.42
+ RM79.9473.7472.03
+ RM + OM80.9374.4672.53
+ RM + OM + ReID80.5875.8473.58
+ RM + OM + ReID + ME81.3476.6574.29

RM: relevance-aware memory, OM: occlusion-aware memory, ReID: feature-based re-identification, ME: memory expansion.

Effect of Memory Expansion

Memory Size Challenge IoU IoU mcIoU
780.5875.8473.59
1581.3476.6574.29
2080.7776.1173.57

Uniform vs. Piecewise Interpolation (M=15)

Method Challenge IoU IoU mcIoU
Uniform80.1375.6674.20
Piecewise81.3476.6574.29

Acknowledgements

The work described in this paper was conducted in the framework of Graduate School 2543/1 "Intraoperative Multi-Sensory Tissue Differentiation in Oncology" (project ID 40947457) funded by German Research Foundation (DFG - Deutsche Forschungsgemeinschaft). This work has been supported by the Deutsche Forschungsgemeinschaft (DFG) – EXC number 2064/1 – Project number 390727645 and SFB 1233, TP 2, Project number 276693517. The authors thank International Max Planck Research School for Intelligent Systems (IMPRS-IS) for supporting Valay Bundele and Mehran Hosseinzadeh. We also thank Jan-Niklas Dihlmann for redesigning the pipeline figure.

BibTeX

@inproceedings{bundele2026remedi,
  author    = {Bundele, Valay and Hosseinzadeh, Mehran and Lensch, Hendrik P. A.},
  title     = {ReMeDI: Refined Memory for Disambiguation of Identities with SAM3 in Surgical Segmentation},
  booktitle = {Medical Image Computing and Computer Assisted Intervention (MICCAI)},
  year      = {2026},
}