A multi-task neural network for atypical mitosis recognition under domain shift


Abstract

Recognizing atypical mitotic figures in histopathology images allows physicians to correctly assess tumor aggressiveness. Although machine learning models could be exploited for automatically performing such a task, under domain shift these models suffer from significative performance drops. In this work, an approach based on multi-task learning is proposed for addressing this problem. By exploiting auxiliary tasks, correlated to the main classification task, the proposed approach, submitted to the track 2 of the MItosis DOmain Generalization (MIDOG) challenge, aims to aid the model to focus only on the object to classify, ignoring the domain varying background of the image. The proposed approach shows promising performance in a preliminary evaluation conducted on three distinct datasets, i.e., the MIDOG 2025 Atypical Training Set, the AMi-Br dataset, as well as the preliminary test set of the MIDOG25 challenge.

Mitosis classification, Domain shift, Multi-Task Learning

masarno@unisa.it

Introduction↩︎

Characterizing mitotic figures in histopathology images in order to detect atypical mitoses, i.e., cells that do not follow a structured division pattern, allows physicians to have an indicator of the aggressiveness of a cancer. Deep neural networks can be exploited for aiding physicians in such a classification task. However, as these models are generally trained under the assumption that training and test data are sampled from the same domain, they fail in generalizing on data from domains that are different from the training ones [1]. In the context of histopathology, domain shift across datasets may occur due to several factors, such as variations in the image acquisition scanner or laboratory, in the analysed tissue or tumor type, as well as in the species which subjects belong to.
The MItosis DOmain Generalization (MIDOG) challenge [2] addresses the problem of developing machine learning models robust to domain shift for mitosis detection and characterization in histopathology images. In particular, the track 2 of this challenge deals with the problem of characterizing mitotic figures as typical or atypical mitoses. To address this problem, in this work, we propose an approach that exploits multi-task learning (MTL) as a strategy for increasing model robustness against domain shift.

Materials and methods↩︎

The proposed approach consists in a multi-task neural network that exploits, at training time, auxiliary tasks, as a regularization strategy against domain shift. Specifically, two auxilary dense-classification tasks correlated to the main task, i.e., mitosis binary segmentation and pixel-level mitosis classification, are exploited in the proposed MTL approach: the motivation is that, as such dense classification tasks explicitely provide the model with information about the localization of the object to classify, they could make an implict regularising contribution to the training process, aiding the model to focus only on the object of interest, regardless of possible variations in the image background, caused for instance by variations in the analysed tissue type across domains. In the following subsections, details about the proposed method are provided.

Mitosis segmentation mask extraction↩︎

In order to provide to our multi-task neural network supervision signals for carrying out the auxiliary dense-classification tasks, a ground truth segmentation mask for each mitosis has been extracted, by means of the segmentation model NuClick [3]. This is an open-source interactive segmentation model, capable of segmenting cells in histopathology images, based on point annotations related to the cells to be segmented.
In this work, the coordinates of the center of each mitosis within the original .tiff files have been extracted from the metadata of the provided datasets, and they have been passed to NuClick for extracting the mitosis segmentation mask in such images.

Figure 1: The proposed multi-task network

Network architecture↩︎

In Figure 1, the proposed multi-task neural network is shown. It consists of a backbone, shared across the performed tasks, followed by three task-specific heads. As the network backbone, the Pre-Activated ResNet-50 presented in [4] has been exploited, due to its capability of preserving, during feature extraction, the information needed for nuclei localization within histopathology images. Following the Pre-Activated ResNet-50 backbone, the proposed network consists of three task-specific heads, for carrying out the three addressed tasks, i.e., the main image-level mitosis classification task, and the auxiliary mitosis binary segmentation and pixel-level mitosis classification. As regards the network head for the main task, it consists of three stacked fully connected layers, interleaved by ReLU activation functions. Concerning instead the task-specific heads for the two auxiliary tasks, they have been designed as U-Net-like decoders: each decoder, in particular, consists of three up-sampling blocks, each of which upsamples the spatial dimension of the input feature maps by a factor of 2. Skip connections are further exploited for allowing each decoder to better recover spatial details in the upsampling operations.

Training procedure↩︎

The proposed network was trained for 50 epochs, using Adam as optimizer with learning rate \(4\times10^{-5}\) and batch size equal to 24. As a loss function, the sum of three losses, one for each addressed task has been exploited: specifically, a weighted binary cross entropy, with weights inversely proportional to class frequency, was exploited for carrying out the main classification task, while Dice loss [5] was used for both the auxiliary tasks.
To increase the variability of the training dataset, online data augmentation has been exploited, through random rotations, random flips, as well as stain augmentation.

Inference↩︎

At inference time, task-specific heads associated to auxiliary tasks are pruned from the network, so as to allow it to perform only the main classification task.
To further improve model generalization capability, model ensembling and test-time-augmentation have been included in the inference pipeline: on one side, the predictions of the best found models in our leave-one-domain out cross validation scheme are combined according to a major voting aggregation scheme; on the other hand, the predictions of each model on different perturbed view of the analysed images are averaged to improve its robustness.

Results↩︎

Dataset↩︎

The proposed approach was evaluated on two datasets, i.e., MIDOG 2025 Atypical Training Set and AMi-Br. The MIDOG 2025 Atypical Training Set [6] consists of atypical mitotic figure subclassification for the entire MIDOG++ dataset, encompassing 11,939 mitotic figures from all 7 domains of MIDOG++. Each domain, in particular, consists of images acqured through a certain scanner in a certain center, and referring to a certain tumor type in a a subject belonging to a certain species.
The AMi-Br [7] dataset containts atypical mitotic figure subclassification for the MIDOG 2021 and the TUPAC16 challenge datasets [[8]][9]. The dataset consists of 3,720 annotated mitoses, split into 832 atypical and 2888 normal mitotic figures. In the conducted experiments, this dataset has been exploited as an additional test set, to further evaluate the robustness of the proposed method. In particular, only the portion of this dataset belonging to the TUPAC dataset has been exploited, in order to avoid superpositions with the images characterizing the MIDOG 2025 Atypical Training Set.

Experimental Protocol↩︎

Experiments have been performed according to a leave-one-domain-out protocol, carried out on the MIDOG 2025 Atypical Training Set. Specifically, in each experiment, the domains within this dataset have been splitted into 5 training domains, 1 validation domain, and 1 test domain. Model selection was performed based on the value of loss on the validation domain.
In the conducted experiments, model performance has been assessed by measuring model balanced accuracy over each of the test sets of the leave-one-domain-out protocol, as well as on the AMi-Br dataset.

Table 1: Mean and standard deviation of the balanced accuracy evaluated on the validation and test domains, as well as on the dataset AMi-Br, across the leave-one-domain-out experiments
Model Validation Test Test AMi-Br
Single task \(0.842_{\pm 0.049}\) \(0.819_{\pm 0.067}\) \(0.793_{\pm 0.013}\)
MTL \(\boldsymbol{0.847}_{\pm 0.046}\) \(\boldsymbol{0.833}_{\pm 0.051}\) \(\boldsymbol{0.806}_{\pm 0.013}\)

Experimental Results↩︎

The performance of the proposed method on both validation and test sets of leave-one-domain-out experiments, as well as on the AMi-Br test set are reported in Table 1. As can be observed, the use of a MTL strategy for dealing with domain shift positively contributes to model performance on data belonging to different domains from the training ones.
On the preliminary test set of MIDOG25 track 2, instead, the proposed approach achieves a balanced accuracy of 0.875, confirming its promising generalization capability under domain shift.

Discussion↩︎

In this work, an MTL approach has been proposed for addressing the problem of atypical mitosis recognition in histopathology images, under domain shift. The proposed approach, in particular, exploits at training time auxiliary dense-classification tasks for reducing model sensitivity to variations in the image background, caused for instance by variations in the analysed tissue or tumor type across domains.
In the conducted experiments on two distinct datasets, as well as in the evaluation conducted on the preliminary test set of the track 2 of the MIDOG25 challenge, the proposed approach shows promising performance.

Bibliography↩︎

References↩︎

[1]
Mostafa Jahanifar, Manahil Raza, Kesi Xu, Trinh Thi Le Vuong, Robert Jewsbury, Adam Shephard, Neda Zamanitajeddin, Jin Tae Kwak, Shan E Ahmed Raza, Fayyaz Minhas, et al. Domain generalization in computational pathology: survey and guidelines. ACM Computing Surveys, 57 (11): 1–37, 2025.
[2]
Jonas Ammeling, Marc Aubreville, Sweta Banerjee, Christof A. Bertram, Katharina Breininger, Dominik Hirling, Peter Horvath, Nikolas Stathonikos, and Mitko Veta. Mitosis DomainGeneralizationChallenge 2025. Zenodo, March 2025. .
[3]
Navid Alemi Koohbanani, Mostafa Jahanifar, Neda Zamani Tajadin, and Nasir Rajpoot. Nuclick: A deep learning framework for interactive segmentation of microscopic images. Medical Image Analysis, 65: 101771, 2020. ISSN 1361-8415. .
[4]
Simon Graham, Quoc Dang Vu, Shan E Ahmed Raza, Ayesha Azam, Yee Wah Tsang, Jin Tae Kwak, and Nasir Rajpoot. Hover-net: Simultaneous segmentation and classification of nuclei in multi-tissue histology images. Medical Image Analysis, 58: 101563, 2019. ISSN 1361-8415. .
[5]
Carole H Sudre, Wenqi Li, Tom Vercauteren, Sebastien Ourselin, and M Jorge Cardoso. Generalised dice overlap as a deep learning loss function for highly unbalanced segmentations. In International Workshop on Deep Learning in Medical Image Analysis, pages 240–248. Springer, 2017.
[6]
Marc Aubreville, Frauke Wilm, Nikolas Stathonikos, Katharina Breininger, Taryn A Donovan, Samir Jabari, Mitko Veta, Jonathan Ganz, Jonas Ammeling, Paul J van Diest, et al. A comprehensive multi-domain dataset for mitotic figure detection. Scientific data, 10 (1): 484, 2023.
[7]
Christof A Bertram, Viktoria Weiss, Taryn A Donovan, Sweta Banerjee, Thomas Conrad, Jonas Ammeling, Robert Klopfleisch, Christopher Kaltenecker, and Marc Aubreville. Histologic dataset of normal and atypical mitotic figures on human breast cancer (ami-br). In BVM Workshop, pages 113–118. Springer, 2025.
[8]
Marc Aubreville, Nikolas Stathonikos, Christof A Bertram, Robert Klopfleisch, Natalie Ter Hoeve, Francesco Ciompi, Frauke Wilm, Christian Marzahl, Taryn A Donovan, Andreas Maier, et al. Mitosis domain generalization in histopathology images—the midog challenge. Medical Image Analysis, 84: 102699, 2023.
[9]
Mitko Veta, Paul J Van Diest, Stefan M Willems, Haibo Wang, Anant Madabhushi, Angel Cruz-Roa, Fabio Gonzalez, Anders BL Larsen, Jacob S Vestergaard, Anders B Dahl, et al. Assessment of algorithms for mitosis detection in breast cancer histopathology images. Medical image analysis, 20 (1): 237–248, 2015.