Manuscript Offprint

arXiv:2610.24037

Benchmarking and Improvement of Artifact Segmentation Methods in H&E-Stained Whole Slide Imaging

Julia Merta, Daniel Mendelsohn, Benedikt Schoser, Joanna Polanska, Michal Marczyk

Abstract

Technical artifacts introduced during tissue preparation or slide scanning remain a major obstacle to developing robust computational pathology algorithms for hematoxylin and eosin (HE)-stained whole-slide images (WSIs). Despite the growing number of quality-control tools, their real-world utility remains hard to assess because of the limited number of publicly available implementations and the lack of systematic, multi-dataset comparisons. This paper presents a benchmark of artifact segmentation methods for HE-stained WSIs. After a literature review, six publicly available algorithms were selected and compared in terms of their ability to segment artifact-free tissue and selected artifact classes. Two publicly available datasets and a newly introduced dataset released to support further research were used for evaluation. Tissue samples from multiple medical centers and different organs are included, enabling evaluation across heterogeneous data sources. Segmentation performance was assessed using Dice Index, pixel-level recall, and false discovery rate for artifact-free tissue segmentation. For algorithms supporting multiclass artifact segmentation, class-wise Dice Index and inter-class misclassification were evaluated. In addition to segmentation quality, pro-

*Corresponding authors

Email addresses: julia.merta@polsl.pl (Julia Merta), michal.marczyk@polsl.pl (Michal Marczyk) cessing time was assessed. Statistical analysis revealed significant differences in segmentation performance between methods. HistoKit, which incorporates a modified version of the GrandQC, was identified as the best-performing algorithm, while HistoQC was the worst. In terms of artifact types, dark spots and out of focus regions were harder to segment than others. Finally, a simple post-processing step was introduced for HistoKit, which further improved segmentation performance. The benchmark establishes a reference for evaluating and developing artifact segmentation methods for HE-stained WSIs.

Keywords: Whole Slide Imaging, Artifact Segmentation, HE-stained Images, Computational Pathology

1. Introduction

Whole Slide Imaging (WSI), introduced in 1999, enables the creation of high-resolution digital slides of tissue specimens, supporting the development of extensive public repositories for educational and research purposes [60]. This advancement greatly facilitates slide storage and transfer between institutions, which speeds up collaboration among pathologists at medical centers worldwide [47]. As computing power increased and newer scanners entered the market, computational pathology (CPath) has emerged as a discipline focused on analyzing histological data through machine learning and image processing algorithms [22]. Recently, numerous deep learning-based methods have been developed for the automated analysis of WSI to assist physicians and speed up the diagnostic process [13]. Models based on convolutional neural networks (CNNs) and vision transformers (ViTs) represent state-of-the-art approaches for tasks such as cell or tissue segmentation, prediction of various clinical characteristics of a tissue, or survival risk regression [54, 12].

Currently, major challenges stand in the way of the widespread adoption of CPath in clinical practice. Although existing methods achieve excellent results on distinct datasets, they often perform poorly on unseen data, posing a significant barrier to their implementation in real-world environments [47, 22]. Moreover, the effectiveness of deep learning models is highly dependent on the representativeness of the training dataset [46, 20]. Therefore, successful deployment requires models with good generalization capabilities that can accommodate the variability present in histology data. This hetero-

Figure

Figure 1: Overview of the study design and algorithm comparison workflow. Six publicly available algorithms: GrandQC [51], HistoKit [32], HistoQC [23], HistoROI [34], Patil et al. [35], and Schreiber et al. [39], were evaluated based on segmentation quality, artifact classification, and processing time. Three datasets comprising multiple artifact classes were used in this study. The annotated classes included dark spots and foreign objects (DS), air bubbles and other edge-like artifacts (EDGE), tissue folds (FOLD), out-of-focus regions (OOF), and pen-marker traces of different colors (PEN), as well as artifact-free tissue (TIS) and background (BG). For Dataset A, background and artifact regions were considered jointly. Additionally, the parameters of the boundary discordance reduction for the best-performing method were examined. Moreover, a post-processing method for the artifact mask for the top-performing algorithm to further enhance segmentation quality.

geneity arises from multiple sources, but mostly from differences in staining protocols and different types of artifacts [22].

Artifacts are unwanted structures or inconsistencies that obstruct clear visualization of tissue morphology [45]. They may be introduced during any stage of WSI preparation. Kanwal et al. [26] classified WSI artifacts into three primary categories: tissue-level, slide-level, and scan-level artifacts.

Tissue-level artifacts arise during tissue preparation, a stage that requires significant precision and expertise in both laboratory procedures and sample collection [29]. The final appearance of the tissue specimen is influenced by numerous variables. Minor variations in preparation protocols, such as fixation time, temperature, tissue thickness, or reagent volumes, are almost inevitable in routine laboratory practice. Therefore, establishing a universal protocol for all laboratories is nearly impossible [52]. Several types of tissue-level artifacts can occur during slide preparation. For example, excessive dehydration of the tissue can cause it to shrink. Cracks in tissue may also be seen, most often resulting from a dull knife or an improperly performed cut. Another common finding is tissue folding. Unfortunately, artifacts from this group are often challenging or even impossible to repair. In most cases, this would require repeating the sample collection process or even performing a new biopsy [26].

Slide-level artifacts can occur in the final stages of the pathology workflow, including slide mounting and storage. These include foreign objects such as dust, hair, and microorganisms, as well as air bubbles introduced during coverslip placement, pen markings in different colors, and dirt. Although marker traces can be removed prior to scanning [26], they remain common, even in public databases such as The Cancer Genome Atlas (TCGA) [6].

Scan-level artifacts occur during tissue scanning, with blur being the most prevalent. This artifact is considered one of the most critical in WSI [41]. Out-of-focus regions may result from improper focal calibration or uneven tissue thickness. Furthermore, certain scanners can introduce distortions along the borders of stitched patches, resulting in strip- or grid-like patterns when illumination is inadequate [53]. These artifacts are generally independent of the specimen on the slide. Therefore, removing them simply requires re-scanning the slide [26]. However, this process entails additional labor and time that could otherwise be devoted to other tasks.

In CPath, artifacts are more common and often have a greater influence on model outcomes than in natural images. This is because differences between tissues or biological conditions are more subtle and harder to detect, meaning that even minor distortions can have a significant impact on the models predictions, which may lead to an incorrect diagnosis [58]. Consequently, quality inspection is an essential component of the data processing workflow [47]. This process enables the analysis to focus on artifact-free regions or to entirely exclude low-quality WSI images from further evaluation. Moreover, this step enables identification of issues in specimen preparation and scanning protocol. This may help determine whether a laboratory can make changes to improve slide quality [51].

Numerous methods have recently been developed for searching artifacts in WSIs. Nevertheless, there is a lack of systematic comparisons evaluating the effectiveness of these methods across multiple manually annotated datasets using segmentation quality metrics. Furthermore, few publicly avail-able datasets for multiclass artifact segmentation exist. This study addresses these research gaps. Figure 1 presents an overview of the study workflow.

The main contributions of this work are as follows:

  • We prepared a new dataset for technical artifact segmentation, containing manually annotated labels for multiple artifact classes. The dataset enables the evaluation of segmentation methods at the WSI level and includes images from multiple organs and databases.

  • We performed a literature review and comprehensive comparison of existing methods for artifact segmentation in HE-stained images, along with a statistical analysis of their performance and computation time. To the best of our knowledge, this is the first comparison of this scale to have been conducted.

• We introduced a simple post-processing method to a leading artifact segmentation algorithm that improves detection of technical artifacts.

In our study, we limited the analyzed datasets to those containing HE-stained images, as this staining method is the most widely used in pathology. Furthermore, most currently available artifact detection tools have been developed exclusively for this staining technique.

References (60)