Abstract
White blood cells (WBCs), also known as leukocytes, are one of the most significant parts of the immune system. They generate antibodies, protect the body from illnesses, and heal wounds. Accurate estimation of WBCs is key for diagnosing cancer, infections, leukemia, lymphoma, and other diseases. However, the widely used Complete Blood Count (CBC) test presents challenges, including prick anxiety, discomfort, and logistical inconvenience to patients. This study introduces a ubiquous White Blood Cell counting system, UbiWhite, a novel smartphone-based, non-invasive system for real-time WBC counting from fingertip videos. Our system uses optical and magnetic techniques to provide accurate WBC counts without blood extraction. An initial experimentation was carried out on 20 adult participants to verify the system’s effectiveness compared to standard CBC tests (IRB #4051). The developed algorithms exhibit 1.04 and 1.23 RMSE, respectively. Our innovation provides an easy, affordable, and instantaneous solution for monitoring WBCs in various healthcare settings, including homes and critical care units. Additionally, it serves as a beacon of hope for low- and middle-income nations, where access to and affordability of traditional lab tests are limited.
Similar content being viewed by others
Introduction
White blood cell (WBC) detection and counting are crucial in early-detecting diseases such as leukemia and lymphoma1. Infections and swelling trigger the body’s immune response, causing an increase in WBC production to combat the invading pathogens. White blood cells are produced in the bone marrow, and cancer can infiltrate it or disrupt its regular physiological processes. This research article introduces a smartphone-based system for real-time WBC counting. The pilot study data collection protocol was approved by the Marquette University Institutional Review Board (IRB). All methods were carried out in accordance with relevant guidelines and regulations for human subject data collection. This system utilizes optical and magnetic techniques to accurately count WBCs from fingertip videos, eliminating the need for invasive blood collection. The OptoMagnetic computational method overcomes challenges posed by hemoglobin in red blood cells, enhancing the contrast between red blood cells and flow gaps2,3,4 by approximating WBCs as outliers in the flowing blood. Outlier detection is a well-established mathematical, model-based task that relies on computational methods to group similar data points while separating dissimilar data points. This study compares two algorithms, A-1 and A-2, revealing varying performance metrics. While A-2 achieved higher accuracy in average error, it displayed a larger mean absolute error (MAE) and root mean squared error (RMSE), indicating significant deviations from actual values. Statistical analysis confirmed no significant difference between the predictions of either algorithm and the actual values5. These findings underscore the efficacy of both algorithms in predicting the target variable. Moreover, this study emphasizes the potential of mHealth applications in providing convenient, cost-effective, and real-time solutions for WBC monitoring, especially beneficial for resource-constrained settings. Our system aims to alleviate the distress of a substantial segment of the population that suffers from needle anxiety6,7. This research introduces a novel approach to leveraging mobile computing and sensor technology for healthcare, focusing on a needle-free method for white blood cell counting. By integrating computational science and biomedical engineering, this study aims to develop innovative solutions for the aforementioned healthcare issues.
Related works
Firstly, we discuss the optical properties of WBCs by reviewing relevant literature.
Red Blood Cells (RBCs) dominate the optical properties of flowing blood because they are highly concentrated, and their light absorption and scattering are significantly higher, by two to three orders of magnitude, compared to other blood components8. RBCs thus impose significant challenges for WBC detection and counting tasks. The effects of the optical properties of WBCs and Platelets (PLTs) on light scattering and absorption by whole blood are considered negligible9,10.
Light scattering-based systems designed to characterize the backscattering of leukemic and normal WBC and RBC were proposed by Yim et al.11. These systems provide the basis for designing in vitro microfluidic‐based and potentially in vivo light scattering flow cytometry devices.
Greiner et al. reported on the design and performance of a confocal laser-based system built to collect backscattered light over a range of 26° at 405, 488, and 633 nm to discriminate leukemic cells from normal RBC and WBC12. There are notable differences in leukemic cells’ intensity and wavelength dependence compared to RBC and WBC. Specifically, the unique light scattering properties of RBCs, attributed to hemoglobin absorption, enable their differentiation from leukemic cells, mononuclear, and polymorphonuclear WBCs, especially at specific wavelengths.
Secondly, we analyze the spectroscopic, light scattering, microscopic, and pulse oximetric techniques for non-invasive total WBC count that several researchers have employed.
Winkelman et al. used non-invasive UV spectroscopy to image nucleic acids and detect WBCs13. They conducted reflectance spectroscopy experiments utilizing a UV light source and a UV receiver. The WBC count was calculated by analyzing the ratio of WBCs to RBCs across a sufficient number of images and multiplying it by the calculated RBC count.
Huo et al. have performed non-invasive detection of the content of white blood cells in the blood of humans based on a dynamic spectrum14. Based on spectral technology, they have built a model on the transmittance spectroscopic data of 332 subjects to predict leukocyte concentration. For validation, they compared the experimental values against the blood component values obtained from venous blood samples.
MIT researchers developed a non-invasive device to detect severe neutropenia, a condition marked by low neutrophil levels, in chemotherapy patients2,15. They analyzed 22 microcirculatory video footage of nail fold capillaries collected from 11 patients using their device. Subsequently, they identified a correlation between moving optical absorption gaps and WBC movement.
The Leuko project combined pulse oximetry and flow cytometry to non-invasively count white blood cells16. By focusing LED light on capillaries, researchers created a snapshot where RBCs appeared as bright red spots and WBCs as negative space. This allowed for the counting of WBCs based on the image analysis.
Bourquard et al. developed a semi-automated method to count WBCs in nail fold capillaries using low-cost microscopy17. By analyzing video data, their algorithm identifies visual gaps in blood flow as WBCs pass through, providing both WBC count and speed. The method’s accuracy was validated on data from a single healthy subject.
Bagramyan et al. presented a miniature microscope to image blood cells in the oral mucosa in real time without labels18. This device uses oblique back-illumination to visualize individual WBCs circulating in the bloodstream. The high-speed imaging capability suggests the potential for non-invasive WBC counting by identifying and categorizing individual cells using machine learning algorithms.
Thirdly, we explore the studies conducted focused on the interaction of magnets and magnetic fields with flowing blood. Mustafa et al. conducted experimental work to monitor the static magnetic field effect on WBCs19. Their study mentions that the external magnetic field affects the flowing blood by rotating the RBCs, aligning it in a specific direction, enhancing its aggregation, and changing the counts nonlinearly20. Abdallah et al. studied the effects of static magnetic field exposure on blood flow21. Mishra et al. developed a numerical model representing the effect of a magnetic field on blood flow through an artery22. Jo et al. simulated a simple capillary blood cell flow monitoring system using a magnetic micro-sensor23.
Innovation
We have curated a point-of-care White Blood Cell (WBC) system from fingertip videos captured with a smartphone. The hemoglobin in Red Blood Cells (RBC) poses a challenge as it contributes to blood being magnetic or magnetizable material8,10. Subsequently, hemoglobin directly influences blood absorption and scattering properties. To overcome this, we have mounted a blue light bandpass filter of 430 nm over the smartphone flashlight to maximize the contrast between the red blood cells and flow gaps as opposed to having external microscopy equipment as used by Bourquard et al.17. Furthermore, we have placed a magnetic field near the smartphone’s magnetometer to repulse the negative charge from hemoglobin and consequently regulate the flow of the dominant RBC in a specific direction19,20. The blue light bandpass filter and magnetic field placement were optimized through iterative testing to maximize the contrast between RBCs and flow gaps while ensuring consistent RBC directionality, as mentioned in the literature to overcome the need for external stabilizers as utilized by Bagramyan et al.18.
Finally, we employed the light scattering and absorption properties of leukocytes to count the number of WBC passing through the finger, contrary to detecting only severely low levels WBC counts as demonstrated by Bourquard et al.2. Specifically, we employed the rear camera of the phone as the light receptor and flash LED as a light emitter24,25 to eliminate the reliance on expensive spectrometers as operated by Huo et al.14.
Comparative analysis
An overview of different studies on WBC measurement techniques, highlighting their methodologies, such as using optical fibers, microscopy, and non-invasive methods, along with their performance metrics are given in Table 1.
Method
Our methodology has been modularized into a series of discrete steps, as illustrated in Fig. 1, which outlines the precise sequence of critical actions for successful white blood cell count estimation.
Data collection
The Institutional Review Board (IRB) at Marquette University authorized the data collection protocol for this pilot study. We collected index fingertip videos from a cohort of 20 adult volunteers (13 males, 7 females) to measure white blood cell counts and levels. All experimental procedures adhered to applicable guidelines and regulations for human subject research. Since all the volunteers were adults, they provided informed consent before participating in data collection. We obtained the gold standard white blood cell count values for the volunteers who underwent CBC tests from four different pathological providers. In terms of eligibility, volunteers aged 18 and above were required to have fingertips without any nail polish. For each subject, we recorded a single 60-second video of the fingertip. Consequently, each patient underwent only one trial. If the recorded video failed to meet acceptable criteria due to the motion of the fingertip, the data collection procedure was restarted.
Hardware system
The data collection kit includes a smartphone, USB-powered LED flashlight, a 430 nm 10 FFWH Blue light filter (4 cm × 10 cm), a 1100 micro-T magnet (30 cm × 5 cm), aesthetically organized in a light-weight box as shown in Fig. 2. The distance between the pair-wise items is given below where d (x, y) denotes distance of x from y:
-
d (the magnet, the light) = 6 cm
-
d (the finger, the camera) = 4 cm
-
d (the light, the camera) = 2 cm
The blue light filter is placed on top of the LED flashlight to illuminate the fingertip with blue light, and the magnet maximizes the contrast between the RBC and the flow gap to regulate the flow of blood. The 1100 micro-T magnet was strategically positioned near the smartphone’s magnetometer to consistently repulse the negative charge from hemoglobin, ensuring a uniform directionality of RBC flow. The light-weight enclosed box was included in the setup to securely stabilize the smartphone, minimizing movement and ensuring consistent positioning of the fingertip throughout the measurement.
Challenges and solution by UbiWhite
An android application, UbiWhite, was developed to facilitate WBC counting at the point of care. The users would register with their email addresses and set up a password to store their values across different devices. This benefits the user in data storage and retrieval by tracking their records and their healthcare providers in monitoring their critical patients. Furthermore, the application performs three essential tasks- noise detection, magnetic field strength measurement, and light intensity detection- to ensure the empirical values found in the literature are consistent throughout the video capture. RGB Motion Detector of Android is used to detect the presence of noise in data collection. Movements of the fingertip during video capture can introduce noise and distort the Photoplethysmograph (PPG) signals. In data collection, a slight sneeze could deteriorate the steady sitting position. Smartphone magnetometers are sensors integrated into smartphones that measure the strength and direction of magnetic fields. Subsequently, the Android phone’s magnetometer reading was taken to ensure the appropriate magnetic field strength was maintained before starting the data collection. A stronger magnetic field interferes with the device’s magnetometer, while a magnetic field that is too weak will be a hurdle in regulating the blood flow. Moreover, this level is well below the International Commission on Non-Ionizing Radiation Protection (ICNIRP) recommended exposure limit of 40,000 µT. Finally, without the exact wavelength of light, the proposed WBC calculation algorithm fails. Calculating the light incident’s luminous intensity on the back camera ensured that a light of specific intensity was captured. To facilitate accurate replication of conditions, the UbiWhite application provides real-time guidance on positioning and setup, including visual and audio cues to help users maintain the optimal fingertip position and avoid common disturbances such as unintended movement. By ensuring better signal quality with the three tasks, we can attain better results.
Algorithm development
An object model of white blood cells was developed to develop an algorithm for white blood cell count. The attributes of the model are as follows-
-
MaxRed: the maximum pixel intensity of the red channel in a frame. This feature is used as an indicator of light absorption variations caused by white blood cells (WBCs) passing through the capillaries, as WBCs cause optical absorption gaps (OAGs).
-
MaxBlue: the maximum pixel intensity of a blue channel in a frame. This variable would record the maximum absorption of the blue channel by the flowing blood. It can also exhibit the distinct patterns of blue channel intensity as blood flows through the finger.
-
MaxDiffRed: the difference of max Histogram value with the previous frame of the red channel. This attribute measures the temporal variation in red intensity between consecutive frames. This difference highlights changes in blood flow over time, specifically fluctuations linked to the WBC movement.
-
MaxDiffBlue: the difference of max Histogram value with the previous frame of the blue channel. This attribute captures the dynamic variations in blue channel intensity, allowing for a more nuanced understanding of blue channel absorption. Additionally, any rapid changes to this variable can refer to motion artifact during data collection.
Algorithm: getCountAndLevelWBC
Our algorithm consists of three major subroutines. We describe the pseudocode and description of each of the subroutines below:
Pseudocode
-
1.
For each frame in the fingertip video:
-
a.
Split the frame into its Red (R), Green (G), and Blue (B) channels.
-
b.
Calculate the pixel values for each channel.
-
c.
Calculate the maximum histogram value for the R and B channels.
-
d.
If it’s not the first frame:
-
i.
Compute the difference between the maximum histogram values and the previous frame.
-
i.
-
a.
-
2.
Apply the K-means algorithm with K = 4 to obtain the cluster-assignment threshold.
-
3.
Count the number of frames according to the cluster-assignment threshold for the lowest valued cluster.
-
4.
Obtain the Cardiac output value using either empirical values or real-time estimated values.
-
5.
Return the count and level of white blood cells.
Algorithm subroutines
Calculating pixel intensity value of the captured fingertip video
Separating the color channels allows for individual analysis of each channel’s pixel intensity, which is crucial for detecting variations specific to WBCs. Furthermore, quantifying pixel values for each channel provides the necessary data for subsequent histogram analysis. The maximum values in the histogram indicate the most intense pixel values, which are expected to highlight the presence of WBCs. Comparing the current frame’s maximum values with the previous frame helps identify dynamic changes and fluctuations attributable to WBC flow.
Performing K means clustering on the pixel intensity values
Clustering the data helps in categorizing the frames based on pixel intensity variations, and the K = 4 setting is empirically chosen to balance granularity and computational efficiency. The choice of K was determined through extensive experimentation involving a range of K values. We conducted clustering analysis on the first 10 participant’s data with known class labels and evaluated the performance of the values using the within-cluster sum of squares (WCSS) and silhouette score. The optimal number of clusters was identified as K = 4 based on the highest silhouette score and a significant reduction in WCSS, indicating well-separated and cohesive clusters.
Estimating WBC by counting OAGs based on K means clustering assignments
The presence of WBCs will be ‘outliers’ in the flow of blood since they appear as optical absorption gaps (OAGs) in blood, as demonstrated by research2. So, counting flow gaps or flow drops can be approximated as the task of ‘outlier detection.’ Frames assigned to the lowest cluster correspond to moments of significant WBC presence, as they have lower pixel intensity variations. Since Cardiac Output (CO) can provide an accurate and contextually relevant measure of WBC levels in the bloodstream, incorporating CO ensures that the WBC count is contextualized within the overall blood flow, enhancing the accuracy of the final WBC level estimation. The final step consolidates the frame count and cardiac output data to provide an accurate WBC count and level.
Data analysis
Fingertip video processing
We captured minute-long videos of light reflected by the fingertip at 30 frames per second. The Google Pixel 2 smartphone was used to collect and process the videos for the fingertip video, which would later be used for white blood cell counting, as demonstrated in Fig. 3.
The initial step of the analysis involved storing the four values of the pixel intensity of the white blood cell object model, as discussed in "Algorithm development" section, for each frame in the video into a single file. This matrix-based data enables us to perform fast calculations on modern smartphones. A sample of the processed numeric dataset is shown in Fig. 4.
Afterward, by performing a visual analysis in the form of a histogram of the Fingertip video max & successive difference dataset, it was observed that the average value of light absorbed in blue and red channels was constant, while the peak values in blue changed due to the presence of flowing white blood cells as indicated by Fig. 5.
An ideal PPG signal has the following features—pulse amplitude, main peak, peak-to-peak interval, systolic peak, diastolic peak, and dichroitic notch. As exhibited in Fig. 6a, the raw signal has uneven edges and fluctuations and it has been widely researched that movement and signal drift can easily distort these sort of signals26. The noise reduction by the Butterworth filter is particularly noticeable in the amplitude of the peaks and troughs, which are smoother and more consistent in the denoised signal compared to the raw signal as illustrated in Fig. 6b.
Precisely selecting the block wise PPG signal from the minute-long continuous signals is part and parcel of the UbiWhite system. The quality of these block-wise signals directly influences the performance of the clustering algorithm and, consequently, the effectiveness of the Butterworth filters. We selected 5 best fit PPG signals as depicted in Fig. 7 by the red rectangles to select the best input signal.
White blood cell count formulation
The focus was on utilizing empirical parameter values to establish a baseline of WBC level. Volume Flow Rate (VFR) is calculated from the blood flow rate measured in the fingertip video by tracking changes in light absorption as blood cells move through capillaries27. In studies focused on fingertip blood flow, such as photoplethysmography (PPG) or video-based analyses, the VFR is typically much smaller and is estimated around 0.1 to 1 µl/s, depending on the subject and conditions28.
We describe the parameters used to calculate the WBC counts and levels below:
-
The ratio of WBC to total blood, r
Calculated from the histogram-based matrix data, by dividing the number of frames in the lowest intensity cluster (β) by the sum of elements in all clusters. Here, f is the Number of frames in the fingertip video, which is equivalent to the sum of elements in all clusters.
$$r = \frac{\upbeta }{f}$$(1) -
Blood flow amount, α
Calculated by normalizing the Blood flow rate, Volume Flow Rate (VFR) to µl/s unit. After simplifying, we get
$$\upalpha = \frac{{{\text{VFR}}*{\text{t}}}}{60}*1000$$$$\upalpha = \frac{{{\text{VFR}}*{\text{t}}}}{3}*50$$(2) -
Count of WBC, C
Calculated from r and α values
$${\text{C}} = \frac{{\text{r}}}{\upalpha }$$(3) -
Level of WBC, L
Calculated from C value
$${\text{L}} = \, \left\{ {{\text{low}},{\text{ normal}},{\text{ high}}} \right\}{\text{ based on C value based on the age}},{\text{ gender}}$$(4)
Feature generation from PPG signal
Following the creation of the PPG signal obtained through video capture using a smartphone held at the fingertip, we extracted features, including its diastolic peak, dicrotic notch height, ratio, and augmented ratio among systolic, diastolic, and dicrotic notch, systolic and diastolic rising slope, and inflection point area ratio29. Extensive filtering was done on the generated PPG signal to ensure good signal quality. Firstly, we grouped five adjacent sets of PPG cycles as one block of PPG wave. Secondly, filtering at individual PPG cycle levels inside a block was done, and we discarded the block that did not have a single PPG cycle satisfying the following condition—one systolic peak (sp) followed by one dicrotic notch (dn) with lower intensity value than the sp, one diastolic peak with higher intensity than the dn but lower than the sp.
One inherent challenge of using PPG signals is the differences in skin tone and texture among participants, which can affect the reflectance and absorption of light, which in turn impacts the accuracy of the PPG signal and subsequent WBC counts30. Calibration for individual variations might be necessary to minimize this variability.
Result
We have used two different algorithms on the same fingertip video. The two algorithms differ in the feature sets. We implemented the algorithm 1 by using the MaxRed features only. In contrast, we have considered MaxRed and maxDiffRed features in algorithm 2. By including MaxDiffRed, algorithm 2 adds a layer of temporal dynamics, improving the detection of WBC presence by capturing not just static intensity levels but also their rate of change. The combination of these two features allows algorithm 2 to be more sensitive to subtle changes in blood flow.
-
MaxRed indicates the most intense red pixels, likely corresponding to moments when blood is passing through capillaries.
-
MaxDiffRed tracks how these pixel intensities change between frames, signaling potential disruptions in blood flow caused by WBCs as shown in Fig. 8. This dynamic feature helps detect the occurrence of WBCs, as they typically cause these disruptions.
Cluster assignment and WBC counting
The lowest intensity cluster, which contains frames with the smallest pixel intensity variations, represents periods of significant WBC presence. These frames are identified as ‘outliers’ due to the optical absorption gaps (OAGs) created by WBCs, which lower the light intensity. Figure 9 illustrates the distribution of frames across the four clusters.
Figure 10 provides a visual representation of frame counts per cluster with distinct color coding for each cluster and the lowest intensity frames.
Result generation
The following Table 2 illustrates the gold standard WBC value and the range of values (min, max) produced by the two algorithms, along with their average values. Since we are using empirical cardiac output values, with the min and max being 5 and 6 Liter per minute respectively, both algorithms predict WBC in a min and max range. These values are averaged to derive the A-1 avg and A-2 avg values. All the entries in the table have the unit as # WBC per Liter of blood.
Comparison of the algorithm performances
Table 3 shows the performance metric of the two algorithms where the A-1 avg and A-2 avg values were used to represent the model performances.
The MAE implies that the average difference between the prediction of A-2 and the actual values is higher than for A-1. The RMSE for A-2 was higher than the MAE, indicating there are a few predictions by the A-2 algorithm that varied significantly from the actual values, pulling the RMSE value up. In conclusion, both algorithms show varying performance, with neither consistently outperforming the other across all metrics. While A-2 had a lower average error, indicating better accuracy, it scored poorer on MAE and RMSE, meaning that its predictions varied more from the actual values than A-1. Specifically, large errors are more prominent in A-2's predictions, as evidenced by the higher RMSE value.
Correlation analysis
We quantified the correlation between the average, maximum and minimum values predicted by both of the algorithms with the actual gold-standard value.
Correlation between the maximum WBC values and the actual WBC count
-
Correlation coefficient for A-1 max: R = 0.67, p-value = 0.001
-
Correlation coefficient for A-2 max: R = 0.55, p-value = 0.012
Although both algorithms exhibit a moderate positive correlation, A-2 does not perform as strongly as A-1 in terms of predicting maximum values as displayed in Fig. 11. Nonetheless, the significant p-value for both algorithms (p < 0.05) demonstrates that these correlations are statistically meaningful, further validating the algorithms’ performance for maximum measurements.
Correlation between the minimum WBC values and the actual WBC count
-
Correlation coefficient for A-1 min: R = 0.61, p-value = 0.004
-
Correlation coefficient for A-2 min: R = 0.53, p-value = 0.016
Figure 12 reveals that the minimum WBC readings produced by the algorithms also align reasonably well with the actual values, with A-1 again showing a slightly better performance.
Correlation between the average WBC values and the actual WBC count
-
Correlation coefficient for A-1 avg: R = 0.65, p-value = 0.002
-
Correlation coefficient for A-2 avg: R = 0.54, p-value = 0.01
Figure 13 suggests that both algorithms track the actual WBC count reasonably well when considering average values, with A-1 showing slightly better performance. Furthermore, the low p-values indicate that the observed correlations are statistically significant, meaning there is a minimal likelihood that these results occurred by random chance.
Statistical analysis
In this study, we undertook a statistical assessment to evaluate the performance of two algorithms, A-1 and A-2, in predicting the target variable of WBC count. For validating our novel smartphone-based WBC counting system, we determined a sample size 20 using G*Power 3.131. The analysis was conducted using the dataset of 20 subjects. This sample size was calculated based on the moderate size of 0.5, with a power of 0.68 at a one-tailed test at an alpha level of 0.05. This sample size assures statistically reliable validation against gold-standard clinical data, allowing us to evaluate the new smartphone-based WBC counting system’s accuracy confidently.
The t-value measures the difference between the mean predictions of the algorithms and the actual WBC counts relative to the variability of the predictions. A higher t-value indicates a more significant difference between the algorithm’s predictions and the actual values.
The statistical tests used were paired t-tests to compare the mean predictions of the algorithms with the actual values. We applied a two-tailed test to assess the prediction difference without specifying a specific direction. For algorithm A-1 and A-2, the paired t-test yielded a t-value of 1.29 and 0.12, respectively.
The p-value assesses the probability that the observed differences between the algorithms’ predictions and the actual WBC counts are due to random chance. A p-value more significant than the alpha level (e.g., 0.05) suggests that the differences are not statistically significant.
Likewise, A-1 and A-2 exhibit p-values of 0.21 and 0.91, respectively. These findings suggest the absence of statistically significant differences between the outcomes of either algorithm or the observed empirical data. We performed the tests at a 95% confidence level. The absence of statistical significance suggests that both A-1 and A-2 algorithms perform similarly in predicting the target variable.
Discussion
Effect of blue light filter
With the blue light filter, the green channel was fully absorbed, while the red channel had lower absorption, as depicted in Fig. 14a. In contrast, the green and blue channels were fully absorbed without the blue light filter, as plotted in Fig. 14b. The blue channel absorption decreased more than the red channel with the presence of the blue light filters. Blue light, being of shorter wavelength, tends to scatter more, especially in biological tissues like blood vessels. Since the red channel has longer wavelengths, it experiences less scattering and is typically absorbed more by hemoglobin-rich blood cells, making its intensity less affected by the filtering. This differential response between the red and blue channels highlights the varying optical properties of different light wavelengths as they interact with biological tissues, and it may offer insights into the distribution and behavior of blood components under specific experimental conditions.
Effect of magnetism
The influence of magnetism on hemoglobin-containing red blood cells was observed. A comparison of histograms generated from fingertip videos captured with and without the magnetic field corroborated these findings, providing visual support for the observed effects. The data presented in Fig. 15 here suggests that magnetism alters the distribution of red blood cells within the blood vessels.
When the magnet was applied, the mean of the MaxRed intensity decreased from 0.25344 (0.007) to 0.2158 (0.019), suggesting a change in the distribution of red blood cells (RBCs) and their interaction with light. This decrease may indicate that magnetism affects the concentration or flow pattern of RBCs, leading to altered optical absorption gaps. In contrast, the mean MaxBlue intensity increased significantly from 0.29658 (0.022) to 0.49797 (0.264), which could indicate a heightened reflection or scattering effect under magnetism. These results suggest that magnetism affects both red and blue channel intensities, possibly altering the arrangement of blood components within the vessels.
A confidence interval provides a plausible range for the true parameter value in the population, based on a representative sample32. To quantify the precision of estimate, width of the confidence interval is one of the most commonly used parameters33.
Table 4 shows very insignificant dispersion from mean for both the red channel and blue channel. Data shows positive impact of magnetism in increasing channel absorption. Since the confidence interval is very narrow, it indicates that the sample data for the white blood cell count, both with and without the magnet, is consistent and provides a precise estimate of the true mean34. This suggests that magnetism not only affects red blood cells but also enhances light scattering or absorption in the blue spectrum, potentially due to changes in blood flow dynamics.
Effect of noise in data collection
Any slight movement can introduce noise and affect the signal quality. We have attempted to generate a supervised learning model looking into the distribution of noisy and stable signal features. Experiments have been carried out to incorporate premeditated motion artifacts in two sets of fingertip videos.
For the maxDiffBlue feature, the stable signal exhibits lower dispersion, indicating less variability in the maxDiffBlue values compared to the noisy signal, as shown in Fig. 16. Furthermore, the absence of outliers in the stable signal further emphasizes the reduced noise and increased consistency in the data.
The maxBlue distribution for the noisy signal is skewed to the right, indicating a concentration of lower values with a tail extending towards higher values, as shown in Fig. 17. Additionally, the distribution’s spread is wider, implying a greater degree of variability in maxBlue values. In contrast, the maxBlue distribution for the stable signal is narrower, reflecting a lower degree of dispersion compared to the noisy signal.
Limitations
The current design of the UbiWhite system, including the optical attachment and blue light bandpass filter, was optimized specifically for the Google Pixel 2 to ensure minimal light scattering and consistent illumination of the fingertip. This design choice allows the system to achieve higher contrast between red blood cells and flow gaps, enhancing the accuracy of WBC counting. However, the system is not device agnostic, meaning that the performance may vary on other smartphone models due to differences in camera specifications and sensor configurations, potentially limiting its widespread applicability without further modifications.
The system may have difficulty with users who have physical conditions affecting their hands or fingers, such as injuries, deformities, or poor circulation. Such conditions could distort the blood flow patterns that the system relies on to detect WBCs, reducing the accuracy of the measurement. Additionally, factors like skin moisture, temperature, and pressure applied to the phone’s camera could also influence the results.
Moreover, the system’s current validation has been limited to participants with relatively normal WBC counts, which may not fully represent the clinical scenarios where extreme WBC variations are critical for diagnosis and treatment. Future studies must assess the system’s accuracy in detecting both abnormally high WBC counts, common in infections or leukemia, and low counts, often seen in immunocompromised individuals, to ensure its reliability in diverse medical conditions.
Feasible future scope
Developing a smartphone-based system for real-time WBC counting opens exciting future research and implementation opportunities. Further refinement of algorithms and technological enhancements can improve the accuracy and reliability of WBC counts, enhancing the system’s performance in various clinical scenarios35. Integration with telemedicine platforms and cloud-based solutions could facilitate remote monitoring and data sharing, extending the reach of this technology beyond traditional healthcare settings. One possible usage can be in children’s emergency. Collaborations with healthcare professionals and stakeholders will be crucial for successfully integrating this system into existing healthcare infrastructures. Overall, the future of this innovative approach lies in continuous refinement, collaboration, and exploration of its broader clinical utility.
Conclusion
Regular monitoring of white blood cell (WBC) counts plays a pivotal role in healthcare, profoundly impacting an individual’s well-being. It encompasses a spectrum of critical functions, including early infection detection, the continuous tracking of chronic ailments, the identification of bone marrow disorders, immune system assessment, medication effect management, allergy reaction detection, post-surgery recovery assurance, and holistic health evaluation. Our research introduces an innovative way to count WBCs using videos of fingertips without drawing blood. As smartphones and sensors advance, the significance of mobile health (mHealth) in our daily lives is steadily increasing. Consequently, our research is driven by a commitment to harness the full potential of Mobile Computing using sensors, networking capabilities, and computational capabilities.
Furthermore, we have designed an ergonomic optical attachment and developed a smartphone application to ensure user-friendliness. The initial test results of our systems are quite accurate, offering a needle-free alternative to traditional methods of counting WBCs. Studies will be conducted with larger and more diverse sample populations to assess the robustness of the system under different ambient settings. Furthermore, the large-scale study will enable the evaluation of our algorithms in diverse environmental settings to determine how external factors affect measurement accuracy.
Data availability
The datasets used in the study are available from the corresponding author upon reasonable request.
References
Greer, J. P. et al. Wintrobe’s Clinical Hematology 14th edn. (Wolters Kluwer Health Pharma Solutions (Europe) Ltd, 2018).
Bourquard, A. et al. Non-invasive detection of severe neutropenia in chemotherapy patients by optical imaging of nailfold microcirculation. Sci. Rep. 8(1), 5301 (2018).
Meinke, M., Gersonde, I., Friebel, M., Helfmann, J. & Müller, G. Chemometric determination of blood parameters using visible–near-infrared spectra. Appl. Spectrosc. 59(6), 826–835 (2005).
Meinke, M., Müller, G., Helfmann, J. & Friebel, M. Optical properties of platelets and blood plasma and their influence on the optical behavior of whole blood in the visible to near infrared wavelength range. J. Biomed. Opt. 12(1), 014024 (2007).
Chekroud, A. M. et al. The promise of machine learning in predicting treatment outcomes in psychiatry. World Psychiatry 20(2), 154–170 (2021).
Shlomowitz, A. & Feher, M. D. Anxiety associated with self-monitoring of capillary blood glucose. Br. J. Diabetes. 14(2), 60 (2014).
Nir, Y., Paz, A., Sabo, E. & Potasman, I. Fear of injections in young adults: prevalence and associations. Am. J. Trop. Med. Hyg. 68(3), 341–344 (2003).
Yaroslavsky, A. N., Priezzhev, A. V., Rodriquez, J., Yaroslavsky, I. V. & Battarbee, H. Optics of blood. In Handbook of Optical Biomedical Diagnostics (ed. Tuchin, V. V.) 169–216 (SPIE-Press, 2002).
Yim, D., Baranoski, G. V., Kimmel, B. W., Chen, T. F. & Miranda, E. A cell‐based light interaction model for human blood. In Computer Graphics Forum 2012 May, Vol. 31, No. 2pt4, 845–854 (Blackwell Publishing Ltd., 2012).
Bosschaart, N., Edelman, G. J., Aalders, M. C. & van Leeuwen, T. G. A literature review and novel theoretical approach on the optical properties of whole blood. Lasers Med. Sci. 29, 453–479 (2014).
Yim, D., Baranoski, G. V., Chen, T. F., Kimmel, B. W. & Miranda, E. On the Modeling of Light Interactions with Human Blood. (2012).
Greiner, C., Hunter, M., Huang, P., Rius, F. & Georgakoudi, I. Confocal backscattering spectroscopy for leukemic and normal blood cell discrimination. Cytom. A. 79(10), 866–873. https://doi.org/10.1002/cyto.a.21095 (2011).
Winkelman, J. W. Non-invasive blood cell measurements by imaging of the microcirculation. Am. J. Clin. Pathol. 113(4), 479–483. https://doi.org/10.1309/7079-v61f-d90u-gu6r (2000).
Huo, Y., Liu, G., Jing, R. & Zhao, P. Non-invasive detection of the content of white blood cells in the blood of humans based on dynamic spectrum. Physiol. Meas. https://doi.org/10.1088/1361-6579/accb3a (2023).
Plataforma SINC. A new portable device counts leukocytes through the skin. ScienceDaily. Retrieved July 1, 2021 from http://www.sciencedaily.com/releases/2015/09/150930074436.htm (2015).
MIT News. Leuko spots life-threatening infections in cancer patients. MIT News. https://news.mit.edu/2024/leuko-spots-life-threatening-infections-cancer-patients-0616 (2024).
Bourquard, A. et al. Analysis of white blood cell dynamics in nailfold capillaries. In 2015 37th Annual International Conference of the IEEE Engineering in Medicine and Biology Society (EMBC), 7470–7473) (IEEE, 2015).
Bagramyan, A. & Lin, C. P. Miniaturized microscope for non-invasive imaging of leukocyte-endothelial interaction in human microcirculation. Sci. Rep. 13, 17881. https://doi.org/10.1038/s41598-023-45018-1 (2023).
Mustafa, B. T., Yaba, S. P. & Ismail, A. H. Experimental evaluation of the static magnetic field effect on white blood cells: in vivo study. Mater. Sci. Forum 1002, 412–419. https://doi.org/10.4028/www.scientific.net/msf.1002.412 (2020).
Mustafa, B. T., Yaba, S. P. & Ismail, A. H. A review of the Effects of Magnetic Field on main blood cells: in vivo and in vitro experiments. ZJPAS 31(6), 40–50 (2019).
Abi Abdallah, D., Drochon, A., Robin, V. & Fokapu, O. Effects of static magnetic field exposure on blood flow. Eur. Phys. J. Appl. Phys. 45(1), 11301. https://doi.org/10.1051/epjap:2008193 (2009).
Misra, J. & Shit, G. C. Effect of magnetic field on blood flow through an artery: A numerical model. J. Comput. Technol. 12, 3–16 (2007).
Jo, S. & Eom, K. A simple capillary blood cell flow monitoring system using magnetic micro-sensor: a simulation study. Electronics 9(4), 618. https://doi.org/10.3390/electronics9040618 (2020).
Semyanov, K. et al. Optics of Leucocytes. https://doi.org/10.1007/978-1-4020-5502-7_10 (2007).
Budde, M. et al. FeinPhone: low-cost smartphone camera-based 2D particulate matter sensor. Sensors. 19, 749. https://doi.org/10.3390/s19030749 (2019).
Liu, S.-H., Li, R.-X., Wang, J.-J., Chen, W. & Su, C.-H. Classification of photoplethysmographic signal quality with deep convolution neural networks for accurate measurement of cardiac stroke volume. Appl. Sci. 10, 4612. https://doi.org/10.3390/app10134612 (2020).
Baran, U., Shi, L. & Wang, R. K. Capillary blood flow imaging within human finger cuticle using optical microangiography. J. Biophotonics 8(1–2), 46–51. https://doi.org/10.1002/jbio.201300154 (2015).
Klarhöfer, M., Csapo, B., Balassy, C., Szeles, J. C. & Moser, E. High-resolution blood flow velocity measurements in the human finger. Magn. Reson. Med. 45, 716–719. https://doi.org/10.1002/mrm.1096 (2001).
Erış, Ö., Erış, S. B., Bılgın, C. & Bozkurt, M. R. IIR based digital filter design for denoising the photoplethysmography signal. In 2021 29th Signal Processing and Communications Applications Conference (SIU), 1–4 (IEEE, 2021).
Spetlík, R., Cech, J., & Matas, J. Non-contact reflectance photoplethysmography: progress, limitations, and myths. In 2018 13th IEEE International Conference on Automatic Face & Gesture Recognition (FG 2018) (IEEE, 2018) 702–709
Faul, F., Erdfelder, E., Buchner, A., & Lang, A.-G. G*Power. Retrieved July 31, 2024, from https://www.psychologie.hhu.de/arbeitsgruppen/allgemeine-psychologie-und-arbeitspsychologie/gpower.
Schober, P., Bossers, S. M. & Schwarte, L. A. Statistical significance versus clinical importance of observed effect sizes: what do P values and confidence intervals really represent?. Anesth. Anal. 126(3), 1068–1072 (2018).
Schober, P. & Vetter, T. R. Confidence intervals in clinical research. Anesth. Anal. 130(5), 1303. https://doi.org/10.1213/ANE.0000000000004731 (2020).
Hazra, A. Using the confidence interval confidently. J. Thorac. Dis. 9(10), 4125–4130. https://doi.org/10.21037/jtd.2017.09.14 (2017).
Liang, Y., Elgendi, M., Chen, Z. & Ward, R. An optimal filter for short photoplethysmogram signals. Sci. Data. 5(1), 1–2 (2018).
Acknowledgements
Grants from the Ubicomp Research Lab, Department of Computer Science, Marquette University partially support this project.
Author information
Authors and Affiliations
Contributions
N U S Sabith developed the algorithm, designed the hardware system, developed the application and collected data. M Rabbani reviewed and proofread the article. K S Alam surveyed the literature, co-designed the hardware system, and reviewed the article. S I Ahamed came up with the idea and lead the project.
Corresponding author
Ethics declarations
Competing interests
The authors declare no competing interests.
Additional information
Publisher’s note
Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.
Rights and permissions
Open Access This article is licensed under a Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International License, which permits any non-commercial use, sharing, distribution and reproduction in any medium or format, as long as you give appropriate credit to the original author(s) and the source, provide a link to the Creative Commons licence, and indicate if you modified the licensed material. You do not have permission under this licence to share adapted material derived from this article or parts of it. The images or other third party material in this article are included in the article’s Creative Commons licence, unless indicated otherwise in a credit line to the material. If material is not included in the article’s Creative Commons licence and your intended use is not permitted by statutory regulation or exceeds the permitted use, you will need to obtain permission directly from the copyright holder. To view a copy of this licence, visit http://creativecommons.org/licenses/by-nc-nd/4.0/.
About this article
Cite this article
Sabith, N.U.S., Rabbani, M., Alam, K.S. et al. Smartphone based non invasive real time white blood cell counter leveraging blue light and static magnetic field. Sci Rep 15, 1594 (2025). https://doi.org/10.1038/s41598-024-81459-y
Received:
Accepted:
Published:
DOI: https://doi.org/10.1038/s41598-024-81459-y