Endometrial cancer (EC) is the sixth most common cancer in women worldwide, with over 417,000 new cases diagnosed in 2020. While most patients are caught at an early stage - when the five-year survival rate is around 81% - late-stage disease carries survival rates as low as 15-17%, making early detection critical.
Atypical endometrial hyperplasia (AEH) is a pre-cancerous condition where the uterine lining cells start to look abnormal. Roughly 28% of AEH cases progress to cancer over 20 years, and up to one-third of women diagnosed with AEH are found to already have hidden endometrial cancer when examined more closely.
Hysteroscopy - a procedure where a thin camera is inserted into the uterus - is the preferred tool for inspecting the uterine cavity and guiding biopsies. While it is generally accurate, studies show that traditional hysteroscopic biopsy still misses EC in 32-45% of pre-operative AEH diagnoses, creating a real need for better diagnostic assistance.
This study introduces ECCADx, a deep learning-based computer-aided diagnosis system designed to analyze hysteroscopy images in real time, helping doctors distinguish dangerous AEH and EC lesions from benign conditions like polyps or normal tissue.
Deep learning is a form of artificial intelligence that learns patterns directly from large collections of images, without being given explicit rules. It has already proven useful in analyzing colonoscopy and gastroscopy images for polyp detection and cancer screening.
Contrastive learning (CL) is a powerful deep learning technique that trains a model to recognize which images are similar and which are different by pushing apart the representations of distinct images while bringing similar ones closer together. This results in richer, more discriminative feature extraction.
The challenge in hysteroscopy AI is the scarcity of large, labeled datasets. The researchers addressed this by first pre-training ECCADx on publicly available colonoscopy image datasets. Although colonoscopy images show the colon rather than the uterus, both are endoscopic images that share low-level visual features like mucosal patterns, vascular structures, and pathological lesion appearances.
After this cross-domain pre-training, the model was fine-tuned on hysteroscopy images from endometrial patients. This strategy - learning broadly from one domain and then specializing in another - is called transfer learning, and it is a key reason ECCADx performs well even with a limited number of hysteroscopy images.
The study collected 55,874 hysteroscopy images from 1,394 patients across three major teaching hospitals in China, spanning data collected over nine years. Images were divided into a training set (1,204 patients, 49,646 images) and two independent test sets from different hospital systems.
The backbone architecture of ECCADx is ResNet-50, a well-established 50-layer convolutional neural network. Images were resized to 224x224 pixels and fed through extensive data augmentation techniques - including simulated lighting changes, color shifts, and simulated instrument shadows - to help the model generalize to real-world variability in imaging equipment.
To handle the challenge of class imbalance (far fewer cancerous cases than benign ones), the team used Focal Loss - a specialized loss function that makes the model pay extra attention to difficult, misclassified examples - combined with an oversampling strategy that duplicates rare positive cases during training.
Two test sets were used: an internal test set from the same hospital as training data, and an external test set from two entirely different hospitals using different imaging equipment (Olympus versus Karl Storz hysteroscopes). Testing on external data is a critical check of whether an AI model will work in the real world beyond the institution where it was developed.
On the internal test dataset, ECCADx with contrastive learning achieved 95.2% sensitivity (correctly identifying cancer/AEH cases) and 91.3% specificity (correctly clearing benign cases), with an AUC of 0.979. These are strong diagnostic metrics, where higher sensitivity minimizes missed cancers and higher specificity minimizes unnecessary biopsies.
On the external test dataset from different hospitals and equipment, ECCADx achieved 92.1% sensitivity and - remarkably - 100% specificity, meaning it correctly cleared every benign case without a single false alarm. The AUC was 0.975.
The AI was directly compared to twelve gynecological endoscopists divided into junior (less than 1 year experience), intermediate (1-5 years), and senior (over 10 years) groups. On both test datasets, ECCADx outperformed all groups on accuracy, AUC, and F1 score. For example, on the external dataset, ECCADx achieved 93.3% accuracy versus 80.2% for senior endoscopists.
The improvement from adding contrastive learning was significant: without CL on the external dataset, AUC was only 0.891 and specificity was just 62.5%. With CL, AUC jumped to 0.975 and specificity reached 100%. This confirms that the contrastive pre-training component is essential, not optional.
t-SNE (t-distributed stochastic neighbor embedding) is a visualization technique that collapses high-dimensional data - in this case, thousands of image features learned by the AI - down to a simple 2D plot, allowing researchers to see whether the model is grouping similar cases together.
Without contrastive learning, t-SNE plots showed heavy overlap between cancerous and benign image clusters. The model was essentially confused, treating many AEH/EC images as similar to benign ones.
With contrastive learning, the clusters became clearly separated and compact - both on internal and external datasets. This visual evidence confirms that CL allows the model to extract more discriminative features, which directly translates into better classification performance.
The researchers also used Grad-CAM (Gradient-weighted Class Activation Mapping), a technique that produces heatmaps highlighting which regions of an image the AI paid attention to when making its decision. These heatmaps focused on clinically meaningful features like abnormal blood vessel patterns, irregular surface structures, and focal necrosis - the same features trained pathologists look for.
The study carefully analyzed the false negative cases - situations where ECCADx incorrectly classified a cancerous case as benign. Two cases involved polyp cystic degeneration (smooth, translucent surfaces that mimic benign polyps) and papillary proliferation (fine delicate fronds resembling normal endometrium). These are genuinely challenging even for experienced physicians.
A key limitation is that ECCADx currently performs only binary classification - it separates AEH/EC from benign conditions but cannot distinguish between specific subtypes like simple hyperplasia, complex hyperplasia, or different histological grades of cancer, which have different clinical implications for treatment planning.
The model was trained on data from a single hospital over nine years, which introduces potential selection bias. Factors like differences in patient demographics, imaging equipment settings, and institutional practices between hospitals can all affect how well a model generalizes.
Another inherent challenge is that human experts themselves show variability - inter-rater agreement among endoscopists on the external dataset ranged from 76-87% accuracy. This underscores that even the gold standard against which AI is compared is imperfect, which creates challenges for measuring true model performance.
One of ECCADx's most important practical advantages is its speed. Because it is built on a fine-tuned ResNet-50 architecture, it can process each hysteroscopy image in milliseconds - fast enough to provide real-time alerts and second opinions during an ongoing hysteroscopic procedure.
The system requires computational resources comparable to running a standard ResNet-50 model, meaning it can run on conventional medical workstations with modern graphics cards. This lowers the barrier to hospital adoption significantly compared to systems requiring specialized hardware.
Unlike human doctors, an AI model does not suffer from fatigue, distraction, or workload pressure - factors that can degrade diagnostic performance during long clinical shifts. ECCADx offers consistent performance regardless of how many cases it has reviewed that day.
The authors envision ECCADx as an assistant tool that helps level performance differences between junior and senior endoscopists, rather than replacing doctors. A junior physician supported by ECCADx could potentially match the diagnostic accuracy of a senior specialist, which has major implications for access to quality care in lower-resource settings.
ECCADx represents a meaningful advance in AI-assisted hysteroscopic diagnosis, demonstrating that deep learning combined with contrastive pre-training can match or exceed experienced human endoscopists in identifying AEH and endometrial cancer across diverse hospital settings.
The multi-center external validation - testing on images from two entirely different hospitals with different equipment - is a critical strength of this study. Most prior AI systems for endometrial diagnosis were validated only at a single institution, limiting confidence in their real-world applicability.
The authors plan to extend ECCADx to multi-class classification, enabling it to distinguish between specific endometrial pathologies rather than just binary malignant/benign categorization. This would make the system far more actionable for treatment planning.
Prospective randomized multicenter trials are planned as the next step to rigorously evaluate whether using ECCADx in routine clinical practice actually improves patient outcomes - such as reducing delayed diagnoses or unnecessary procedures - rather than just improving diagnostic accuracy on test datasets.