Skip to main content

ORIGINAL RESEARCH article

Front. Neurol., 09 April 2024
Sec. Neurotechnology
This article is part of the Research Topic Artificial Intelligence and telemedicine: applications to vascular neurology, neuro-ophthalmology, neuro-otology, and epilepsy View all 3 articles

Machine learning approach for ambient-light-corrected parameters and the Pupil Reactivity (PuRe) score in smartphone-based pupillometry

\r\nAleksander Bogucki&#x;Aleksander Bogucki1Ivo John
&#x;Ivo John1*&#x;ukasz ZinkiewiczŁukasz Zinkiewicz1Micha&#x; JachuraMichał Jachura1Damian Jaworski,Damian Jaworski2,3Karolina Suwa&#x;a,Karolina Suwała2,4Hugo ChrostHugo Chrost1Michal Wlodarski
Michal Wlodarski1*Jakub Ka&#x;uny,Jakub Kałużny2,4Doug CampbellDoug Campbell5Paul BakkenPaul Bakken5Shawna PandyaShawna Pandya5Rados&#x;aw ChrapkiewiczRadosław Chrapkiewicz1Sanjay G. Manohar
Sanjay G. Manohar1*
  • 1Solvemed Inc., Lewes, DE, United States
  • 2Oftalmika Eye Hospital, Bydgoszcz, Poland
  • 3Division of Ophthalmology and Optometry, Department of Ophthalmology, Collegium Medicum, Nicolaus Copernicus University, Bydgoszcz, Poland
  • 4Department of Sensory Organ Studies, Collegium Medicum, Nicolaus Copernicus University, Bydgoszcz, Poland
  • 5Space Medicine Group, International Institute for Astronautical Sciences, Boulder, CO, United States

Introduction: The pupillary light reflex (PLR) is the constriction of the pupil in response to light. The PLR in response to a pulse of light follows a complex waveform that can be characterized by several parameters. It is a sensitive marker of acute neurological deterioration, but is also sensitive to the background illumination in the environment in which it is measured. To detect a pathological change in the PLR, it is therefore necessary to separate the contributions of neuro-ophthalmic factors from ambient illumination. Illumination varies over several orders of magnitude and is difficult to control due to diurnal, seasonal, and location variations.

Methods and results: We assessed the sensitivity of seven PLR parameters to differences in ambient light, using a smartphone-based pupillometer (AI Pupillometer, Solvemed Inc.). Nine subjects underwent 345 measurements in ambient conditions ranging from complete darkness (<5 lx) to bright lighting (≲10,000 lx). Lighting most strongly affected the initial pupil size, constriction amplitude, and velocity. Nonlinear models were fitted to find the correction function that maximally stabilized PLR parameters across different ambient light levels. Next, we demonstrated that the lighting-corrected parameters still discriminated reactive from unreactive pupils. Ten patients underwent PLR testing in an ophthalmology outpatient clinic setting following the administration of tropicamide eye drops, which rendered the pupils unreactive. The parameters corrected for lighting were combined as predictors in a machine learning model to produce a scalar value, the Pupil Reactivity (PuRe) score, which quantifies Pupil Reactivity on a scale 0–5 (0, non-reactive pupil; 0–3, abnormal/“sluggish” response; 3–5, normal/brisk response). The score discriminated unreactive pupils with 100% accuracy and was stable under changes in ambient illumination across four orders of magnitude.

Discussion: This is the first time that a correction method has been proposed to effectively mitigate the confounding influence of ambient light on PLR measurements, which could improve the reliability of pupillometric parameters both in pre-hospital and inpatient care settings. In particular, the PuRe score offers a robust measure of Pupil Reactivity directly applicable to clinical practice. Importantly, the formulae behind the score are openly available for the benefit of the clinical research community.

1 Introduction

The pupillary light reflex (PLR) is mediated by a well-understood neural pathway consisting of the retina, optic nerves, midbrain, brainstem, sympathetic, and parasympathetic nervous systems (13). Consequently, the PLR is sensitive to a wide array of biological and environmental conditions (48), in particular ambient lighting. In order to elicit the PLR response, a single pulse of light is delivered to one eye, leading to pupil constriction (Figures 1A, B). The dynamics of constriction can be characterized by several parameters. These are often measured as the initial pupil size, minimum pupil size, final pupil size, the size difference from initial to the minimum (constriction amplitude), the maximum constriction velocity, peak dilation velocity, the time to begin constriction (latency), and time to re-dilate (recovery time; Figure 1A) (911).

Figure 1
www.frontiersin.org

Figure 1. Establishing invariance to illumination in the pupillary light reflex (PLR). (A) We recorded the PLR using a Smartphone-based pupillometer. (B) The recording yields pupil diameter as a function of time. The curve can be characterized by eight parameters (see Table 1 for descriptions). Shaded rectangle: flash stimulus window. Below: the rate of change of pupil diameter is used to estimate the velocity parameters. (C) Ambient light conditions significantly alter the baseline pupil diameter. This impacts the dynamics of the pupillary response to light (D) Under bright conditions, the response amplitude is attenuated (lower, pale blue lines), which could potentially be confused with an unreactive pupil (dotted line). (E) Top row: ambient light variations, like those occurring throughout the day, can alter pupil parameters even without neurological deterioration, leading to potential misinterpretation. The Pupil Reactivity (PuRe) score is designed to monitor neurological health changes, while remaining stable despite varying light conditions. Bottom row: However, PuRe score should accurately reflect pupillary changes due to neurological health, even under variable lighting.

The PLR is an important marker of neurological decline in patients with conditions such as traumatic brain injury, stroke, infection, tumors, and aneurysms due to raised intracranial pressure (ICP) (8, 1223) Furthermore, the degree of PLR reactivity has recently been shown to hold prognostic value in patients with intracranial hemorrhage and traumatic brain injury (14, 1620). It is therefore crucial for measured pupil parameters to be accurate. Current clinically used methods of assessing pupil size and reactivity do not control for the effects of ambient light, contributing to the lack of confidence in the test results including among trained professionals (24). Achieving inter-examiner reliability in pupil examinations performed with medical pentorches (penlights) proves challenging to practitioners (25), with the measurement reliability affected by varying levels of ambient light among other factors (Figures 1CE). Crucially, infra-red pupillometer devices can exhibit clinically relevant lighting dependence, with significant confounding effects reported previously in critical care patients (5, 6) calling for standardization of measurement conditions, which can be difficult to achieve in hospital settings.

The need for reliable pupil assessment at various stages of clinical care (e.g., pre-hospital care, neuro-monitoring in critical care, etc.) and recent advances in smartphone cameras, have motivated efforts to develop a smartphone-based method to quantify the PLR. In addition, recently there has been a rapid development of neural network-based computer vision models (26, 27) that allow robust extraction of image features with a precision suitable for biomedical imaging, including subtle changes of the pupil size down to micron accuracy. In this context, a computational approach to lighting-invariant PLR measurements is a requirement to measure PLR reliably, across varying ambient light conditions.

In response to these challenges and needs, this study first aimed to establish the relation of each PLR parameter with lighting, and then develop lighting-invariant versions of the parameters, using an FDA-listed smartphone app to measure PLR. To correct for the effect of lighting on each pupil parameter, we used a two-step process. First, we fitted a model to predict the metric based on lighting, in healthy individuals. Second, this prediction was used to subtract away the effect of lighting. This leaves a lighting-corrected metric, that reflects how the metric deviates from what it should be, given the lighting. Second, we aimed to establish that these lighting-invariant parameters remain able to discriminate reactive and unreactive pupils. To this end, we used an anticholinergic agent tropicamide to dilate and render the pupil unreactive. Crucially, we developed the Pupil Reactivity (PuRe) score (PuRe), a scalar composite parameter which is based on the lighting-corrected PLR parameters and quantifies the Pupil Reactivity. Finally, we tested the performance of the lighting-invariant index in an unfavorable environment involving two distinct levels of ambient lighting.

2 Methods

2.1 Laboratory calibration

First, using a smartphone-based pupillometer (AI Pupillometer, Solvemed Inc.) running on an iPhone 13 Pro, we acquired pupillometry data under various precisely controlled illumination conditions (Figure 2A). We tested nine healthy participants (male = 6, female = 3) in a quiet, dimly lit room. Each participant sat comfortably and placed their head on a chinrest, which was positioned 15 cm away from a phone camera mounted on a retort stand. We modulated the illumination in the room using a combination of adjustable LED lamps and dimmable light bulbs. We measured the illuminance using a digital luxometer, attaching its photometric head to the chinrest near the eye to be stimulated.

Figure 2
www.frontiersin.org

Figure 2. Raw pupillograms acquired under different conditions. (A) Design of the lighting study. Each participant was tested under a range of illuminations. (B) Raw inferred pupil size for each recording for the nine participants, shown in the 112 lx condition. The pupil constricts in response to light. The flash time is depicted as a shaded window. (C) Mean traces in the lighting study. Shaded areas indicate the standard error of the mean. As expected, both the baseline pupil size and response amplitude were both smaller under brighter illumination.

We allowed each participant a minimum of 10 min to acclimatize to the respective lighting conditions before initiating the testing. At each illumination, five repeated measurements were taken, at 30 s intervals. We elicited the pupillary light reflex using a light pulse with a duration of 1,000 ms and an illuminance on the face of ~300 lx, generated by the iPhone's LED flash. Video recordings were acquired at 60 Hz, with each recording 5 s long. The recording included 1 s prior to the light stimulus, 1 s during the stimulus, and 3 s post-stimulation.

2.2 Clinical study at an outpatient ophthalmology clinic

In order to ensure lighting correction still enabled the detection of unreactive pupils, we rendered the pupil unreactive by administering tropicamide, an antimuscarinic drug commonly used to dilate pupils before the ophthalmological examination. N = 15 patients (female = 11, male = 4), mean age 55.1 ± 16.61 were recruited from the Oftalmika Eye Hospital. Ethical approval was granted by the Research Bioethics Committee at Nicolaus Copernicus University in Toruń Poland (ref. KB 42712021). All patients provided informed written consent to participate in the study. The study complied with the International Conference on Harmonization Good Clinical Practice (ICH-GCP) guidelines. Patients were excluded if they had previous ocular surgery. The patients had a range of diagnoses from shortsightedness and far-sightedness to age-related cataracts and retinal breaks without detachments.

At the onset of each clinical pupillometry appointment, patients were seated in the clinic room under controlled lighting conditions. The study was performed in the dark, in routine ophthalmology clinic lighting conditions, ranging from 12 to 120 lux. The phone was held by the clinician, and the flash provided a backlight intensity of ~24 lx. The external lighting varied between ~11 and 120 lx as estimated by phone sensors (details below).

We administered a single drop of tropicamide 1% eye drops in each eye as part of the patients' routine clinical care to induce mydriasis. We measured the pupillary light reflex at baseline, several minutes before administering the eye drops, in each eye. Reactivity was re-tested 15 min following administration, again in each eye, to evaluate the changes in Pupil Reactivity to light.

2.3 Validation in an austere environment

During the NEP2NE (Nautical Experiments in Physiology, Technology and Underwater Exploration) scientific mission, three individuals performed various research tasks, one of which was to test whether hyperbaric saturation affected physiology at a depth of 22 feet, over 5 days. Three subjects (female = 1, male = 2; ages 35–55) self-selected to take part in a 120-h scientific aquanautic mission in an underwater dive complex at a depth of 22 feet, and a pressure of 1.6 atm. Employing an AI-based smartphone software-as-medical-device (AI Pupillometer, Solvemed Inc), with no additional hardware, PLR was measured in each eye at 8 timepoints: at pre-exposure to the hyperbaric environment where the illumination was bright, and at seven scheduled intervals during the mission when illumination was dark. Ethical approval was provided by the University of Alberta Research Ethics Board (REB, Ref. Pro00131062).

The code and data used in this paper is publically available at: https://github.com/solvemed/PuRe. As further data are added to the training set, this repository will be updated.

3 Pre-processing

The phone camera captured video with a frame rate of 60 Hz. Each frame was passed through a custom convolutional neural network trained on a large set of manually-annotated images, to determine the absolute pupil size. Following this, we employed a proprietary signal processing pipeline to infer the pupil size over time. The inferred pupil size was then fitted to a canonical pupil response function, operationalized as the sum of two logistic sigmoid functions, with physiological constraints. This yielded parameters for the pupillary response, in accordance with standard quantitative definitions (Table 1).

Table 1
www.frontiersin.org

Table 1. Parameters utilized for quantitatively assessing the dynamics of pupil response to light stimulation with the calculation methodology and their physiological meaning.

3.1 Analysis and statistics

3.1.1 Effect of lighting

To determine whether lighting influences a given pupil parameter, a general linear mixed effects model was used to predict the parameter as a function of external lighting. The illumination was treated categorically to avoid assuming linearity, and a random intercept per subject was included to control for inter-individual differences, yielding the following model:

pupil parameter~categorical(illumination)+(1|subject)

Analysis of variance was then used to test for significance. Linear models were fitted using the STATSMODELS package in Python.

3.1.2 Correction for lighting

Each pupil parameter was then corrected for lighting by first fitting a model to predict the pupil parameter from lighting and baseline pupil size (INIT parameter). This prediction was then used to re-scale the parameter.

Predictors of the pupil parameters included the camera exposure (Exposure, determined by the phone firmware), and the baseline pupil size (Baseline). Baseline pupil size is physiologically determined, but in healthy people does accurately track ambient lighting. Correction curves were fitted for each of the parameters in Table 1, except for INIT which was used as a predictor. Each parameter was predicted by regression against linear and nonlinear terms of baseline pupil size and Exposure. The nonlinear terms were X−1, X2, X2, logX, logX2 where X can be Baseline or Exposure, as well as interactions Baseline × Exposure and log(Baseline) × log(Exposure). We used stepwise regression to optimize the Bayes information criterion (BIC) for each parameter. The top 250 models for each parameter were then fine-tuned using LASSO regularization (α = 0.006) yielding one winning model for each parameter.

We reasoned that a “corrected parameter value” should be proportional to the measured value, but be scaled in such a way that the value is the same across the range of lighting conditions. In order to perform this type of correction, we obtained a predicted value of the parameter for the given lighting, using the best fitting-model determined above. The corrected values were then computed as the deviation of the measurement from its lighting-predicted value, added to the parameter's average value. For this, we used the mean values across all lighting conditions.

corrected=average+measured-predicted

The motivation behind this formula is as follows. A person who has an exactly average pupil response (in this case, the average of the participants in this study), will have metrics equal to the predicted values. The formula will then yield the population average, plus zero. When the lighting changes, the prediction and metric will change in tandem, giving the same result irrespective of lighting. A person with different pupillary metrics (e.g., slower, faster, smaller in amplitude) will deviate from the prediction by a given amount. The formula assumes that this will be present at all given lighting levels, and yields the population average plus or minus this deviation. This produces a lighting-invariant index that remains sensitive to deviations of a person's pupil responses from the normative value.

The methods used for computing the lighting-invariant index are general enough to be used on any model of phone. The specific coefficients presented in the results were all collected on a single model, and therefore apply to the iPhone 13 only.

4 Results

4.1 Lighting influences all pupillometric parameters

First, we aimed to determine, under laboratory conditions, how PLR parameters were affected by varying the ambient illumination. The pupillograms, i.e., inferred pupil size over time time, obtained under 112 lx illumination are shown in Figure 2B. Mean pupillograms differed greatly according to lighting, as predicted (Figure 2C for three example lighting conditions: 5 lx, 112 lx, and 1,343 lx). The eight parameters were calculated for each pupillogram. To quantify the dependence of each pupil parameter on lighting, the mean and the standard error of the parameter value across participants were computed (Figures 3AH).

Figure 3
www.frontiersin.org

Figure 3. Impact of lighting on pupillometric parameters (A–H). The figures show the significant influence of lighting conditions on all evaluated pupillometric parameters. Each subject is in a different color, with the line denoting the mean. (A) Baseline pupil diameter (INIT), (B) Constriction amplitude (CAMP), (C) Final asymptotic pupil size (FIN), (D) Constriction amplitude (CAMP), (E) Maximum constriction velocity (MCV), (F) Peak dilation velocity (PDV), (G) Latency (LAT), and (H) Recovery time (T75).

Each parameter was strongly determined by lighting (general linear mixed effects model of pupil parameter vs. external lighting with a per-subject random intercept and slope, all p < 0.05, all F(7, 338)>4.45, Table 2). The most strongly affected parameters were baseline (INIT), constriction amplitude (CAMP), and maximum constriction velocity (MCV; all F>190). Specifically, brighter illumination decreased initial size, reduced constriction amplitude and slowed the maximum constriction velocity.

Table 2
www.frontiersin.org

Table 2. Best model to explain the lighting-dependence of each of the standard PLR parameters.

4.2 Correction of each PLR parameter for lighting

Next, we sought to compute a “lighting-corrected” form of each PLR parameter. To do this, we examined the predictors of each parameter across lighting conditions (Figure 4A), which were used to compute corrected versions of each parameter (Figure 4B). Uncorrected and corrected values across the range of lighting were compared (Figure 4C). In each case, the predicted values were computed using leave-one-out cross-validation, so the model had not seen the data that was being corrected. The winning models are shown in Table 2. To measure how well the correction works, we tested whether the parameter (before and after correction) varied with the lighting level. This yielded an F statistic for the uncorrected and corrected parameter. The light-dependence was reduced for each of the parameters.

Figure 4
www.frontiersin.org

Figure 4. Lighting-corrected parameters. (A) To predict how each parameter varies with lighting, hardware exposure measurements and the baseline pupil size are used as inputs to the model. The correction aims to make each measure lighting-invariant. (B) Each of the seven parameters is corrected using the trained models. The optimal model for each parameter is given in Table 2. (C) Each raw parameter was strongly dependent on illumination (blue). The lighting-corrected parameters (red) each showed a flatter dependence on illumination.

4.3 Corrected PLR parameters remain able to detect unreactive pupils

It is possible that by enforcing a parameter to be insensitive to lighting, it may become insensitive to other important measures including pathology. We therefore asked how each of the corrected parameters fared at detecting unreactive pupils. This was tested by measuring PLR before and after tropicamide eye drops (Figures 5A, B). The demographics of the patients are in Table 3.

Figure 5
www.frontiersin.org

Figure 5. Effect of correction on PLR parameters under the effects of the mydriatic agent tropicamide. (A) Study design: particpants were tested before and 15 min after tropicamide instillation. (B) Pupillary response to light after applying tropicamide drops, which leads to a fixed dilated pupil, giving an “artificial lesion.” (C) Raw values of parameters showed differences between pre- and post-tropicamide recordings but also showed considerable variability. (D) After lighting-correction, most parameters continued to discriminate strongly between pre- and post-tropicamide recordings. (E) Area under curve for distinguishing between pre-tropicamide and post-tropicamide, calculated separately for uncorrected and lighting-corrected parameters. Discrimination improved numerically for all parameters except for final pupil size (FIN).

Table 3
www.frontiersin.org

Table 3. Demographics of participants in the tropicamide study.

We compared the constriction parameters (END, FIN, CAMP, MCV, PDV, LAT, and T75) before vs. 15 min after administration of tropicamide eye drops. The most accurate parameter for distinguishing drug condition was CAMP (Figure 5C). After correction for lighting, several parameters distinguished clearly between pre- and post-tropicamide (Figure 5D). Notably, the corrected CAMP parameter was 100% accurate with a wide margin of separation. As expected, the final pupil size did not discriminate well between tropicamide conditions, as it is highly correlated with the baseline pupil size and therefore becomes relatively invariant. A receiver operating characteristic was computed for each parameter, to distinguish pre vs. post-tropicamide, using a kernel density estimate. The area under the curve for several parameters (END, CAMP, PDV, LAT, and T75) was numerically greater after correction, compared to before correction (Figure 5E).

4.4 Optimizing discrimination of unreactive pupils using a score that combines corrected pupil parameters

Although individual corrected parameters already provide a strong separation of tropicamide from control, including multiple parameters to create a single Pupil Reactivity (PuRe) score (Figure 6A) enables the detection of more subtle changes including slowing of the PLR, changes in amplitude, and the ability to re-dilate. Therefore we estimated the optimal hyperplane to separate the reactive and unreactive pupils using regularized multi-variable logistic regression. We included the seven corrected parameters, and their powers of 2 and -1, and their first order products. LASSO regularization was applied using a coefficient of α = 0.006, and included a penalty in the regression for light-dependence to maintain light invariance.

Figure 6
www.frontiersin.org

Figure 6. Lighting-invariant index of Pupil Reactivity. (A) To calculate a score, pupil diameter D(t) was recorded and uncorrected parameters were extracted. Exposure and INIT were used to compute lighting-invariant parameters (see Section 4.2). The parameters were combined to optimize discrimination between the pre- and post- tropicamide recordings, resulting in the Pupil Reactivity (PuRe) score PuRe. (B) the score was scaled to lie in the range 0–5, based on the distribution of normative values. A value of 3.0 corresponds to the midpoint between reactive and unreactive pupils. (C) The Pupil Reactivity (PuRe) score PuRe is plotted in the lighting study. Bars are shown as a function of varying ambient illumination, demonstrating relative invariance to lighting. (D) To demonstrate that the score still distinguishes well between reactive and non-reactive pupils, the score (PuRe) is shown before tropicamide drops, and 15 min after. the score maintained a good separation of the two conditions. (E) In the NEP2NE study, three healthy subjects were tested on the surface and after diving into an underwater habitat. (F) Lighting was significantly brighter at the surface compared to depth conditions. (G) The Pupil Reactivity (PuRe) score was unaffected by the conditions.

The logistic regression yielded coefficients which provide a score of reactivity with a formula (three decimal places):

PuRe=0.007×INIT-2.438×ENDc+2.773×FINc+0.838                                   ×MCVc+1.239×PDVc+2.604×CAMPc

In order to correspond to commonly used clinical scales, we scaled our PuRe score using a piecewise function to the range 0–5 (0, non-reactive pupil; 0–3, abnormal/“sluggish” response; 3–5, normal/brisk response, Figure 6B). The line segments making up the function are calculated to map specific parts of the distribution of scores onto specific points on the final scale. The function maps median(post)−3 × stdev(post) → −0.5, median(post)−stdev(post) → 0.2, median(post) → 0.8, median(post)+stdev(post) → 1.0, 0 → 3, median(pre)−3 × stdev(pre) → 4.0, median(pre) → 4.5 and where median, stdevdenotes median and standard deviation of values of PuRe obtained before mapping, before tropicamide administration (pre) and after tropicamide administration (post). The score was relatively invariant to light (Figure 6C) while distinguishing between reactive and unreactive pupils (Figure 6D).

4.5 Validating the lighting-invariance of the reactivity score during the NEP2NE underwater study

Finally, we aimed to test the lighting-invariance of the reactivity score in an environment less favorable than the lab or clinic. The AI Pupillometer app was deployed in a hyperbaric underwater lagoon, and tests were performed at the surface and at depth (Figure 6E). The illumination measured by the sensors was over six times brighter at the surface, 790 ± 570lx(mean ± SD), than at depth, 128 ± 83lx (linear mixed effects model with the environment as predictor, and subject as group variable, random intercept, t(environment) = 57.5, P>|t| <0.001) (Figure 6F). There was no difference in the reactivity index (PuRe) comparing surface vs. depth [t(environment) = 2.93] (Figure 6G)

5 Discussion

Despite its crucial role in emergency and critical care, the pupillary light reflex (PLR) is highly dependent on background illumination. We quantify and fit the relationship between each PLR parameter and illumination, allowing us to develop lighting-invariant versions of each parameter. Crucially, we demonstrated that they retain sensitivity to discriminate key pathological features of an unreactive pupil. We then combined these lighting-invariant parameters to produce a single reactivity index (PuRe) that optimally discriminated unreactive pupils. Since the score is based on these corrected parameters, it is tuned to be stable under a wide range of lighting conditions. The lighting-invariant parameters described here are a step toward increasing the reliability and accessibility of PLR measures. This is especially important as conventional infra-red pupillometer devices struggle with varying ambient light (REF Ong, C. 2019), which can lead to inaccurate readings and sub-optimal clinical decision-making.

Quantitative pupillometry plays an increasingly important in critically ill patients, both for the evaluation of neurological status (7, 12, 13), monitoring (12, 13), and prognostication (12, 13, 17). These especially include patients affected by acute brain injuries (14, 17), where there is a need to detect deterioration of neurological state. Quantitative pupil dynamics have also gathered interest in recent years in neurology (28), neurosurgery (14, 16), anesthesiology (29), and emergency medicine (30). Objective and accurate pupil size and reactivity testing have been shown to be clinically valuable, reducing assessment errors and the examiner's uncertainty, and aiding nurses and clinicians in improved clinical decision-making compared to when a subjective visual assessment of pupils is performed (24, 25).

Even when measured with infra-red pupillometer devices, PLR parameters can vary with lighting. In one study of critically ill patients, Pupil Reactivity differed significantly under different lighting conditions (5). Standardizing lighting conditions is therefore necessary to maximize measurement reliability, but during routine clinical care, this is extremely challenging, for many practical reasons. Using opaque eye-cups (rubber cups) to block ambient light during the measurement has been suggested as a possible solution (6), however, this is not possible with most pupillometer devices. Further, it may not fully alleviate ambient light effects in conscious patients due to the consensual pupillary response and adds costs. Thus, robust lighting-correction methods are needed to allow for accurate and clinically meaningful Pupil Reactivity tracking in patients.

Naively, one might think that the change in pupil size, as a proportion of the baseline size, might correct for background effects, but this is not the case (31, 32). In our data, the lighting dependence of various parameters was nonlinear, and optimal correction differed according to the parameter. Furthermore, the optimal axis for discriminating reactivity required a non-intuitive combination of parameters, though constriction amplitude was the most dominant, as expected.

The final underwater study demonstrated invariance not only to illumination, but also to hyperbaric conditions. While the effects of hypobaric conditions on brain function are well–established (33), such as those at high altitudes with diminished PiCO2 levels, the effects of hyperbaric pressures remain poorly understood. Saturation diving complexes offer several challenges, owing to their isolation, confinement, and location in hyperbaric environments. Even after several days at depth, at 1.6 atm, we found no effects of pressure on the pupillary reactivity index after correcting for lighting. The findings underscore the stability of PLR under different lighting situations and in a hyperbaric environment. Moreover, we observed that smartphone-based pupillometry was easy to deploy in the austere environment owing to its lightweight, portable form factor. This last study was opportunistic. While the results showcase the robust mobile platform capable of remote operation with local processing, further tests in a real intensive care setting are needed.

While the numerical results presented were calculated using only one model of the phone, the same calibration can be applied to data from other models. Since different phones have different cameras with different resolutions, sensitivities, and exposure relationships, calibrating individual phones is likely to be essential to producing reproducible results. The methods proposed in this paper provide a framework for how this should be done.

We argue that lighting-invariant quantitative pupillometry could herald a new area for pupillometry. First, lighting-corrected parameters may be more clinically useful compared to their raw counterparts, since they are more robust to environmental conditions and may offer more sensitive discrimination between reactive vs. “sluggish“ vs. unreactive pupils. Lighting-corrected parameters are also likely to improve the quality of Pupil Reactivity trends, crucial for detecting neurological deterioration, for example in critical care settings. Presently, gradual changes in ambient light (for example as a consequence of typical changes in sunlight over a diurnal cycle) can induce false trends in Pupil Reactivity and lead to sub-optimal clinical decisions. Second, it allows reliable pupil assessment across the spectrum of care. Much of the data in this study was collected from patients by clinicians in a clinical setting. Adopting the lighting-corrected open-sourced Pupil Reactivity (PuRe) score could be an important step toward the standardization of pupil testing across different healthcare professionals and research groups. Since it can be performed using a standard smartphone app with no additional hardware, quantitative pupillometry opens new opportunities to measure neurological vital signs, that have historically required a healthcare professional. For example, with the ability to perform rapid quantitative pupil assessment reliably in a variety of environments, emergency medicine technicians may be able to better triage brain injury patients at the scene of accidents and neuro-monitor the patients during transport, with the potential for improved decision-making, greater cost-effectiveness, and improved outcomes. In addition, measurements captured with a smartphone can be shared flexibly across clinical teams providing intensive care and surgical teams, providing richer baseline data and thus facilitating clinical assessment, prognostication, and decision-making.

Finally, the Pupil Reactivity (PuRe) score, presented here for the first time, represents the first-ever lighting-corrected score quantifying Pupil Reactivity. The score is directly applicable to clinical practice allowing for reliable and convenient assessment and tracking of Pupil Reactivity, necessary for evaluation and monitoring of patient's neurological status. Importantly, the formula behind the score was presented here openly for the benefit of the clinical research community.

Data availability statement

The subject-level datapoints supporting the conclusions of this article will be made available by the authors upon reasonable request.

Ethics statement

The studies involving humans were approved by Research Bioethics Committee at Nicolaus Copernicus University in Toruń, Poland (ref. KB 42712021) and University of Alberta Research Ethics Board (REB, Ref. Pro00131062). The studies were conducted in accordance with the local legislation and institutional requirements. The participants provided their written informed consent to participate in this study.

Author contributions

AB: Conceptualization, Formal analysis, Investigation, Software, Visualization, Writing – original draft, Writing – review & editing. IJ: Data curation, Software, Validation, Writing – original draft, Writing – review & editing. ŁZ: Writing – original draft, Writing – review & editing. MJ: Writing – original draft, Writing – review & editing. DJ: Writing – original draft, Writing – review & editing. KS: Writing – original draft, Writing – review & editing. HC: Writing – original draft, Writing – review & editing. MW: Writing – original draft, Writing – review & editing. JK: Writing – original draft, Writing – review & editing. DC: Writing – original draft, Writing – review & editing. PB: Writing – original draft, Writing – review & editing. SP: Writing – original draft, Writing – review & editing. RC: Writing – original draft, Writing – review & editing. SM: Writing – original draft, Writing – review & editing.

Funding

The author(s) declare financial support was received for the research, authorship, and/or publication of this article.

Conflict of interest

AB, IJ, ŁZ, MJ, HC, MW, RC, and SM either are employees or receive consultancy fees, and/or hold equity rights at Solvemed. HC and MW are directors at Solvemed. Pupillometer mobile app (AI Pupillometer) used for data collection was created by the Solvemed.

The remaining authors declare that the research was conducted in the absence of any commercial or financial relationships that could be construed as a potential conflict of interest.

The authors declare that this study received funding from Solvemed. The funder had the following involvement in the study: funding a part of the research team. Specifically, AB, IJ, ŁZ, MJ, HC, MW, RC, and SM either are employees or receive consultancy fees, and/or hold equity rights at Solvemed, and their work was funded by the company. Other authors received no financial support from the company for the research, authorship, and/or publication of this article.

Publisher's note

All claims expressed in this article are solely those of the authors and do not necessarily represent those of their affiliated organizations, or those of the publisher, the editors and the reviewers. Any product that may be evaluated in this article, or claim that may be made by its manufacturer, is not guaranteed or endorsed by the publisher.

References

1. Kardon R. Pupillary light reflex. Curr Opin Ophthalmol. (1995) 6:20–6.

Google Scholar

2. Ellis CJ. The pupillary light reflex in normal subjects. Br J Ophthalmol. (1981) 65:754–9.

PubMed Abstract | Google Scholar

3. Meeker M, Du R, Bacchetti P, Privitera CM, Larson MD, Holland MC, et al. Pupil examination: validity and clinical utility of an automated pupillometer. J Neurosci Nurs. (2005) 37:34. doi: 10.1097/01376517-200502000-00006

PubMed Abstract | Crossref Full Text | Google Scholar

4. Sharma S, Baskaran M, Rukmini AV, Nongpiur ME, Htoon H, Cheng CY, et al. Factors influencing the pupillary light reflex in healthy individuals. Graefe's Archiv Clin Exp Ophthalmol. (2016) 254:1353–9. doi: 10.1007/s00417-016-3311-4

PubMed Abstract | Crossref Full Text | Google Scholar

5. Ong C, Hutch M, Smirnakis S. The effect of ambient light conditions on quantitative pupillometry. Neurocrit Care. (2019) 30:316–21. doi: 10.1007/s12028-018-0607-8

PubMed Abstract | Crossref Full Text | Google Scholar

6. Couret D, Simeone P, Freppel S, Velly L. The effect of ambient-light conditions on quantitative pupillometry: a history of rubber cup. Neurocrit Care. (2019) 30:492–3. doi: 10.1007/s12028-018-0664-z

PubMed Abstract | Crossref Full Text | Google Scholar

7. Greer DM, Shemie SD, Lewis A, Torrance S, Varelas P, Goldenberg FD, et al. Determination of brain death/death by neurologic criteria: the world brain death project. J Am Med Assoc. (2020) 324:1078–97. doi: 10.1001/jama.2020.11586

PubMed Abstract | Crossref Full Text | Google Scholar

8. Couret D, Boumaza D, Grisotto C, Triglia T, Pellegrini L, Ocquidant P, et al. Reliability of standard pupillometry practice in neurocritical care: an observational, double-blinded study. Crit Care. (2016) 20:99. doi: 10.1186/s13054-016-1239-z

PubMed Abstract | Crossref Full Text | Google Scholar

9. Aderman MJ, Meister MR, Roach MH, Dengler BA, Ross JD, Malvasi SR, et al. Normative values for pupillary light reflex metrics among healthy service academy cadets. Milit Med. (2023) 2023:usad271. doi: 10.1093/milmed/usad271

PubMed Abstract | Crossref Full Text | Google Scholar

10. Shah SS, Ranaivo HR, Mets-Halgrimson RB, Rychlik K, Kurup SP. Establishing a normative database for quantitative pupillometry in the pediatric population. BMC Ophthalmol. (2020) 20:121. doi: 10.1186/s12886-020-01389-x

PubMed Abstract | Crossref Full Text | Google Scholar

11. Lussier BL, Stutzman SE, Atem F, Venkatachalam AM, Perera AC, Barnes A, et al. Distributions and reference ranges for automated pupillometer values in neurocritical care patients. J Neurosci Nurs. (2019) 51:335–40. doi: 10.1097/JNN.0000000000000478

PubMed Abstract | Crossref Full Text | Google Scholar

12. Phillips SS, Mueller CM, Nogueira RG, Khalifa YM. A systematic review assessing the current state of automated pupillometry in the NeuroICU. Neurocrit Care. (2019) 31:142–61. doi: 10.1007/s12028-018-0645-2

PubMed Abstract | Crossref Full Text | Google Scholar

13. Kim TJ. Quantitative assessments of pupillary light reflexes in neurocritically ill patients. J Neurocrit Care. (2022) 15:79–87. doi: 10.18700/jnc.220085

Crossref Full Text | Google Scholar

14. Boulter JH, Shields MM, Meister MR, Murtha G, Curry BP, Dengler BA. The expanding role of quantitative pupillometry in the evaluation and management of traumatic brain injury. Front Neurol. (2021) 12:685313. doi: 10.3389/fneur.2021.685313

PubMed Abstract | Crossref Full Text | Google Scholar

15. Bower MM, Sweidan AJ, Xu JC, Stern-Nezer S, Yu W, Groysman LI. Quantitative pupillometry in the intensive care unit. J Intens Care Med. (2021) 36:383–91. doi: 10.1177/0885066619881124

Crossref Full Text | Google Scholar

16. Chen J, Gombart Z, Rogers S, Gardiner S, Cecil S, Bullock R. Pupillary reactivity as an early indicator of increased intracranial pressure: the introduction of the neurological pupil index. Surg Neurol Int. (2011) 2:82. doi: 10.4103/2152-7806.82248

PubMed Abstract | Crossref Full Text | Google Scholar

17. Ong CJ. Quantitative pupillometry: not a clear predictor of delayed cerebral ischemia after subarachnoid hemorrhage. Neurocritical Care. (2023) 39:34–5. doi: 10.1007/s12028-023-01709-1

Crossref Full Text | Google Scholar

18. Prescott BR, Saglam H, Duskin JA, Miller MI, Thakur AS, Gholap EA, et al. Anisocoria and poor pupil reactivity by quantitative pupillometry in patients with intracranial pathology. Crit Care Med. (2022) 50:e143–53. doi: 10.1097/CCM.0000000000005272

PubMed Abstract | Crossref Full Text | Google Scholar

19. Olson DM, Fishel M. The use of automated pupillometry in critical care. Crit Care Nurs Clin N Am. (2016) 28:101–7. doi: 10.1016/j.cnc.2015.09.003

PubMed Abstract | Crossref Full Text | Google Scholar

20. Ong CJ. The prognostic potential of pupillometry in patients with acute brain injury. Lancet Neurol. (2023) 22:876–8. doi: 10.1016/S1474-4422(23)00314-9

PubMed Abstract | Crossref Full Text | Google Scholar

21. Zafar SF, Suarez JI. Automated pupillometer for monitoring the critically ill patient: a critical appraisal. J Crit Care. (2014) 29:599–603. doi: 10.1016/j.jcrc.2014.01.012

PubMed Abstract | Crossref Full Text | Google Scholar

22. Leinonen V, Vanninen R, Rauramaa T. Raised intracranial pressure and brain edema. Handb Clin Neurol. (2018) 145:25–37. doi: 10.1016/B978-0-12-802395-2.00004-3

PubMed Abstract | Crossref Full Text | Google Scholar

23. Changa AR, Czeisler BM, Lord AS. Management of elevated intracranial pressure: a review. Current Neurol Neurosci Rep. (2019) 19:99. doi: 10.1007/s11910-019-1010-3

Crossref Full Text | Google Scholar

24. Olson DM, Stutzman S, Saju C, Wilson M, Zhao W, Aiyagari V. Interrater reliability of pupillary assessments. Neurocrit Care. (2016) 24:251–7. doi: 10.1007/s12028-015-0182-1

PubMed Abstract | Crossref Full Text | Google Scholar

25. Omburo L, Stutzman S, Supnet C, Choate M, Olson DM. High variance in pupillary examination findings among postanesthesia care unit nurses. J PeriAnesth Nurs. (2017) 32:219–24. doi: 10.1016/j.jopan.2015.05.117

PubMed Abstract | Crossref Full Text | Google Scholar

26. Krizhevsky A, Sutskever I, Hinton GE. ImageNet classification with deep convolutional neural networks. Commun ACM. (2017) 60:84–90. doi: 10.1145/3065386

Crossref Full Text | Google Scholar

27. Dosovitskiy A, Beyer L, Kolesnikov A, Weissenborn D, Zhai X, Unterthiner T, et al. An image is worth 16x16 words: transformers for image recognition at scale. arXiv.2010.11929 (2021). doi: 10.48550/arXiv.2010.11929

Crossref Full Text | Google Scholar

28. Chougule PS, Najjar RP, Finkelstein MT, Kandiah N, Milea D. Light-induced pupillary responses in Alzheimer's disease. Front Neurol. (2019) 10:360. doi: 10.3389/fneur.2019.00360

PubMed Abstract | Crossref Full Text | Google Scholar

29. Packiasabapathy S, Rangasamy V, Sadhasivam S. Pupillometry in perioperative medicine: a narrative review. Can J Anesth. (2021) 68:566–78. doi: 10.1007/s12630-020-01905-z

Crossref Full Text | Google Scholar

30. Alexis M, Fernández-Penny F, Abella B. Assessment of altered mental status in the emergency department using quantitative pupillometry: a prospective cohort study (P7-4.006). Neurology. (2023) 100(17Suppl.2):4697. doi: 10.1212/WNL.0000000000204165

Crossref Full Text | Google Scholar

31. Fink L, Simola J. From pre-processing to advanced dynamic modeling of pupil data. Behav Res Methods. (2023) 23:2098. doi: 10.3758/s13428-023-02098-1

PubMed Abstract | Crossref Full Text | Google Scholar

32. Reilly J, Kelly A. The human task-evoked pupillary response function is linear: Implications for baseline response scaling in pupillometry. Behav Res Methods. (2023) 59:865–78. doi: 10.3758/s13428-018-1134-4

PubMed Abstract | Crossref Full Text | Google Scholar

33. Sherman P, Sladky J. Acute and chronic effects of hypobaric exposure upon the brain. In:Russomano T, Rehnberg L, , editors. Into Space—A Journey of How Humans Adapt and Live in Microgravity. InTech (2018). doi: 10.5772/intechopen.74231

Crossref Full Text | Google Scholar

Keywords: pupillary light reflex (PLR), Pupil Reactivity, Pupil Reactivity (PuRe) score, neurocritical care, pupillometry, critical care, intensive care unit, Artificial Intelligence (AI)

Citation: Bogucki A, John I, Zinkiewicz Ł, Jachura M, Jaworski D, Suwała K, Chrost H, Wlodarski M, Kałużny J, Campbell D, Bakken P, Pandya S, Chrapkiewicz R and Manohar SG (2024) Machine learning approach for ambient-light-corrected parameters and the Pupil Reactivity (PuRe) score in smartphone-based pupillometry. Front. Neurol. 15:1363190. doi: 10.3389/fneur.2024.1363190

Received: 30 December 2023; Accepted: 18 March 2024;
Published: 09 April 2024.

Edited by:

Kemar E. Green, Johns Hopkins University, United States

Reviewed by:

Roger Soberanis Mukul, Johns Hopkins University, United States
Diego Kaski, University College London, United Kingdom

Copyright © 2024 Bogucki, John, Zinkiewicz, Jachura, Jaworski, Suwała, Chrost, Wlodarski, Kałużny, Campbell, Bakken, Pandya, Chrapkiewicz and Manohar. This is an open-access article distributed under the terms of the Creative Commons Attribution License (CC BY). The use, distribution or reproduction in other forums is permitted, provided the original author(s) and the copyright owner(s) are credited and that the original publication in this journal is cited, in accordance with accepted academic practice. No use, distribution or reproduction is permitted which does not comply with these terms.

*Correspondence: Ivo A. John, ivo@solvemed.ai; Sanjay G. Manohar, sanjay.manohar@solvemed.ai; Michal Wlodarski, michal.wlodarski@solvemed.ai

These authors have contributed equally to this work

Disclaimer: All claims expressed in this article are solely those of the authors and do not necessarily represent those of their affiliated organizations, or those of the publisher, the editors and the reviewers. Any product that may be evaluated in this article or claim that may be made by its manufacturer is not guaranteed or endorsed by the publisher.