{'fraction_non_alphanumeric': 0.03646055437100213, 'fraction_numerical': 0.01673773987206823, 'mean_word_length': 4.824588637069233, 'pattern_counts': {'":': 0, '<': 0, '<?xml version=': 0, '>': 0, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
Unsupervised Cross-Modality Domain Adaptation for Segmenting Vestibular Schwannoma and Cochlea with Data Augmentation and Model Ensemble

Magnetic resonance images (MRIs) are widely used to quantify vestibular schwannoma and the cochlea. Recently, deep learning methods have shown state-of-the-art performance for segmenting these structures. However, training segmentation models may require manual labels in target domain, which is expensive and time-consuming. To overcome this problem, domain adaptation is an effective way to leverage information from source domain to obtain accurate segmentations without requiring manual labels in target domain. In this paper, we propose an unsupervised learning framework to segment the VS and cochlea. Our framework leverages information from contrast-enhanced T1-weighted (ceT1-w) MRIs and its labels, and produces segmentations for T2-weighted MRIs without any labels in the target domain. We first applied a generator to achieve image-to-image translation. Next, we ensemble outputs from an ensemble of different models to obtain final segmentations. To cope with MRIs from different sites/scanners, we applied various 'online' augmentations during training to better capture the geometric variability and the variability in image appearance and quality. Our method is easy to build and produces promising segmentations, with a mean Dice score of 0.7930 and 0.7432 for VS and cochlea respectively in the validation set.


Introduction
Vestibular schwannoma (VS) is a benign tumor of the human hearing system. For better understanding the disease progression, quantitative analysis of VS and cochlea from magnetic resonance images (MRIs) is important. Recently, deep learning frameworks have been dominating the medical segmentation field [12,14,2,6,11,10] with state-of-the-art performances. However, supervised learning methods often require a high level of consistency between training and testing data. Consequently, such supervised methods often lack domain generalizability or ability to deal with images from various sites that have different intensity distributions, i.e., distribution shift or domain shift. Such a shift is usually caused by different image acquisition protocols or scanners; different image modalities could also be considered a domain shift problem.
Furthermore, in medical image analysis, lack of human delineations in one or multiple domains is another common issue, which is problematic for supervised learning. Unsupervised domain adaptation (UDA) is a solution for increasing generalizability of deep learning models to deal with new data from different domains.
In the cross-MoDA challenge 4 , the ceT1-weighted and T2-weighted MRIs are provided, but only ceT1-weighted MRIs are labeled by experts. To obtain the segmentations on T2-weighted MRIs, we consider it as a UDA problem and propose an unsupervised cross-modality domain adaptation framework for segmenting the VS and cochlea. Our framework contains 2 parts: synthesis and segmentation. For synthesis, we apply a CycleGAN [16] to perform unpaired image translation between ceT1-weighted and T2-weighted MRIs. For segmentation, we use the generated T2-weighted MRIs as input and train an ensemble of models with various data augmentations, each of which yields candidate segmentations of VS and cochlea. We fuse those candidate segmentations to form the final segmentation.

Related work
Supervised learning is an effective way for medical image segmentation when sufficient labels are available in target domain. Wang et al. [14] proposed an attention-based 2.5D convolutional neural network (CNN) to segment VS from T2-weighted MRIs with anisotropic resolution. In a following publication, Shapey et al. [12] employed this 2.5D CNN and further explored the performance of segmenting VS on both T1-weighted and T2-weighted MRIs. As we know, obtaining manual annotations is labor-intensive and time-consuming. Dorent et al. [2] introduced a novel weakly-supervised domain adaptation framework for VS segmentation on T2-weighted MRIs. In their work, only scribbles are needed as weak supervision in the target domain. They leveraged information from T1weighted (source domain) MRIs to segment VS in the target domain based on co-segmentation and structured learning. However, in scenarios where there is no label available in target domain, UDA is a solution. Typical UDA methods try to align the image features between source domain and target domain [5,1]. Once the features are well aligned, downstream tasks, such as segmentation, are relatively easy to accomplish. CycleGAN [16] and MUNIT [4] are popular methods to achieve unpaired image translation. Huo et al. [5] propose an end-toend framework for unpaired synthesis between CT and MRI images, and jointly

Dataset
The cross-modality domain adaptation for medical image segmentation challenge dataset (cross-MoDA 5 ) contains two different MRI modalities: contrastenhanced T1-weighted (ceT1-weighted) with an in-plane resolution of 0.4 × 0.4mm and slice thickness between 1 − 1.5mm, and high-resolution T2-weighted with an in-plane resolution of 0.5×0.5mm and slice thickness between 1−1.5mm. ceT1-weighted imaging was performed with an MPRAGE sequence and T2weighted imaging with 3D CISS or FIESTA sequence. The training set contains 105 ceT1-weighted and 105 T2-weighted MRIs, and the validation set contains 32 T2-weighted MRIs. Expert manual VS and cochlea labels are available for the 105 ceT1-weighted training MRIs. More detailed information about this dataset can be found in 6 .

Overall framework
Fig. 1 displays our proposed framework. There are two parts in our framework: synthesis (Syn) and segmentation (Seg). For the Syn part, the 3D ceT1-weighted image, after undergoing pre-processing, is fed to the CycleGAN [16] pipeline to achieve image-to-image translation (ceT1-weighted to T2-weighted). Data augmentation strategies are applied on the generated T2-weighted MRIs to increase the model robustness. We send the augmented data into four different models: a 2.5D model with two different augmentation schemes, a 3D model with attention module, and a 3D model without attention module. We finally employ a union operation to fuse the outputs of each model to form the final segmentation.

Preprocessing and postprocessing
Our preprocessing pipeline contains 5 steps: (1) non-local mean filter denoising, (2) image alignment with MNI template by rigid registration, (3) bias field correction, (4) image cropping based on region of interest (ROI), and (5) linear intensity normalization with range [0,1]. Before rigid registration, MNI template was resampled to the size of 512 × 512 × 128 voxel 3 , with spatial resolution 0.377 × 0.447 × 1.508 mm 3 . The ROIs are identified based on the labels of ceT1weighted MRIs. We first make a common bounding box by taking the union of each bounding box over all labels. In order to cover all structures from all MRIs, the bounding box was then extended to the size 256 × 128 × 48 voxel 3 . In postprocessing, we extracted the largest connected component for VS from the network output. Finally, we applied the inverse transformation from the rigid registration (step 2 of preprocessing) to move the segmentations back to their original space.

Synthesis: Image-to-image translation
The CycleGAN [16] framework is used for image-to-image translation in 2D. We first split the 3D cropped ROIs into 2D slices. Next, we feed those 2D slices to the CycleGAN for training; in this context, we consider the ceT1-weighted and T2-weighted MRIs to be two different domains. After the training process, we stack 2D slices back together to form a 3D MRI volume. The model convergence is determined based on the best performance by visual inspection at each epoch.

Data augmentation
Data augmentation is widely used in medical image segmentation to help minimize the gap between datasets/domains, producing more robust segmentations. Here, we design an 'online' augmentation strategy during training and randomly apply data transformations to input images. These transformations are in 3 different groups: -Spatial augmentation. 3 types of random spatial augmentation are used: affine transformation with angle range of [−10 • , 10 • ], and scale factor from 0.9 to 1.2; elastic deformation with control points = 7, max displacement = 6; and a combination of affine and elastic deformation [9]. The same spatial augmentations and parameters are applied to both MRIs and the labels.
-Image appearance augmentation. To minimize the different image appearance between MRIs from different sites and scanners, we randomly apply multi-channel Contrast Limited Adaptive Equalization (mCLAHE) and gamma correction with γ from 0.5 to 2 to adjust image contrast.
-Image quality augmentation. In this context, image quality refers to resolution and noise level. We randomly blur the image using Gaussian kernel with σ blur from 0.5 to 1.5, we add Gaussian noise with σ noise = 0.01, and we sharpen the image by I s = I b + (I b − I bb ) × α, where I s is sharpened image, I b is the image blurred with a Gaussian kernel (σ blur ), and I bb is the image blurred twice with the same Gaussian kernel. In our case, we set α = 10, σ blur = 1.5.

Segmentation: 2.5D model and its architecture
We leverage a 2.5D CNN [14] model to alleviate the impact of the anisotropic image resolution. Network architecture details can be found in Fig. 2  and a decoder, and the skip connections between encoder and decoder. The max-pooling and deconvolution operations connect the features between levels.
Batch normalization and parametric rectified linear unit (pReLU) are used in the network architecture. An attention module is applied to assist in segmenting the small ROI. A second 2.5D model with identical architecture was also used in the ensemble, with the only difference being in the gamma correction parameter in the augmentation stage (with γ ∈ [0.5, 1.5] rather than [0.5, 2]).

Segmentation: 3D model and its architecture
We used a fully convolutional neural network for our 3D models [6]. The network architecture details can be found in Fig. 3. Similar to a 3D U-Net, it consists of an encoder and a decoder. 3D max-pooling and 3D nearest neighbor upsampling are used in both the encoder and decoder. We further reinforce the output by adding the feature maps at the end of each level. In one of our two 3D models, we employ an attention module in the skip connections to emphasize the small ROI and preserve the information from encoder to decoder. Note that the two 3D models are identical except the attention module.

Implementation details
The Adam optimizer was used with L2 penalty of 0.00001, β 1 = 0.9, β 2 = 0.999 and an initial learning rate of 0.0002 for the CycleGAN generators [16] and 0.0001 for the segmentation models [14,12,6]. For the generators, the learning rate was left at the initial value for the first 100 epochs, and then dropped to 0 in following 100 epochs. For segmentation models, learning rate was decayed by a factor of 0.5 every 50 epochs. We evaluated our generator and segmentation models every epoch and selected the optimal model based on visual inspection of image quality for generator, and Dice score for segmentation. Based on the Dice loss [7], we defined our loss function as 1−mean(Dice) from multiple labels, with equal weight (w F G = 1) for all foreground labels and decayed weight (w BG = 0.1) for the background. The training, which has a batch size of 2, was conducted on NVIDIA GPUs and implemented using PyTorch.

Quantitative results
Tab. 1 displays the quantitative results of our methods in the validation phase, reported as mean(stdev). The initial result of our method is shown as baseline in the Tab. 1, which uses the resampled MRIs without any cropping as input to the 3D model with attention module. Different crop sizes in the preprocessing step leads to different results, as evidenced by the results presented in Tab. 1. By adding various data augmentations, the performance of segmentation network is dramatically improved, 7.8% and 11.1% on Dice scores for VS and cochlea respectively. Lastly, using the model ensemble boosts the Dice score of VS to nearly 80%. We submitted the proposed method as our final result in the validation phase of the cross-MoDA challenge.

Qualitative results
Representative qualitative results from 4 different subjects can be viewed in Fig. 4. In the first row of Fig. 4, we observe that our 2.5D method produces an accurate segmentation. Varying the augmentation parameters of the 2.5D model improves performance in some challenging cases (e.g., fourth row of Fig. 4-(c)). However, in some cases, both 2.5D models under-segments the VS, which can be seen in the second and third rows of Fig. 4-(b,c). In such cases, 3D models compensate for this tendency of the 2.5D models. Although the attention module has good ability to capture small ROIs, which can be observed in the second row of Fig. 4-(e), it may also lead to over-fitting (first and third rows of Fig. 4-(e)). Thus, we also include a 3D model without attention module (first and third rows of Fig. 4-(d)) in the model ensemble for best results. The model fusion balances the strengths of the individual models and is able to produce consistently good segmentations in a variety of images ( Fig. 4-(f)).

Discussion
There are four main design choices of our method that merit discussion: (1) cropping ROI, (2) image-to-image translation, (3) segmentation network, and (4) self-training strategy.
-Cropping ROI. Given the small size of the segmented objects and the overall MRI size, cropping an ROI is an essential preprocessing step. Using the cropped ROI as input not only reduces redundant computation and improves the computational efficiency by letting the network focus on the the structures of interest increases accuracy. An additional benefit is the reduced GPU memory requirements. However, determining the optimal size for cropped MRIs is not straightforward. Too small ROIs might not fully contain all the structures of interest; however, too large ROIs would negatively impact the quality of the image-to-image translation and segmentation results by increasing the intensity variability in the input samples. How to balance the size of ROIs and the quality of generated MRIs from image-to-image translation remains an important problem.
-Image-to-image translation. Image-to-image translation is a critical step in our pipeline and generally in UDA problems [5,1]. Moreover, generating well-aligned pseudo T2-weighted MRIs from source domain (i.e., from ceT1weighted MRIs) could determine the accuracy of segmentations in the target domain, by minimizing the gap between the two domains. Thus, choosing a suitable image-to-image translation method is important. In our experiments, we employ CycleGAN [16], a popular method for unpaired imageto-image translation. However, synthesis artifacts (intensity shift between slices) appear along the depth direction of generated images in 2D Cycle-GAN. This is a common issue of 2D CycleGAN for translating volumetric MRIs, since slices are mapped independently from each other during training.
We also found that 3D CycleGAN requires large amount of GPU memory, and the quality of images generated by using downsampled input MRIs is not satisfactory. Furthermore, patch-based 3D CycleGAN approaches could blur MRIs along the borders of the patches. However, modifying the architecture of the generator in CycleGAN pipeline could lead to satisfactory results [15]. Thus, improving the quality of results from image-to-image translation is another way to boost the performance. This argument is not only about the training manner of CycleGAN pipeline, but also more generally for methods such as CUT [8] and MUNIT [4].
-Segmentation network. In our pipeline, the segmentation performance is primarily determined by the quality of the generated MRIs in the target domain. Nevertheless, given the same input MRIs, different segmentation models produce different results. In our work, we combine results from an ensemble of models to form the final segmentation, since each model could bring different advantages, even with small changes. The design choices then become the specific models and the ensembling strategy. Additional models with different hyper-parameters could thus improve the segmentation results. The good performance of the top teams in the challenge [3] suggests that the nnU-Net [13], which is a well-known framework for biomedical image segmentation, could provide a good alternative for our ensemble models. Additionally, while we currently use a simple union operation, a more sophisticated ensembling strategy could be designed to minimize the weaknesses of each model while maximizing the strengths.
-Self-training strategy. Finally, the training strategy contributes to the accuracy of segmentation results. Compared to other teams [3], our training strategy is potentially the biggest limitation of our work, since we just use traditional supervised learning after generating T2-weighted MRIs. Following this training strategy, we only use the generated images instead of the real images in the segmentation task, which leads to our model lacking information in the original target domain. In an ideal situation, the features of generated T2-weighted MRIs should be very close or identical to the target domain, and the segmentation model could achieve a good accuracy by leveraging those features. However, given the limitations of image-to-image translation, not all of the generated T2-weighted MRIs are well-aligned to the target domain. Self-training could be a good approach to better handle such situations in the challenge [3]; this may involve directly segmenting real T2weighted MRIs by a pre-trained model with generated T2-weighted MRIs as inputs, and designing an algorithm to find plausible segmentations among the results. Next, we could use these plausible segmentations as 'ground truths' to further fine-tune the pre-trained segmentation model. Iterating this process could further improve the segmentation accuracy. We believe that using such a self-training strategy would improve the final segmentation results.

Conclusion
In this work, we proposed an unsupervised cross-modality domain adaptation framework for VS and cochlear segmentation. There are two parts in our framework: synthesis and segmentation. We applied various 'online' data augmentations to deal with the MRIs from different sites and scanners. In addition, a model ensemble is used for increasing the performance. In the validation stage of the crossMoDA challenge, our method shows promising results.