## 7 Discussion  
For the purpose of the assessment of receptive and nonreceptive endometrial stages, we proposed a metric-driven approach, which is based on an image segmentation model and evaluation of nucleus size and density. Utilizing a customized dataset obtained through collaboration with Tartu University and the Lithuanian University of Health Sciences, the proposed technique and three additional deep architectures were tested. There are several issues that can induce misdetection and misclassification. The quality of the image collection used to segment the endometrial glands has a direct influence on the accuracy of the segmentation. It should be noted that various specialists may annotate the identical whole-slide picture of an endometrial biopsy differently due to differences in opinion on the borders of the glands. The accurate segmentation of endometrial tissue is a difficult task that requires several years of practice to master if it is conducted manually. Furthermore, histological image aberrations, uneven biopsy slide lighting, and image noise can all contribute to erroneous segmentation of endometrial glands. The minimum DPI (dots per inch) for input images is important for our endometrium segmentation model's accuracy. Higher resolution generally leads to better results. However, the computational resources should be considered. The selection of image size is influenced by the desired balance between image resolution and processing speed. In our research, we selected an image resolution of 4 pixels per 1 \(\upmu\)m. The ensemble-based method's attained detection accuracy comes at the expense of processing time. Since the ensemble technique is based on three deep neural networks, it takes three times longer to provide predictions. On a GPU graphics card, three separate segmentation models were trained and tested. The Nvidia RTX4090 with 24 GB of internal RAM was utilized. The identical custom training dataset and hyperparameters were used to train all three neural networks. To train the U-Net autoencoder that consists of 7.7 trainable parameters, less than 22 h is needed. The training of residual U-Net (21.6 trainable parameters) required up to 50 h. On average, 29 h are needed to train the U-Net++ (9.1 trainable parameters) segmentation network. In total, it took 105 h (less than 5 days) to train all ensemble-based segmentation models. Several strategies can be employed to potentially improve the overall performance when all three models demonstrate poor outcomes. The proposed endometrial assessment method can be used for a deeper analysis of images. By using the metric-driven approach, we could objectively demonstrate that the receptive endometrium had a higher density of stromal cell nuclei next to the endometrial glands compared to the pre- or post-receptive phases. This is in accordance with the generally applied pathohistological dating  
Figure 9: The rational histograms of the stromal cell’s nucleus are derived using (**a**) a 30 \(\upmu\)m grid, (**c**) a 50 \(\upmu\)m grid, (**b**) at the 30 \(\upmu\)m range from endometrial glands, and (**d**) at the 50 \(\upmu\)m range from endometrial glands, where the black color curve represents the receptive stage, the red dashed line represents pre-receptive values, and the post-receptive stage values are presented with the blue curve. criteria that describe increasing stromal edema in the post-receptive endometrium as the fluids push the stromal cells further apart. An interesting additional finding is the smaller stromal cell size in the receptive stage compared to the pre- and post-receptive stages. The pathohistologist is normally incapable of routinely measuring the stromal cell sizes, which are very small. Ensemble methods enhance histology image segmentation by combining predictions from multiple models. This combination leads to higher accuracy, capturing intricate tissue details. It also boosts robustness, making segmentation more reliable despite image noise or staining variations.