Manuscript Offprint
arXiv:2610.39414Anatomical Prior-Guided Routing for 3D Lung Tumor Segmentation
Uihyeon Maeng , Jonghun Kim , and Hyunjin Park
Department of Artificial Intelligence, Sungkyunkwan University, Suwon, Korea
Department of Electrical and Computer Engineering,
Sungkyunkwan University, Suwon, Korea
{uhmaeng,iproj2,hyunjinp}@skku.edu
Abstract. Accurate lung tumor segmentation in computed tomography (CT) is essential for treatment planning, response assessment, and quantitative imaging analysis. However, 3D lung tumor segmentation remains challenging because tumors occupy only a small portion of the whole volume and exhibit heterogeneous appearances across anatomical locations. In patch-based training and sliding-window inference for 3D medical image segmentation, location-dependent heterogeneity is further amplified because cropped image patches provide limited global anatomical context, making it difficult for a model to adapt its feature processing according to the anatomical region from which each patch is extracted. To address this limitation, we propose an Anatomical Prior-guided Routing Module (APRM) for lung tumor segmentation. For each image patch, we obtain anatomical prior information of regional occupancy and deterministically select an anatomical routing gate. The selected gate then performs sparse feature routing over a shared expert adapter pool, enabling anatomy-specific feature adaptation while sharing expert capacity across regions. We evaluate APRM on two datasets with various backbone networks and demonstrate consistent improvements over baseline models. Furthermore, feature visualizations show that APRM produces different feature responses depending on patch location, indicating that the proposed routing mechanism effectively adapts feature processing according to anatomical context.
Keywords: Computed Tomography · 3D Medical Image Segmentation · Anatomical Prior-guided Routing
1 Introduction
Lung cancer is one of the most common cancers worldwide and is characterized by high incidence and mortality rates that demand early detection and precise management . To diagnose and formulate treatment plans, computed tomography (CT) is widely used in clinical practice because it provides
- Equal Contribution
Corresponding Author
U. Maeng et al.

(a) Subtype Distribution of Lung Tumors
(b) Anatomical Distribution of Lung Tumors
Fig. 1: Distribution of lung cancer subtypes and anatomical tumor locations within the NSCLC [1,6,45] dataset. Tumor location is defined as the anatomical region (e.g., right upper lobe) showing the maximum spatial overlap with the tumor. Outside indicates areas around the lungs that do not overlap with any anatomical masks.
a non-invasive way to observe lung tumors and surrounding anatomical structures [9,32]. Accurate lung tumor segmentation is essential for determining tumor extent, supporting treatment planning, evaluating response, and enabling quantitative imaging analysis [20,34,44]. However, tumor segmentation has traditionally relied on manual annotation by experienced clinicians. Manual annotation is inherently time-consuming, labor-intensive, and prone to high interobserver variability, which incurs substantial clinical costs. These limitations motivate deep learning-based automatic segmentation, which can provide efficient tumor annotation. Despite recent advances, lung tumor segmentation remains challenging [34,37]. Lung tumors often occupy only a small fraction of the entire CT volume. In addition, tumor boundaries can be obscured by surrounding anatomy such as the pleura, vessels, bronchi, and mediastinum, leading to location-dependent errors [20,39].
Furthermore, lung tumors exhibit heterogeneity across histological subtypes and their imaging appearance can vary with both subtype and anatomical context [30, 50, 52]. As shown in Fig. 1, both lung cancer subtypes and tumor locations exhibit heterogeneous distributions. In particular, different subtypes appear with different frequencies and lung tumors are not uniformly distributed across anatomical regions. Prior lobe-level analysis has also shown that tumor occurrence and histologic composition differ across anatomical locations, suggesting that tumor subtype and anatomical location are related rather than independent factors [42]. Accordingly, Fig. 2 presents representative cases with different histological subtypes and lobar locations [1]. These examples show that tumor-centered patches can contain diverse local anatomical contexts, including lung parenchyma, pleural or chest-wall interfaces, and regions close to cardiomiastinal structures. Such subtype- and location-dependent heterogeneity may influence boundary conspicuity and apparent tumor shape, while introducing nearby non-tumor tissues that can be confused with the tumor. In addition, medical datasets are often limited in size because data collection and expert annotation are costly [21, 23, 25, 41], making it difficult for conventional segmentation methods to learn the full heterogeneity of lung tumors from image appearance alone. Therefore, incorporating anatomical priors is important: a model should adapt feature processing according to where a tumor patch is located, so that

Fig. 2: Illustration of lung tumor heterogeneity and anatomical context. Left: anatomical prior regions, including the five lung lobes and the central mediastinum. Right: different histological subtypes and lobar locations. The yellow bounding boxes show tumor regions and the red contours indicate tumor annotations.
it can better interpret subtype- and location-dependent tumor appearance and distinguish tumors from surrounding anatomical structures [20, 39].
Mixture-of-experts (MoE) methods perform dynamic routing according to input features, activating only a subset of experts for each input while increasing the overall model capacity [10, 51]. This conditional computation has been used to scale the number of parameters while keeping the number of activated parameters nearly fixed, leading to improved performance and efficiency [10]. Distribution-aware MoE (dMoE) interprets MoE from a control-theoretic perspective as a feedback control that flexibly adapts to heterogeneous medical image data distributions [43]. However, instead of relying only on feature-driven routing, prior knowledge can provide a meaningful control signal by changing the routing strategy according to the anatomical location.
We propose Anatomical Prior-guided Routing Module (APRM) for 3D lung tumor segmentation. We extract anatomical masks using TotalSegmentator [53] and route each image patch based on information from the corresponding anatomical mask. The selected anatomical gate then conditions a router that computes sparse routing weights over a shared expert pool. This design enables anatomical information to guide patch-wise feature adaptation in a stable and interpretable manner, while avoiding the need to allocate a separate expert set to each region. We validate APRM on two datasets with various backbone networks and observe consistent performance improvements when APRM is added to the baseline models. In addition, feature visualizations show that APRM produces different feature responses according to anatomical location, indicating that the proposed module effectively reflects anatomical context during segmentation.
The main contributions of this study are as follows:
- We propose APRM, a plug-in anatomical prior-guided routing module that uses anatomical masks to guide patch-level feature adaptation through gate-conditioned sparse routing.
U. Maeng et al.
-
We validate APRM on two datasets with various backbones, showing consistent performance improvements.
-
We demonstrate that different feature processing occurs according to the anatomical location, showing the effectiveness of the APRM through feature visualization.
2.1 Medical Image Segmentation
Medical image segmentation aims to classify regions of interest, such as lesions, organs, and tumors, at the pixel or voxel level [19, 22, 24, 26–29, 49]. This task is important for diagnosis, treatment planning, surgical guidance, and quantitative analysis. U-Net [47] uses an encoder-decoder structure with skip connections, which is effective for voxel-wise prediction [5, 40, 47]. Many U-shaped variants have been proposed to improve this structure. ResUNet adds residual connections to convolution blocks for training deeper networks [7]. The nnU-Net instead uses a basic U-Net and automatically adapts preprocessing, training settings, and network configuration to each dataset [15]. Transformer-based methods have also been studied to capture wider context. UNETR uses a transformer encoder with a convolutional decoder [12], and SwinUNETR uses a hierarchical Swin Transformer [11]. Since full-resolution 3D volumes require large memory, these methods usually use patch-based training and sliding-window inference [15, 17]. Recent methods also improve U-Net with modern convolution blocks or large-scale pre-training, such as MedNeXt [48] and STUNet [14]. Unlike these works, APRM does not introduce a new backbone. It is a plug-in routing module that can be added to existing segmentation models.
2.2 Anatomical Priors and Mixture-of-Experts
Anatomical priors provide information about body structures and have been used as spatial maps, shape constraints, auxiliary inputs, or post-processing steps in medical image segmentation [13, 31, 36, 54]. Automatic CT parsers such as TotalSegmentator can extract organ masks from CT images [53]. These masks can provide anatomical context for tasks such as lymph-node segmentation [8, 38]. MoE models use conditional computation. A router selects a small number of experts for each token or patch, so the model can increase its capacity without using all experts at once [10, 46, 51, 55]. Recent medical imaging studies have used MoE for continual learning, multi-modal representation, SAM adaptation, and semi-supervised learning [4, 18, 35]. These methods usually use image features, modalities, or prompts for routing. However, feature-based routing methods may overlook anatomical location. In lung tumor segmentation, errors often depend on anatomical location because nearby structures such as the pleura, vessels, and mediastinum can obscure tumor boundaries. We use anatomical priors as the routing context. This allows the model to adapt patch-level features according to the location of each patch.

Fig. 3: Overview of proposed APRM. Anatomical masks are extracted using a pre-trained TotalSegmentator [53]. An anatomical gate is assigned based on these anatomical masks. When the outside region is larger than , the patch is assigned to the outside gate. The selected gate computes top-K sparse weights using shared experts.
3 Method
We propose APRM, which adapts feature processing according to anatomical locations to reflect tumor heterogeneity. APRM is added to all scales of the backbone encoder and applies different feature routing strategies according to the anatomical location of each patch. Fig. 3 provides an overview of APRM. Let input image denote a CT volume, where , , and are the spatial dimensions. Let denote a patch. The image is divided into patches. We define the patch set as
where patch denotes a patch region. The local image patch extracted from a patch region is denoted by . We use an anatomical label map A extracted using TotalSegmentator [53]. We compute the occupancy ratio of anatomical regions in from A for routing gate selection. If the outside proportion exceeds a threshold , the patch is assigned to the outside gate. Otherwise, the anatomical gate is selected from among the five lung lobes and the central region. The selected gates independently route features to the shared experts. This design allows routing to vary according to anatomical context while enabling expert capacity to be shared across multiple anatomical regions.
3.1 Definition of Anatomical Prior
We predefine anatomical regions relevant to lung cancer and extract their masks using TotalSegmentator [53]. We use masks for the five lung lobes: right upper
U. Maeng et al.
lobe (RUL), right middle lobe (RML), right lower lobe (RLL), left upper lobe (LUL), and left lower lobe (LLL). We also define a central region by merging masks of selected mediastinal structures, including the heart, aorta, trachea, esophagus, pulmonary vein, superior vena cava, and inferior vena cava. The anatomical regions, therefore, consist of the five lung lobes and the central region. Areas that do not belong to these six predefined regions are defined as outside, resulting in seven classes:
where C denotes the set of anatomical region classes and denotes the subset excluding the outside region.
3.2 Anatomical Prior-Guided Routing
Gate selection. We obtain the cropped anatomical label map corresponding to the image patch . To determine which anatomical gate should be used for the patch, we calculate the occupancy ratio of each predefined mask in the patch. The anatomical occupancy ratio is defined as
where denotes the total number of voxels in the patch, the numerator counts the voxels in the cropped anatomical label map that belong to class , and 1 is an indicator function. The outside occupancy is computed to classify the patch into outside or anatomical regions. If this value is greater than or equal to the threshold , the patch is defined as outside. If the outside occupancy is smaller than the threshold, the patch is assigned to the class with the largest occupancy among :
where denotes the routing gate for patch . According to the anatomical location classes in Eq. 2, a routing gate is assigned to each anatomical region.
Feature routing with anatomical gates. APRM is applied at each encoder stage and the anatomical gate is selected according to the anatomical location of each patch. The selected gate routes the feature tokens to a shared expert pool, allowing the routing function to be anatomy-specific while keeping the expert capacity shared across all anatomical regions. For expert routing, the feature map at stage is flattened into a spatial token sequence :
where , , , and denote the channel, height, width, and depth at stage s, respectively. After flattening, the feature map is represented by tokens, each with a dimension . For each token , the assigned gate computes sparse expert weights over shared experts and the routed output is obtained as
where M is the number of shared experts, denotes the output of the i-th expert network, and is the sparse routing weight assigned by gate . To prevent the model from relying on only a small subset of experts, we employ noisy top-K routing, which injects Gaussian noise into the routing logits before selecting the active experts. The noisy logits and sparse gating weights are defined as follows:
where and are the learnable parameters of the selected anatomical gate for routing logits and noise scale, respectively. The Softplus function constrains the noise scale to be positive. After all tokens are routed, the updated token sequence is reshaped back to the feature-map resolution:
where is the output feature map at stage s.
3.3 Objective Function
The segmentation objective is defined as the sum of Dice loss and cross-entropy (CE) loss:
In sparse routing, the router may repeatedly assign high probabilities to only a small subset of experts, which can reduce expert diversity and limit the effective capacity of the shared expert pool. To mitigate this issue, we introduce a lightweight expert balancing loss [10]. This loss is computed from the dense softmax probabilities of the selected router before top-K masking, so that all experts receive a learning signal regardless of whether they are selected by the sparse routing operation.
U. Maeng et al.
Using these dense routing probabilities, the average usage probability of expert i at stage s is computed over all tokens in the stage as
The expert balancing loss is then defined by penalizing concentrated average expert usage across the routed encoder stages:
where denotes the set of encoder stages. By minimizing this term, the model is encouraged to distribute the average dense routing probability more evenly across the shared expert pool rather than concentrating on a few experts. The final training objective combines the segmentation loss with the balancing loss as
The balancing weight is empirically set to in our experiments.
3.4 Sampling Process
During training, a cropped region (i.e., patch) is sampled from the input volume I, and the corresponding image patch and anatomical patch are extracted together. The anatomical patch is used to determine the routing gate according to Eq. (4). The anatomical prior used for routing is spatially aligned with the feature tokens processed by APRM at each encoder stage. During sampling, we process the full volume using sliding-window inference with an overlap ratio of 0.5 along each spatial dimension. Predictions from overlapping windows are combined using Gaussian-weighted voxel-wise aggregation, following the standard nnU-Net inference procedure. For each patch, the same crop is applied to the anatomical label map and the patch-level anatomical occupancy is computed to select the corresponding anatomical gate. Predictions from overlapping windows are aggregated in the original image space and the final segmentation is obtained from the merged probability map.
4 Experiments
4.1 Experimental Setup
Datasets. We evaluate 3D lung tumor segmentation using two public CT datasets: NSCLC [1, 6, 45] and MSD [2]. Both NSCLC and MSD are non-small cell lung cancer datasets. NSCLC provides subtype annotations consisting of large cell carcinoma, squamous cell carcinoma (SCC), adenocarcinoma (Aden.), and not otherwise specified (NOS), whereas MSD does not provide subtype information.
Table 1: Quantitative lung tumor segmentation results on the NSCLC [1,6,45] dataset with various backbones. Results are reported for each tumor subtype, where SCC denotes squamous cell carcinoma, Aden. denotes adenocarcinoma, and NOS denotes not otherwise specified. Average indicates the mean performance across all subjects. DSC and IoU are reported as percentages and higher values indicate better performance. Bold indicates the best performance.
| Backbone | Dataset Subtype Module | NSCLC [1,6,45] | |||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| Large cell | SCC | Aden. | NOS | Average | |||||||
| DSC(%) | IoU(%) | DSC(%) | IoU(%) | DSC(%) | IoU(%) | DSC(%) | IoU(%) | DSC(%) | IoU(%) | ||
| nnU-Net [15] | Baseline | 71.30 | 61.28 | 59.18 | 48.05 | 79.66 | 70.70 | 57.66 | 48.27 | 65.64 | 55.64 |
| + MoE | 72.52 | 61.86 | 62.54 | 51.10 | 77.77 | 68.79 | 57.65 | 48.95 | 66.66 | 56.55 | |
| + APRM | 72.38 | 61.39 | 62.38 | 50.93 | 77.30 | 68.05 | 60.62 | 50.90 | 67.29 | 56.75 | |
| ResEnc [16] | Baseline | 73.54 | 62.32 | 63.37 | 51.41 | 84.91 | 75.40 | 64.22 | 54.27 | 70.00 | 59.17 |
| + MoE | 73.27 | 61.83 | 64.10 | 52.53 | 83.48 | 73.94 | 63.20 | 53.65 | 69.63 | 58.94 | |
| + APRM | 73.63 | 62.44 | 63.38 | 51.69 | 86.88 | 77.53 | 66.32 | 56.17 | 70.88 | 60.10 | |
| MedNeXt [48] | Baseline | 66.80 | 56.06 | 54.63 | 43.20 | 70.84 | 59.61 | 57.22 | 47.62 | 64.08 | 53.13 |
| + MoE | 72.76 | 61.91 | 63.04 | 51.36 | 78.70 | 69.60 | 60.54 | 51.03 | 67.76 | 57.30 | |
| + APRM | 72.52 | 61.43 | 65.53 | 53.54 | 85.37 | 75.20 | 58.38 | 49.37 | 68.81 | 58.16 | |
| STUNet [14] | Baseline | 72.44 | 61.37 | 57.00 | 46.68 | 75.46 | 65.73 | 58.75 | 49.56 | 65.05 | 54.88 |
| + MoE | 66.68 | 56.47 | 62.29 | 51.15 | 76.12 | 66.04 | 60.54 | 51.43 | 65.28 | 55.06 | |
| + APRM | 73.27 | 62.30 | 56.48 | 46.12 | 79.67 | 69.41 | 60.67 | 50.68 | 66.31 | 55.87 | |
Following the nnU-Net preprocessing setup, both datasets were resampled to a target spacing of and have an image size of . NSCLC is used for model training and evaluation. MSD is used as an external test dataset. From NSCLC, we use 319 subjects for training and 80 subjects for test. From MSD, we use 63 subjects for test.
Implementation details. All methods are implemented using the nnU-Net framework [15, 16]. The input shape of was automatically determined during the nnU-Net preprocessing steps. We use the training objective in Eq. (15), with the balancing loss weight set to . Anatomical masks are extracted using TotalSegmentator [53]. We use seven anatomical routing gates and a shared expert pool per routed stage with experts and Top-K parameter set to . For the +MoE, we use the same expert architecture, number of experts , top-K sparsity , and sparse weighted aggregation as APRM, but use a single feature-driven router.
Evaluation metrics. We use Dice similarity coefficient (DSC) and intersection over union (IoU) to evaluate volumetric segmentation performance.
Comparison backbones. We compare four backbone architectures: the U-Net [47] architecture in nnU-Net [15], ResEnc [16], MedNeXt [48], and STUNet [14]. All backbones are trained and evaluated within the nnU-Net framework.
4.2 Results of Lung Tumor Segmentation
Results on NSCLC. We compare APRM with the baseline and MoE across several backbones, as shown in Table 1. Among the backbones, ResEnc achieves
U. Maeng et al.

Fig. 4: Qualitative lung tumor segmentation results. Left: comparison with different modules using ResEnc as the backbone. Right: comparison with different modules using MedNeXt as the backbone. The top two rows show results for different NSCLC tumor subtypes, while the bottom row shows results on the MSD dataset. Each result shows a zoomed-in view of the yellow bounding box in the image.
the best performance. Adding MoE improves the results for most tumor subtypes, while Adding APRM improves the performance of all backbones and achieves the best average scores for every backbone. These results indicate that anatomy-guided routing enables effective feature adaptation across heterogeneous tumor groups. Fig. 4 (top) shows qualitative results on NSCLC, where the tumors have different sizes and locations depending on the subtype. The baseline often fails to segment the tumor region and MoE captures part of the tumor but misses fine details. In contrast, APRM produces results that are closest to the ground truth. These results show that APRM can segment tumors well across different locations and sizes, demonstrating the effectiveness of the proposed module.
Results on MSD. We also evaluate each baseline and our module on MSD, which is used as an external test dataset. The quantitative results are shown in Table 2. Consistent with the results on NSCLC, ResEnc achieves the best performance among the baseline models, while APRM improves segmentation performance across all evaluated backbones. The bottom row examples in Fig. 4 show qualitative results on MSD using ResEnc and MedNeXt for two cases: a large tumor on the left and a small tumor on the right. In the left case, the comparison methods miss a region that is separated from the main large tumor,
Table 2: Quantitative lung tumor segmentation results on the MSD dataset [2]. Bold indicates the best performance.
| Backbone | Dataset | MSD [2] | |
|---|---|---|---|
| Module | DSC(%) | IoU(%) | |
| nnU-Net [15] | Baseline | 54.86 | 43.09 |
| + MoE | 55.18 | 43.11 | |
| + APRM | 58.41 | 46.32 | |
| ResEnc [16] | Baseline | 66.38 | 53.47 |
| + MoE | 65.91 | 53.30 | |
| + APRM | 66.72 | 54.02 | |
| MedNeXt [48] | Baseline | 49.36 | 37.69 |
| + MoE | 62.49 | 49.96 | |
| + APRM | 62.91 | 50.33 | |
| STUNet [14] | Baseline | 56.28 | 43.99 |
| + MoE | 55.94 | 43.83 | |
| + APRM | 58.93 | 46.83 | |
Table 3: Ablation study on the NSCLC and MSD. ResEnc is used as the backbone.
| Category | Dataset Setting | NSCLC [1, 6, 45] | MSD [2] | ||
|---|---|---|---|---|---|
| DSC(%) | IoU(%) | DSC(%) | IoU(%) | ||
| Top-K sparsity | 70.54 | 59.93 | 65.06 | 52.36 | |
| 70.88 | 60.10 | 66.72 | 54.02 | ||
| Number of experts | 70.80 | 60.21 | 65.74 | 53.29 | |
| 70.88 | 60.10 | 66.72 | 54.02 | ||
| Outside threshold | 69.83 | 59.06 | 66.56 | 53.91 | |
| 70.88 | 60.10 | 66.72 | 54.02 | ||
| 70.32 | 59.61 | 66.15 | 53.39 | ||
whereas APRM correctly detects it as part of the tumor. In the right case, the tumor is very small, and the comparison methods fail to detect it, while APRM successfully captures the tumor region.
4.3 Ablation Studies
Top-K sparsity. We observe how the top-K setting affects the sparse routing strategy, as shown in Table 3 (top). Using the top two experts to aggregate features improves segmentation performance on both NSCLC and MSD compared with using only the top expert. Based on this result, we set in our experiments.
Number of experts. We compare different values of the number of experts in the shared expert pool, as shown in Table 3 (middle). Both and achieve similar performance, with providing a slight improvement. This result suggests that performance does not simply increase by adding more experts. Rather, the routing mechanism dynamically selects the features needed for each input from the shared expert pool. Based on these results, we use in our experiments.
Outside threshold. We evaluate different values of the outside threshold and observe their effect on segmentation performance, as shown in Table 3 (bottom). Because most voxels within a patch are background on average and only a limited portion corresponds to lung-related anatomy, a relatively high is needed to reliably determine the anatomical location of each patch. At the lower value , performance decreases noticeably, indicating that many patches are assigned to the outside category and the model consequently relies predominantly on the outside gate. This behavior makes the performance close to that of ResEnc + MoE in Tables 1 and 2. In contrast, at the higher value , even a small overlap with an anatomical mask can determine the patch location, which may make anatomical distinctions ambiguous and lead to degraded performance. We obtain the best performance with .
U. Maeng et al.

Fig. 5: Visualization of anatomical patch selection for anatomical gate assignment. Left: an upper (superior) slice closer to the head. Right: a lower (inferior) slice closer to the abdomen. In each patch image, the upper-left label indicates the selected anatomical region, while the upper-right inset shows the distribution of anatomical masks.
4.4 Computational Cost Analysis
We report computational cost using nnU-Net as the backbone. As shown in Table 4, although APRM adds additional anatomy-specific router parameters from 0.017M to 0.122M due to the seven anatomy-specific gates, the total parameter count increases only from 49.38M to 49.48M ( 0.2%) compared with MoE. Importantly, for each patch, APRM evaluates only the router associated with the selected anatomical gate rather than densely executing all seven routers. Accordingly, segmentation inference increases only modestly from 48.57s to 50.41s ( 3.8%).
Table 4: Computational cost on the NSCLC test set using nnU-Net. Inference time reports segmentation processing only.
| Method | Total params | Router params | Infer. time (s) |
|---|---|---|---|
| nnU-Net | 30.70M | - | 22.14 ± 4.80 |
| + MoE | 49.38M | 0.017M | 48.57 ± 15.01 |
| + APRM | 49.48M | 0.122M | 50.41 ± 15.46 |
4.5 Analysis of Anatomical Prior-guided Routing
Anatomical patch selection. Fig. 5 visualizes how patch locations are identified and how anatomical gates are selected during inference. In the upper-left patch of Fig. 5 (left), only a small portion overlaps with the right upper lobe; therefore, the patch is assigned to the outside region according to . In the next patch, both the right upper lobe and left upper lobe are present, and the background ratio is below . Therefore, the right upper lobe is selected because it occupies the largest anatomical mask area. Although the exact tumor location is not explicitly given to the model, sliding-window inference allows each patch to be assigned to different anatomical regions and processed through the corresponding anatomical gates. This enables the model to select

Fig. 6: Visualization of expert features according to anatomical location. Each image shows the voxels for which the corresponding expert is selected as the top-1 expert and the red contour denotes the tumor region. The aggregation map represents the final feature map obtained after sparse routing.
segmentation-relevant features from multiple anatomical contexts and dynamically reflect heterogeneity caused by tumor location, size, and subtype. A similar trend is observed in Fig. 5 (right).
Routing feature visualization. We further visualize the features represented by the shared experts, as shown in Fig. 6. Because different experts are assigned at the voxel level, each expert produces a distinct top-1 voxel map. For the right upper lobe gate ( , top row), tumor-related regions are mainly selected by Experts 2 and 3: Expert 2 focuses on the tumor interior, while Expert 3 responds to the tumor boundary. The aggregation feature map preserves these complementary tumor-related responses. For the right lower lobe gate ( , second row), tumor-related regions are represented by Experts 1 and 7, showing a routing pattern that differs from that of the right upper lobe gate, and their aggregated feature map also clearly highlights the tumor region. Similarly, for the left upper lobe gate ( , third row), Experts 4 and 5 are selected for tumor-related regions. The central and outside gates also select different experts to represent tumor regions. These observations show that, although all anatomical gates share the same expert pool, different experts are assigned depending on the anatomical context and tumor appearance. Thus, the proposed model learns gate-specific routing strategies within the shared expert pool, enabling it to capture heterogeneity in tumor location and size and extract effective segmentation features.
U. Maeng et al.
5 Discussion
We proposed APRM to incorporate anatomical priors into patch-based 3D lung tumor segmentation. By selecting an anatomical gate for each patch and routing features through a shared expert pool, APRM enables location-aware feature adaptation without assigning separate experts to each anatomical region. The experimental results show that APRM consistently improves segmentation performance across multiple backbones on the NSCLC dataset and also generalizes to the external MSD dataset. Compared with a standard MoE module, APRM provides more stable gains, indicating that anatomical context is useful beyond simply increasing model capacity. The ablation and visualization results further show that sparse routing with shared experts learns different feature responses for different anatomical regions, helping the model capture tumor interiors, boundaries, and location-dependent heterogeneity.
Limitations. The proposed method depends on anatomical masks extracted by a pretrained segmentation model. Although this makes APRM practical because it does not require manual anatomical annotation, errors in the anatomical masks may lead to incorrect gate assignment, especially near lobe boundaries, mediastinal structures, or abnormal anatomy. The anatomical categories used in this work are defined at a relatively coarse level, including lung lobes, the central region, and an outside region. Finer anatomical subdivisions or vessel- and airway-aware priors may provide additional context for tumors with complex local interactions, but they may also increase routing ambiguity and computational cost. The current framework uses deterministic patch-level gate selection based on anatomical occupancy. This improves stability and interpretability, but it may be suboptimal for patches containing multiple relevant anatomical structures. Future work could explore soft anatomical routing, uncertainty-aware gate assignment, or joint optimization of anatomical priors and tumor segmentation.
Acknowledgement
This study was supported by the SMC-SKKU Future Convergence Research Program Grant (SMO126115). It was also supported by the AI Graduate School Support Program (Sungkyunkwan University) (RS-2019-II190421), the National Research Foundation of Korea (RS-2024-00408040, RS-2026-25598771), the ICT Creative Consilience Program Grant (IITP-2026-RS-2020-II201821), the Institute of Information & Communications Technology Planning & Evaluation (IITP) grant (RS-2026-25528384, Resource-Intensive AI Technologies Based on Sustainable GPU Integrated Platforms), the IITP grant (IITP-2026-RS-2026-25615334, AI Star Fellowship Support Program), and an IITP grant for the AI Computing Support Project for R&D (RS-2026-25505492, High-Performance Research AI Computing Infrastructure Support at the 2 PFLOPS Scale), all funded by the Ministry of Science and ICT (MSIT), Republic of Korea.
References
-
Aerts, H.J., Velazquez, E.R., Leijenaar, R.T., Parmar, C., Grossmann, P., Carvalho, S., Bussink, J., Monshouwer, R., Haibe-Kains, B., Rietveld, D., et al.: Decoding tumour phenotype by noninvasive imaging using a quantitative radiomics approach. Nature communications 5(1), 4006 (2014)
-
Antonelli, M., Reinke, A., Bakas, S., Farahani, K., Kopp-Schneider, A., Landman, B.A., Litjens, G., Menze, B., Ronneberger, O., Summers, R.M., et al.: The medical segmentation decathlon. Nature communications 13(1), 4128 (2022)
-
Bray, F., Laversanne, M., Sung, H., Ferlay, J., Siegel, R.L., Soerjomataram, I., Jemal, A.: Global cancer statistics 2022: Globocan estimates of incidence and mortality worldwide for 36 cancers in 185 countries. CA: a cancer journal for clinicians 74(3), 229–263 (2024)
-
Chen, Q., Zhu, L., He, H., Zhang, X., Zeng, S., Ren, Q., Lu, Y.: Low-rank mixture-of-experts for continual medical image segmentation. In: International Conference on Medical Image Computing and Computer-Assisted Intervention. pp. 382–392. Springer (2024)
-
Çiçek, Ö., Abdulkadir, A., Lienkamp, S.S., Brox, T., Ronneberger, O.: 3d u-net: learning dense volumetric segmentation from sparse annotation. In: International conference on medical image computing and computer-assisted intervention. pp. 424–432. Springer (2016)
-
Clark, K., Vendt, B., Smith, K., Freymann, J., Kirby, J., Koppel, P., Moore, S., Phillips, S., Maffitt, D., Pringle, M., et al.: The cancer imaging archive (tcia): maintaining and operating a public information repository. Journal of digital imaging 26(6), 1045–1057 (2013)
-
Diakogiannis, F.I., Waldner, F., Caccetta, P., Wu, C.: Resunet-a: A deep learning framework for semantic segmentation of remotely sensed data. ISPRS Journal of Photogrammetry and Remote Sensing 162, 94–114 (2020)
-
Engelson, S., Ehrhardt, J., Kepp, T., Niemeijer, J., Handels, H.: Lnq challenge 2023: Learning mediastinal lymph node segmentation with a probabilistic lymph node atlas. arXiv preprint arXiv:2406.03984 (2024)
-
Ettinger, D.S., Wood, D.E., Aisner, D.L., Akerley, W., Bauman, J., Chirieac, L.R., D'Amico, T.A., DeCamp, M.M., Dilling, T.J., Dobelbower, M., et al.: Non-small cell lung cancer, version 5.2017, nccn clinical practice guidelines in oncology. Journal of the National Comprehensive Cancer Network 15(4), 504–535 (2017)
-
Fedus, W., Zoph, B., Shazeer, N.: Switch transformers: Scaling to trillion parameter models with simple and efficient sparsity. Journal of Machine Learning Research 23(120), 1–39 (2022)
-
Hatamizadeh, A., Nath, V., Tang, Y., Yang, D., Roth, H.R., Xu, D.: Swin unetr: Swin transformers for semantic segmentation of brain tumors in mri images. In: International MICCAI brainlesion workshop. pp. 272–284. Springer (2021)
-
Hatamizadeh, A., Tang, Y., Nath, V., Yang, D., Myronenko, A., Landman, B., Roth, H.R., Xu, D.: Unetr: Transformers for 3d medical image segmentation. In: Proceedings of the IEEE/CVF winter conference on applications of computer vision. pp. 574–584 (2022)
-
Huang, H., Zheng, H., Lin, L., Cai, M., Hu, H., Zhang, Q., Chen, Q., Iwamoto, Y., Han, X., Chen, Y.W., et al.: Medical image segmentation with deep atlas prior. IEEE transactions on medical imaging 40(12), 3519–3530 (2021)
-
Huang, Z., Wang, H., Deng, Z., Ye, J., Su, Y., Sun, H., He, J., Gu, Y., Gu, L., Zhang, S., et al.: Stu-net: Scalable and transferable medical image segmen-
U. Maeng et al.
tation models empowered by large-scale supervised pre-training. arXiv preprint arXiv:2304.06716 (2023)
-
Isensee, F., Jaeger, P.F., Kohl, S.A., Petersen, J., Maier-Hein, K.H.: nnu-net: a self-configuring method for deep learning-based biomedical image segmentation. Nature methods 18(2), 203–211 (2021)
-
Isensee, F., Wald, T., Ulrich, C., Baumgartner, M., Roy, S., Maier-Hein, K., Jaeger, P.F.: nnu-net revisited: A call for rigorous validation in 3d medical image segmentation. In: International Conference on Medical Image Computing and Computer-Assisted Intervention. pp. 488–498. Springer (2024)
-
Jeon, Y.S., Yang, H., Fu, H., Kway, Y., Feng, M.: No more sliding window: efficient 3d medical image segmentation with differentiable top-k patch sampling. In: International Conference on Medical Image Computing and Computer-Assisted Intervention. pp. 376–386. Springer (2025)
-
Jiang, Y., Shen, Y.: M4oe: A foundation model for medical multimodal image segmentation with mixture of experts. In: international conference on medical image computing and computer-assisted intervention. pp. 621–631. Springer (2024)
-
Jo, G., Kim, J., Park, B.Y., Park, H.: Deafusion: Detail-aware image fusion for whitematter hyperintensity segmentation. In: 2024 IEEE International Conference on Bioinformatics and Biomedicine (BIBM). pp. 3361–3366. IEEE (2024)
-
Kashyap, M., Wang, X., Panjwani, N., Hasan, M., Zhang, Q., Huang, C., Bush, K., Chin, A., Vitzthum, L.K., Dong, P., et al.: Automated deep learning-based detection and segmentation of lung tumors at ct imaging. Radiology 314(1), e233029 (2025)
-
Kim, J., Kim, M., Park, H.: Domain aware multi-task pretraining of 3d swin transformer for t1-weighted brain mri. In: Asian Conference on Computer Vision. pp. 121–141. Springer (2024)
-
Kim, J., Na, I., Chung, J., Song, H.N., Kim, K., Ju, S., Eun, M.Y., Seo, W.K., Park, H.: Enhancing intracranial vessel segmentation using diffusion models without manual annotation for 3d time-of-flight magnetic resonance angiography. Computerized Medical Imaging and Graphics p. 102651 (2025)
-
Kim, J., Na, I., Ko, E.S., Park, H.: Tumor synthesis conditioned on radiomics. In: 2025 IEEE/CVF Winter Conference on Applications of Computer Vision (WACV). pp. 3635–3646. IEEE (2025)
-
Kim, J., Na, I., Kwon, J., Seo, W.K., Park, H.: Weakly-supervised segmentation using sparse single point annotations for lumen and wall of carotid arteries in 3d mri. Computer Methods and Programs in Biomedicine 269, 108881 (2025)
-
Kim, J., Park, H.: Visual prompt tuning for task-flexible medical image synthesis. Computer Methods and Programs in Biomedicine p. 109244 (2026)
-
Kwon, J., Kim, J., Kim, T., Seo, S.W., Cho, H.h., Park, H.: Blood pressure assisted cerebral microbleed segmentation via meta-matching. In: International Conference on Medical Image Computing and Computer-Assisted Intervention. pp. 77–86. Springer (2025)
-
Kwon, J., Kim, J., Park, H.: Leveraging segmentation-guided spatial feature embedding for overall survival prediction in glioblastoma with multimodal magnetic resonance imaging. Computer Methods and Programs in Biomedicine 255, 108338 (2024)
-
Kwon, J., Seo, S.W., Park, H.: Anatomically-guided segmentation of cerebral microbleeds in t1-weighted and t2*-weighted mri. In: International Conference on Medical Image Computing and Computer-Assisted Intervention. pp. 24–33. Springer (2024)
-
Kwon, J., Seo, S.W., Park, H.: Enhancing cerebral microbleed segmentation with pretrained unetr++. In: 2024 IEEE International Conference on Bioinformatics and Biomedicine (BIBM). pp. 3372–3377. IEEE (2024)
-
Lambe, G., Durand, M., Buckley, A., Nicholson, S., McDermott, R.: Adenocarcinoma of the lung: from bac to the future. Insights into imaging 11(1), 69 (2020)
-
Larrazabal, A.J., Martínez, C., Glocker, B., Ferrante, E.: Post-dae: anatomically plausible segmentation via post-processing with denoising autoencoders. IEEE transactions on medical imaging 39(12), 3813–3820 (2020)
-
Latimer, K.M., Mott, T.F.: Lung cancer: diagnosis, treatment principles, and screening. American family physician 91(4), 250–256 (2015)
-
Li, C., Wang, H., Jiang, Y., Fu, W., Liu, X., Zhong, R., Cheng, B., Zhu, F., Xiang, Y., He, J., et al.: Advances in lung cancer screening and early detection. Cancer biology & medicine 19(5), 591–608 (2022)
-
Li, J., Liu, J., Wang, W., et al.: Systematic review and meta-analysis of deep learning applications in ct lung cancer segmentation. Biomed. Signal Process. Control 89, 105804 (2024)
-
Li, R., Wu, L., Gu, J., Xu, Q., Chen, W., Cai, X., Bu, J.: Moe-sam: Enhancing sam for medical image segmentation with mixture-of-experts. In: International Conference on Medical Image Computing and Computer-Assisted Intervention. pp. 367–377. Springer (2025)
-
Liu, L., Wolterink, J.M., Brune, C., Veldhuis, R.N.: Anatomy-aided deep learning for medical image segmentation: a review. Physics in Medicine & Biology 66(11), 11TR01 (2021)
-
Liu, X., Song, L., Liu, S., Zhang, Y.: A review of deep-learning-based medical image segmentation methods. Sustainability 13(3), 1224 (2021)
-
Mathai, T.S., Liu, B., Summers, R.M.: Segmentation of mediastinal lymph nodes in ct with anatomical priors. International journal of computer assisted radiology and surgery 19(8), 1537–1544 (2024)
-
Mercieca, S., Belderbos, J.S., van Herk, M.: Challenges in the target volume definition of lung cancer radiotherapy. Translational lung cancer research 10(4), 1983 (2021)
-
Milletari, F., Navab, N., Ahmadi, S.A.: V-net: Fully convolutional neural networks for volumetric medical image segmentation. In: 2016 fourth international conference on 3D vision (3DV). pp. 565–571. Ieee (2016)
-
Na, I., Kim, J., Ko, E.S., Park, H.: Radiomicsfill-mammo: Synthetic mammogram mass manipulation with radiomics features. In: International Conference on Medical Image Computing and Computer-Assisted Intervention. pp. 723–733. Springer (2024)
-
Nilssen, Y., Brustugun, O.T., Fjellbirkeland, L., Helland, Å., Møller, B., Wahl, S.G.F., Solberg, S.: Distribution and characteristics of malignant tumours by lung lobe. BMC Pulmonary Medicine 24(1), 106 (2024)
-
Oh, Y., Jin, P., Park, S., Kim, S., yoon, S., Kim, J.S., Kim, K., Li, X., Li, Q.: Distribution-aware fairness learning in medical image segmentation from a control-theoretic perspective. In: Forty-second International Conference on Machine Learning (2025), https://openreview.net/forum?id=BUONdewsBa
-
Primakov, S.P., Ibrahim, A., van Timmeren, J.E., Wu, G., Keek, S.A., Beuque, M., Granzier, R.W., Lavrova, E., Scrivener, M., Sanduleanu, S., et al.: Automated detection and segmentation of non-small cell lung cancer computed tomography images. Nature communications 13(1), 3423 (2022)
U. Maeng et al.
-
Prior, F., Smith, K., Sharma, A., Kirby, J., Tarbox, L., Clark, K., Bennett, W., Nolan, T., Freymann, J.: The public cancer radiology imaging collections of the cancer imaging archive. Scientific data 4(1), 170124 (2017)
-
Riquelme, C., Puigcerver, J., Mustafa, B., Neumann, M., Jenatton, R., Susano Pinto, A., Keysers, D., Houlsby, N.: Scaling vision with sparse mixture of experts. Advances in Neural Information Processing Systems 34, 8583–8595 (2021)
-
Ronneberger, O., Fischer, P., Brox, T.: U-net: Convolutional networks for biomedical image segmentation. In: International Conference on Medical image computing and computer-assisted intervention. pp. 234–241. Springer (2015)
-
Roy, S., Koehler, G., Ulrich, C., Baumgartner, M., Petersen, J., Isensee, F., Jaeger, P.F., Maier-Hein, K.H.: Mednext: transformer-driven scaling of convnets for medical image segmentation. In: International conference on medical image computing and computer-assisted intervention. pp. 405–415. Springer (2023)
-
Rue, N., Jo, G., Na, I., Oh, S., Lee, H.Y., Park, H.: Label-free lung mri segmentation via misalignment-aware diffusion translation. Journal of Imaging Informatics in Medicine pp. 1–17 (2026)
-
Sasaki, T., Kuno, H., Hiyama, T., Oda, S., Masuoka, S., Miyasaka, Y., Taki, T., Nagasaki, Y., Ohtani-Kim, S.J.y., Ishii, G., et al.: 2021 who classification of lung cancer: molecular biology research and radiologic-pathologic correlation. Radiographics 44(3), e230136 (2024)
-
Shazeer, N., Mirhoseini, A., Maziarz, K., Davis, A., Le, Q., Hinton, G., Dean, J.: Outrageously large neural networks: The sparsely-gated mixture-of-experts layer. arXiv preprint arXiv:1701.06538 (2017)
-
Shi, L., Zhao, J., Wei, Z., Wu, H., Sheng, M.: Radiomics in distinguishing between lung adenocarcinoma and lung squamous cell carcinoma: a systematic review and meta-analysis. Frontiers in Oncology 14, 1381217 (2024)
-
Wasserthal, J., Breit, H.C., Meyer, M.T., Pradella, M., Hinck, D., Sauter, A.W., Heye, T., Boll, D.T., Cyriac, J., Yang, S., et al.: Totalsegmentator: robust segmentation of 104 anatomic structures in ct images. Radiology: Artificial Intelligence 5(5), e230024 (2023)
-
You, X., He, J., Yang, J., Gu, Y.: Learning with explicit shape priors for medical image segmentation. IEEE Transactions on Medical Imaging 44(2), 927–940 (2024)
-
Zhou, Y., Lei, T., Liu, H., Du, N., Huang, Y., Zhao, V., Dai, A.M., Le, Q.V., Laudon, J., et al.: Mixture-of-experts with expert choice routing. Advances in Neural Information Processing Systems 35, 7103–7114 (2022)