Transformer-based Deep Learning Model for Automated Detection of Panretinal Photocoagulation Scars on Ultrawide-Field Images

Milan Bahi, Daniel Uriel Gonzalez Quezada, Raul Garrido Garcia, Xiyu Yang, Cameron Mehran Ashrafzadeh, Hassan Naushad Jessani, Vivian Paraskevi Douglas, Sakshi Shiromani, Ward Fickweiler, Jennifer K. Sun, Lloyd P. Aiello, Paolo S. Silva, Mauricio Santillana
Investigative Ophthalmology & Visual Science
Volume 67, Issue 7
June 15, 2026

Purpose : To develop and evaluate a deep-learning model that detects panretinal photocoagulation (PRP) scars on ultrawide-field (UWF) retinal images using dual-view (raw and optimized) inputs, and to assess the impact of automated PRP detection on models for diabetic retinopathy (DR) severity grading.

Methods : UWF images from 6343 eyes with documented receipt of PRP treatment were collected. Certified reading center graders labeled PRP present/absent regardless on extent or density. Each image was processed to generate an illumination-normalized optimized UWF view by local subtraction using a radius-based Gaussian filter with a selected offset to homogenize brightness. A vision transformed deep neural network was trained separately on raw UWF color and optimized UWF images to classify PRP present vs absent. To train various models, four configurations were tested by combining the two types of UWF images, raw and optimized, with the decision to either include or exclude a data augmentation technique. Data were split into training (60%), validation (20%), and held-out test (20%) sets. Performance for PRP detection was evaluated using AUC, sensitivity, specificity, and F1-score.

Results : The best performing model measured by balanced accuracy was trained using the optimized dataset without data augmentation, achieving an AUC of 0.9936, sensitivity of 92.67%, specificity of 97.12%, and an F1-score of 0.8872. The test set contained 15% eyes with prior PRP and 85% without PRP, for which the best model achieved an AUC of 0.9975 for PRP detection, with sensitivity 97.91%,specificity 98.42% and an F1-score of 0.9468.

Conclusions : A vision transformer-based deep-learning model, trained on optimized UWF images, demonstrated high accuracy, sensitivity, and specificity in automatically detecting PRP on UWF images. This allows for detection of historical treatment status directly from images which may improve phenotyping and decision support in large-scale screening programs. Future model development will be aimed at quantifying the extent, distribution and density of PRP scars to enable objective assessment of treatment adequacy and residual ischemic burden.

‍

Related publications