Enhancing the Predictions of Cytomegalovirus Infection in Severe Ulcerative Colitis Using a Deep Learning Ensemble Model: Development and Validation Study
Abstract
BACKGROUND: Cytomegalovirus (CMV) reactivation in patients with severe ulcerative colitis (UC) leads to worse outcomes; yet, early detection remains challenging due to the reliance on time-intensive biopsy procedures. OBJECTIVE: This study explores the use of deep learning to differentiate CMV from severe UC through endoscopic imaging, offering a potential noninvasive diagnostic tool. METHODS: We analyzed 86 endoscopic images using an ensemble of deep learning models, including DenseNet (Densely Connected Convolutional Network) 121 pretrained on ImageNet. Advanced preprocessing and test-time augmentation (TTA) were applied to optimize model performance. The models were evaluated using metrics such as accuracy, precision, recall, F1-score, and area under the curve. RESULTS: The ensemble approach, enhanced by TTA, achieved high performance, with an accuracy of 0.836, precision of 0.850, recall of 0.904, and an F1-score of 0.875. Models without TTA showed a significant drop in these metrics, emphasizing TTA's importance in improving classification performance. CONCLUSIONS: This study demonstrates that deep learning models can effectively distinguish CMV from severe UC in endoscopic images, paving the way for early, noninvasive diagnosis and improved patient care.