Slide-SAM: Medical SAM Meets Sliding Window

Authors: quan  quan
fenghe  tang
s kevin zhou
Venue: MIDL_io_2024_Conference
Published: 2024-01-26 07:42:32

Abstract: The Segment Anything Model (SAM) has achieved a notable success in two-dimensional image segmentation in natural images. However, the substantial gap between medical and natural images hinders its direct application to medical image segmentation tasks. Particularly in 3D medical images, SAM struggles to learn contextual relationships between slices, limiting its practical applicability. Moreover, applying 2D SAM to 3D images requires prompting the entire volume, which is time- and label-consuming. To address these problems, we propose Slide-SAM, which treats a stack of three adjacent slices as a prediction window. It firstly takes three slices from a 3D volume and point- or bounding box prompts on the central slice as inputs to predict segmentation masks for all three slices. Subsequently, the masks of the top and bottom slices are then used to generate new prompts for adjacent slices. Finally, step-wise prediction can be achieved by sliding the prediction window forward or backward through the entire volume. Our model is trained on multiple public and private medical datasets and demonstrates its effectiveness through extensive 3D segmetnation experiments, with the help of minimal prompts. Code is available at https://github.com/Curli-quan/Slide-SAM.

Main paper: 
 introduction: 
 Nowadays, 3D medical image segmentation plays a crucial role in medical image analysis for clinical analysis and diagnosis. However, annotating 3D medical images requires a significant amount of human labor and time resources. Recently, the Segment Anything Model (SAM) (Kirillov et al., 2023) demonstrates impressive zero-shot segmentation capabilities in large-scale computer vision tasks (Mazurowski et al., 2023; Huang et al., 2023b; He et al., 2023) . In the field of medical imaging, SAM introduces new possibilities for accelerating data annotation by using non-fixed points, bounding boxes, and rough mask prompts to define segmentation region categories. However, the huge distributional gap between natural images and medical images makes SAM inapplicable directly to medical images (Huang et al., 2023a; Cheng et al., 2023) . One straightforward solution to bridge the gap is finetuning SAM using medical images (Cheng et al., 2023; Ma and Wang, 2023; Wu et al., 2023) . Another feasible approach is to adjust the numeric range of medical images, making them visually more akin to natural images, which greatly improves the segmentation ability of SAM in the medical domain. Given these straightforward solutions, we believe that this issue may not be the central challenge in medical segmentation tasks.The fundamental challenge that SAM faces with medical images, in our view, lies in its inability to efficiently segment 3D images. Most recent variants can only employ a slice-byslice approach for processing volumetric images (Cheng et al., 2023; Ma and Wang, 2023) . However, such methods require substantial manual assistance and overlook the contextual information between slices, resulting in evident discontinuities in the segmentation results on each layer. Some other methods utilize adapters to introduce information between slices (Bui et al., 2023; Lei et al., 2023; Wu et al., 2023) whereas they still require a substantial cost in terms of prompt annotations. Additionally, there exists another category of methods that directly extend SAM into a 3D model (Gong et al., 2023) . Nevertheless, this method relinquishes the assistance provided by SAM's pre-trained weights due to the difference between tasks, necessitating a more resource-intensive model training process. Indeed, a core question prominently arises: How can SAM be enabled to predict 3D data effectively with only one prompt while fully harnessing its pre-trained weights? To address it, we propose a network called Slide-SAM. Slide-SAM only requires a prompt from the central slice to simultaneously infer multiple adjacent slices, and the resulting predictions can be used to generate prompts for the next group of adjacent slices. This is achieved through a sliding window approach, ultimately enabling one prompt to segment an entire volume. Furthermore, Slide-SAM's architecture and task are similar to the original SAM (from an RGB image to 3 grayscale images), making it easier to leverage the pre-trained weights of SAM. Regarding data, we utilize both 3D ground truth labels and 2D pseudo-labels generated by SAM and we introduce a hybrid loss function that controls which slices to calculate the loss on, allowing the incorporation of single-slice labels and multi-slice labels. Extensive experiments prove that our Slide-SAM can gain superior inference performance on 3D images with minimal prompt cost. 
structure of sam: 
 SAM consists of three main components: image encoder, prompt encoder and light-weight mask decoder. The image encoder is based on the Vision Transformer (ViT) (Dosovitskiy et al., 2020) pretrained by MAE (He et al., 2022) to extract representations. Prompt encoders can handle both sparse (points, boxes, text) and dense (masks) prompts. In this paper, we mainly focus on sparse encoders, which represent points and boxes as positional encodings that are then summed with the learned embeddings for each prompt type. The mask decoder is a Transformer decoder block modified to include dynamic mask prediction headers. SAM uses bidirectional cross-attention in each block, one for prompt-to-image embeddings and the other for image-to-prompt embeddings, to learn the interaction between prompt and image embeddings. After fusing two embeddings, SAM upsamples the image embedding, and then a multilayer perceptron maps the output labels to a dynamic linear classifier that predicts the target mask given the image.Feature Encoder: Concerning the feature encoder, which is a transformer encoder, we incorporate LoRA (Hu et al., 2021) , enabling SAM to update only a small subset of parameters during medical image training. The ViT-B (used in SAM-B) serves as the backbone and remains frozen throughout training, while the embedding layer is configured to be trainable. Mask Encoder: Given an image with 3 slices X ∈ R H×W ×3 , the mask decoder efficiently maps the image embedding F im ∈ R c×h×w , prompt embeddings P ∈ R 5×c , and an output token into feature maps F o ∈ R c×h×w representing the images, and three prediction heads H representing the prompted-based tasks. In order to segment multiple slices at the same time, the feature maps are expanded from one to three, but followed with the same heads.Specifically, for the feature map F o , Slide-SAM has three different MLP blocks to convert the feature map F o into three feature mapsF 1 ∈ R c×h×w , F 2 ∈ R c×h×w , and F 3 ∈ R c×h×w .Each feature map represents a slice. The heads H are divided into three heads H s1 ∈ R c , H s2 ∈ R c , and H s3 ∈ R c for segmenting different semantic regions, and H u ∈ R c for IoU prediction. Similar to SAM, we can obtain mask predictions M ∈ R H×W ×3×3 and IoU predictions U ∈ R 3 :EQUATION)where ⊙ is point-wise multiplication. Additionally, to fully leverage the prior knowledge of SAM weights, we load all weights from the Transformer decoder and the weights of the heads. We duplicate the weights of the MLP block receiving the feature map F o from one to three to load into the three branches of Slide-SAM.Prompt Encoder: We consider two sets of prompts: sparse (points, boxes) and dense (masks). The distinction between our method and SAM lies in the fact that our input images consist of three slices, and we opt to select the middle slice as a reference to provide prompts.Regarding the mask prompt, we extend the input channel count of the convolutional block associated with the mask prompt to three, in order to facilitate the input of masks from three layers of slices. Points and boxes are encoded by positional encodings summed with learned embeddings for each prompt type. Mask prompts are encoded and then summed element-wise with the image embedding.Hybrid loss: Given the prediction M ∈ R H×W ×3×3 and the ground-truth M ∈ R H×W ×3 , Slide-SAM adopts cross-entropy and Dice loss to supervise the fine-tuning process. The loss function can be described as follows:L j seg (M j , M ) = λ 1 L ce (M j , M ) + λ 2 L dice (M j , M ), L j iou (U j , M j , M ) = L mse (U j , IoU (M j , M ))(2)EQUATIONwhere L ce and L dice represent cross-entropy loss and dice loss, respectively. M ∈ R H×W ×3 and M ∈ R H×W ×3 represent the prediction and the ground truth, respectively. λ 1 and λ 2 represent loss weights, which are used to balance the impact between these two loss terms. λ 1 and λ 2 are set to 20 and 1 in practice, respectively. Next, to facilitate concurrent training on 2D and 3D data, we introduce an indicator I ∈ {0, 1} 3 to guide the layers for which loss computation is required. As a result, Eq (3) can be transformed as follows:EQUATIONFor instance, when using 3D labels, all three slices possess masks, resulting in each value of the indicator being 1. Conversely, when using 2D labels, only one slice contains a mask, leading to the indicator values being set to 1 for the slice with the mask and 0 for the others. In the case of IoU prediction loss, since it is not feasible to accurately predict all masks when using 2D labels, the exact IoU values remain unknown. Therefore, in such situations, we set the IoU prediction loss to be 0.Our inference process, as shown in Figure 2 , begins by selecting a specific layer as the starting point. We provide prompts for points or bounding boxes on this layer. Subsequently, we input this layer and its adjacent slices (3 slices in total) into the model to obtain segmentation masks. The masks at both ends are then denoised by morphological opening and used for computing bounding boxes for the next 3 consecutive slices. We iterate through the inference process in a sliding window fashion, extending towards both ends, until one of the masks at ends is empty.  
dataset preparation: 
 Training data:The training data we used is divided into two parts. (1) Annotated datasets.The public datasets include AbdomenCT-1K (Ma et al., 2021) , TotalSegmentor (Wasserthal et al., 2023) , CTPelvic1K (Liu et al., 2021) , WORD (Luo et al., 2021) , etc. and some private data;(2) Pseudo-labels generated by SAM. We use SAM to generate labels for unlabeled or partially labeled data. These labels are typically in 2D format and need to be used in conjunction with the mixed loss function we propose. (Gong et al., 2023) . We choose Dice as the evaluation metric.Preprocessing: We initially apply value clipping to confine the range of CT data within [-200, 400] and MRI data within [0, 600]. Subsequently, we standardize the intensity values of each volume to the range [0, 255]. We proceed to extract all slice images along the x, y, and z axes, along with their corresponding masks. These slices are then organized and saved in groups of three adjacent slices. During the extraction process, we discard groups for which the percentage of the central slice's mask area is less than 0.14%. Settings: To quantitively assess the performance of our model, we conduct comparative experiments involving fully-supervised networks, including nnUNet (Isensee et al., 2021) , a one-shot network SSL-ALp (Ouyang et al., 2020) , as well as SAM (Kirillov et al., 2023) , (Gong et al., 2023) . The fully supervised networks employ all training data and corresponding labels. SAM and SAM-Med2d are initialized with public weights. The one-shot segmentation model utilizes training data but abstains from using labels, and requires only the labels of one volume to make predictions. Implementation details: We use AdamW as the optimizer, and set the training rate to 0.0002. β 1 , β 2 and weight decay settings are 0.9, 0.999 and 0.1 respectively. We end training at 20 epochs. Our models are trained on 4 Nvidia RTX GPUs with 24G GPU memory.In Table 1 , we find that our performances are much better than SAM and SAM-Med2d when using point prompts, and compared to them using prompts on each slice, we only use one point prompt. When using 1 box prompt, we achieve similar performance to SAM-Med2d on multiple anatomies. In addition, when we also use box prompts on each slice like SAM, we can achieve the best performance on multiple anatomies. While initial performance gains are significant, further improvements plateau as the number of prompts increases. This is because our method automatically generates reliable prompts for other slices, minimizing the marginal benefit of additional prompts. For tumor detection, we compare our method with SAM3d-Adapter (Gong et al., 2023) and some popular segmentation methods, nnU-Net (Isensee et al., 2021) , nnFormer (Zhou et al., 2023) , Swin-UNETR (Hatamizadeh et al., 2021) . We finetune Slide-SAM with tumor datasets based on weights well-trained on fore-mentioned large-scale medical datasets. As shown in Table 2 , our performance Our model significantly outperforms existing supervised methods and SAM models, while requiring only a small number of prompts. This can greatly improve annotation efficiency.For the WORD testset, as illustrated in Table 3 , we achieve competitive results with only 5 prompts per anatomical structure, in stark contrast to SAM and SAM-Med2d, which necessitate approximately 40 prompts on average for each structure. Moreover, we leverage a larger backbone network (ViT-H) and incorporate additional CT data to train Slide-SAM, observing a more robust performance. Analysis of prompt efficiency: Assuming we set the condition for successful annotation as having a Dice coefficient greater than 0.9 between predictions and ground-truth labels, we counted the number of images successfully annotated by our method and other methods (SAM, SAM-Med2D) when using the same 1000 prompts. As demonstrated in Figure 3 , the annotation efficiency of our method is significantly higher than that of other methods.Visual comparison: As depicted in Figure 4 , the segmentation results from the original SAM exhibit noticeable discontinuities between upper and lower layers, leading to incoherence between adjacent layers. Additionally, when using point prompts, a significant number of segmentation errors are prevalent, causing considerable challenges for experts. In contrast, our method produces remarkably smooth results, whether utilizing point prompts or box prompts as initial prompts. It provides excellent 3D segmentation results and facilitates subsequent annotation optimization, making it a more user-friendly option for experts.Noisy prompts: As shown in Figure 5 , we attempt to simulate a realistic annotation environment by using points or bounding box prompts with noise. We find that our method exhibits a certain level of robustness to noise. For box prompts, stable prediction results are obtained regardless of translation or scaling. The stability of point prompts is relatively lower. Poor predictions may occur with points at edges. 
conclusion: 
 One main challenge AM encounters when applied to medical images mainly stems from its limitations in effectively segmenting 3D image data. To address this, we introduce Slide-SAM, which leverages pretrained weights and facilitates multi-slice inference through a sliding window technique. Incorporating our data enrichment strategies and a hybrid loss function that encompasses both 3D labels and 2D pseudo-labels, our method enhances the training process and results in performance advancements. Extensive experiments prove that our Slide-SAM can gain superior inference performance on 3D images with a minimal prompt cost.Pseudo-labels: Since some datasets have only partial annotations, we employ a straightforward method to generate a large number of pseudo-labels and apply them after training. Moreover, we observe that these data indeed result in a significant performance improvement. The generation of pseudo-labels is as follows: We find that by adjusting the window width of CT or MRI images (i.e., adopting different truncation methods, such as constraining data within the range of [-200, 400] for CT), SAM can produce different results for the same data. We believe that this adjustment can make certain regions, originally with small color differences, more distinguishable, allowing SAM to segment these areas. Therefore, we used multiple truncation thresholds, [µ± 3 * δ], [µ ± 2 * δ], [µ ± δ], and [µ ± 0.5 * δ],where µ and δ refer to the average and standard variance, respectively. In addition, we used superpixels to generate point/box prompts for SAM. We would exclude superpixels with an average value below a certain threshold, as we consider them potentially representing background. Figure 7 illustrates the pseudo-labels we generate.  
 
 Appendix: Prompt genetation: Following SAM and other interactive segmentation models, we simulate an interactive segmentation setup during training. First, with equal probability, either a foreground point or bounding box is selected randomly for the target mask. Points are sampled uniformly from the ground truth mask. Boxes are taken as the ground truth mask's bounding box, with random noise added in each coordinate with a standard deviation equal to 10% of the box sidelength, to a maximum of 20 pixels. This noise profile is a reasonable compromise between applications like instance segmentation, which produces a tight box around the target object, and interactive segmentation, where a user may draw a loose box.2D post-processing: missed, and overly large box prompts may lead to incorrect predictions. However, slightly larger box prompts than the standard bounding boxes result in minimal impact. Therefore, we recommend making the box prompts slightly larger to avoid missing annotations as much as possible.Our method works fine under common spacing settings (such as (1,1,3), (1,1,5)). Currently, the performance of our Slide SAM on consecutive slices with larger differences may be relatively poor. As shown in the Table 4 , we resampled the volumes of the Word testset along the z-axis to change the z-spacing. We find that slightly increasing the z-spacing does not have much impact on performance, but performance notably decreases when the z-spacing becomes too large. We plan to improve this problem in future work, such as adding an adaptive module to Slide-SAM to try to robust the model identify variable slices that are further apart. We conduct an additional testing on an in-house dataset sourced from the Guangdong Provincial People's Hospital in China. This dataset comprises 120 MRI volumes, partitioned into subsets: 100 volumes for training, 10 volumes for validation, and 10 volumes for testing purposes. The dataset comprises scans focusing on the lower abdomen, with the segmentation targets being the rectum and rectal tumors. One challenge of this dataset is its divergence from our pre-training data, which primarily consists of CT scans. Specifically, the CHAOS dataset is our sole MRI dataset, involving upper abdominal scans. Consequently, our model has not been exposed to lower abdominal MRI data previously. Furthermore, the spacing between slices in this dataset measures approximately (0.36, 0.36, 5), with a pronounced inter-slice gap. This structural peculiarity poses a significant challenge for our model's adaptation. To address these challenges, we employ a fine-tuning strategy using the available training data and subsequently evaluate the performance of our model. The results are shown in Table 5 . We find that when only one box prompt is used, the performance is not as good as nnUNet, but when we use 3 or more prompts, the performance can exceed nnUNet. Ad- ditionally, the segmentation accuracy can be further improved as the number of prompts increases.To prove the efficacy of pseudo-labels, we conducte a comparative analysis by assessing model performance with and without their utilization. As shown in Table 6 , we employ all slices from the 3D volumes of AbdomenCT-1K as the training images and finetune SAM with the incorporation of the Subsequently, validation is carried out on the test set of AbdomenCT-1K. Our findings indicate that, when using only the original data and their associated labels, the finetuned model's performance is even inferior to that of the original SAM. However, a notable enhancement in performance is observed when we incorporate the additional pseudo-labels, thereby affirming the constructive impact of the pseudo-labels used in our model training. Table 6 : Comparison between the utilization of generated pseudo-labels and their absence on AbdomenCT-1K testset. 


Decision: Reviewers unanimously agree to strongly accept the submission.

Reviews: review: paper_summary: paper_summary: SAM struggles to learn contextual relationships between slices when applied to 3D medical images. Moreover, applying 2D SAM to 3D images requires prompting the entire volume. In this paper, the authors propose Slide-SAM, which only requires a prompt from the central slice to simultaneously infer multiple adjacent slices, and the resulting predictions can be used to generate prompts for the next group of adjacent slices, which could better adapt SAM to 3D medical image segmentation tasks.
main_review: main_review: Thanks for addressing the comments. Great work!  ( Another minor question in the revised version of manuscript. Please ensure that the significant figures in Table 1 are consistent, and add the prompt settings in line SAM-Med3d
strength_weakness: strength_weakness: Several minor suggestions for the article. 

Table 1. It would be better to add the average performance of our target organs. Similar for Table 3.
Besides, comparison with SAM-Med3D, another adaption of SAM for 3D medical images which could also enable segmentation with single prompt, should be included and compared. 
Minor typos Sec 3.1 training data should be “TotalSegmentator”
questions: questions: See above.
paper_summary: paper_summary: The paper presents Slide-SAM to address the challenge of segmenting 3D medical images with minimal prompts. Slide-SAM utilizes a sliding window of three adjacent slices, beginning with a prompt on the central slice and generating successive prompts through prediction masks for the entire volume, leveraging pre-trained SAM weights and a hybrid loss function to efficiently train on both 2D and 3D data. Extensive experiments on various datasets demonstrate that Slide-SAM achieves superior performance over existing methods with fewer required prompts.
main_review: main_review: The paper demonstrates the model's superior performance quantitatively through extensive benchmarking and experiments. The authors have effectively addressed my comments, and with the paper now in excellent condition.
strength_weakness: strength_weakness: The paper is well-written. The paper may have tested only certain types and levels of noise. In real-world clinical settings, noise and inaccuracies in prompts can be more unpredictable and diverse. Hence, if the range of noise conditions tested doesn't cover the full spectrum encountered in clinical practice, sensitivity to the initial input could remain a concern (but may a bit of out-of the scope in this manuscript)
questions: questions: Please check the weakness and detailed comments section.
paper_summary: paper_summary: The paper introduces Slide-SAM, an adaptation of the Segment Anything Model (SAM) for 3D medical image segmentation. Unlike SAM, which struggles with the contextual relationships in 3D medical images, Slide-SAM uses a stack of three slices to predict segmentation masks, improving efficiency and accuracy. It demonstrates effectiveness across various datasets.
main_review: main_review: The innovative approach of Slide-SAM addresses a significant gap in medical image segmentation, offering a promising solution to the challenges of 3D image analysis. Despite potential limitations in adaptability and computational demand, its successful application across diverse datasets justifies a positive preliminary assessment.
strength_weakness: strength_weakness: While Slide-SAM represents a significant advancement, its reliance on the continuity between adjacent slices may not be universally applicable across all types of medical images, where variability between slices can be substantial. Additionally, the model's performance in highly heterogeneous datasets remains to be fully explored. The computational efficiency of the sliding window approach, especially for large volumes, and the potential for increased processing time or resource demands, are concerns that could limit its practical deployment in resource-constrained settings.
questions: questions: No comments

Comments: comment: Thanks for addressing those concerns. I would accept it now.
Thanks for addressing those concerns. I would accept it now.
Thanks for addressing the comments. I would accept this paper now.
Thanks for your advice, which could impove Slide-SAM robustness and make it able to face the challenges of variable clinical applications. 

We have added all the following discussions in appendix.

## Slice variability: 
Our method works fine under common spacing settings (such as (1,1,3), (1,1,5)). Currently, the performance of our Slide SAM on consecutive slices with larger differences may be relatively poor. As shown in the table below, we resampled the volumes of the Word testset along the z-axis to change the z-spacing. We find that slightly increasing the z-spacing does not have much impact on performance, but performance notably decreases when the z-spacing becomes too large. We plan to improve this problem in future work, such as adding an adaptive module to Slide-SAM to try to robust the model identify variable slices that are further apart. 

|  Dataset     | z-spacing       | liver | spleen | pancreas | gallbladder |
|--------------|-----------------|-------|--------|----------|-------------|
| WORD testset | 2.75mm   | 94.36	 | 90.01	 | 71.84	 | 69.03       |
|              | 3.00mm   | 94.99 | 89.1   | 71.18    | 69.31       |
|              | 3.30mm   | 95.03 | 88.34  | 69.59    | 70.79       |
|              | 4.12mm   | 94.51 | 89.17  | 68.36    | 68.1        |
|              | 5.50mm   | 94.09 | 88.2   | 66.19    | -           |
|              | 6.87mm   | 93.29 | 89.15  | 60.66    | -           |
|              | 11.00mm | 90.25 | 82.58  | 48.41    | -           |
|              | 16.50mm | 85.84 | 75.2   | 42.38    | -           |
|              | 19.25mm | 83.60 | 73.54   | -   | -           |
|              | 22.00mm | 81.71 | -   | -    | -           |

## Heterogeneous datasets:  

We conduct an additional testing on an in-house dataset sourced from the Guangdong Provincial People’s Hospital in China. This dataset comprises 120 MRI volumes, partitioned into subsets: 100 volumes for training, 10 volumes for validation, and 10 volumes for testing purposes. The dataset comprises scans focusing on the lower abdomen, with the segmentation targets being the rectum and rectal tumors.
One challenge of this dataset is its divergence from our pre-training data, which primarily consists of CT scans. Specifically, the CHAOS dataset is our sole MRI dataset, involving upper abdominal scans.
Consequently, our model has not been exposed to lower abdominal MRI data previously. Furthermore, the spacing between slices in this dataset measures approximately (0.36, 0.36, 5), with a pronounced inter-slice gap. This structural peculiarity poses a significant challenge for our model's adaptation.
To address these challenges, we employ a fine-tuning strategy using the available training data and subsequently evaluate the performance of our model. The results are shown in Table below.

We find that when only one box prompt is used, the performance is not as good as nnUNet, but when we use 3 or more prompts, the performance can exceed nnUNet. Additionally, the segmentation accuracy can be further improved as the number of prompts increases.

| Method             | Prompt   | Rectum | Tumor |
|--------------------|----------|--------|-------|
| nnUNet-2d          |          | 59.62  | 47.56 |
| nnUNet-3d          |          | 68.48  | 61.68 |
| Slide-SAM-finetune | 1 box    | 65.10  | 52.89 |
|                    | 3 boxes  | 75.92  | 61.85 |
|                    | 5 boxes  | 81.11  | 64.48 |
|                    | 10 boxes | 83.96  | 65.12 |



## Computational efficiency:  

We adopt a parallel strategy during inference, that is, divide all adjacent slices into multiple batches, and increase the batch size as large as possible to ensure that as much GPU memory is utilized as possible. Inference is performed on Nvidia Titan RTX 24G and the batchsize is set to 4. For Slide-SAM, the running speed is 3.25 sec/volume, and the GPU memory usage is 14G. For Slide-SAM-H, the running speed is about 10 sec/volume, and the GPU memory usage is 17G. In future, we will also try more mobile-friendly technologies to light-weight and accelerate model inference, such as using EfficientViT as backbone or SAMI pretrain strategy in EfficientSAM, using model compression and distillation technology or other operator acceleration technologies, etc.
Thank you for your valuable reviews, which greatly contributes to refining our work and its practical application in real clinical settings. 

(1) We have added the discussion about more noisy prompts in Appendix. As we are unable to share images, we provide textual descriptions instead. Through our testing, we have discovered that certain types of noise adversely affect prediction accuracy when the box prompt is completely contained within the ground truth bounding box. Optimal performance is achieved when the box prompt slightly exceeds the bounding box. Particularly challenging organs or lesions are more susceptible to noise interference. To address these issues comprehensively, we plan to conduct further testing and optimization in future iterations, ensuring our model's efficacy in diverse real-world scenarios. Our work has been open sourced in github (https://github.com/Curli-quan/Slide-SAM) and the model weights have been released. We sincerely hope that our contribution benefits the medical imaging community, and you are welcome to use our open source project and discover more problems. 

(2) We have added a discussion in Appendix about usage for clinicians. We are exploring the integration of Slide-SAM into existing labeling tools, such as Slicer, as a plug-in. Furthermore, we will provide comprehensive guidelines to assist researchers and clinicians in effectively utilizing our tool.

(3) We have added more description in Figure-1's caption in the revised manuscript.
Thanks for your reviews, which greatly contributes to enhancing the completeness of our work and experiments. We have evaluated SAM-Med3D using the official checkpoint and summarized the results in the table below. It is worth noting that the SAMMed-3D method only supports point prompts, whereas our approach can utilize either point prompts or box prompts. The ability to use box prompts represents an advantage of our method over SAMMed-3D. Therefore, in the performance comparison, we contrasted our performance using box prompts with SAMMed-3D's performance using point prompts. It is evident that our approach yields better results when compared to SAMMed-3D, further affirming the effectiveness and potential of Slide-SAM. 

Additionally, we have added the average performance and fixed all typos in the revised manuscript. 

| WORD testset |          |       |           |           |           |         |             |           |           |
|--------------|----------|-------|-----------|-----------|-----------|---------|-------------|-----------|-----------|
| Method       | Prompt   | Liver | Spleen    | Kidney(L) | Kidney(R) | Stomach | Gallbladder | Esophagus | Pancrease |
| Ours         | 1 box    | 94.36 | 90.01     | 93.04     | 91.39     | 76.46   | 69.03       | 60.75     | 71.84     |
| SAMMed-3D    | 1 point  | 90.38 | 82.83     | 84.1      | 87.24     | 55.28   | 60.56       | 28.02     | 43.49     |
| Method       | Duodenum | Colon | Intestine | Adrenal   | Rectum    | Bladder | Femur(L)    | Femur(R)  | Average   |
| Ours         | 50       | 50.15 | 56.78     | 33.98     | 77.86     | 84.11   | 93.47       | 93.72     | 74.18     |
| SAMMed-3D    | 31.41    | 24.45 | 30.47     | 0.86      | 60.38     | 86.84   | 83.89       | 73.65     | 57.74     |

|  CHAOS testset           |         ||        |        |        |         |
|-----------|---------|---------------|--------|--------|--------|---------|
| Method    | Prompt  | Liver         | Kid(R) | Kid(L) | Spleen | Average |
| Ours      | 1 box   | 88.42         | 91.89  | 90.98  | 90.76  | 90.51   |
| SAMMed-3D | 1 point | 82.8          | 80.25  | 78.49  | 79.37  | 80.22   |

| BTCV testset |         |       |         |        |        |         |
|--------------|---------|-------|---------|--------|--------|---------|
| Method       | Prompt  | Liver | Stomach | Kid(L) | Spleen | Average |
| Ours         | 1 box   | 95.44 | 74.31   | 92.42  | 91.16  | 88.33   |
| SAMMed-3D    | 1 point | 64.31 | 54.73   | 85.98  | 75.38  | 70.10   |