ChatPPG Editorial

ML Classifiers for Cardiac Arrhythmia Detection from PPG: Algorithms, Accuracy & Clinical Evidence

**Cardiac arrhythmia detection from photoplethysmography has progressed from a research curiosity to a clinically validated screening capability, with...

ChatPPG Team
Published
12 min read
  • Arrhythmia & ECG
ML Classifiers for Cardiac Arrhythmia Detection from PPG: Algorithms, Accuracy & Clinical Evidence
Editorial illustration · Devices and signals are conceptual. Where shown, violet optical paths represent invisible infrared in false color.

Cardiac arrhythmia detection from photoplethysmography has progressed from a research curiosity to a clinically validated screening capability, with the FDA clearing multiple PPG-based atrial fibrillation detection algorithms for consumer wearable devices since 2018. The fundamental premise is that arrhythmias disrupt the regularity, amplitude, and morphology of the peripheral pulse wave, and these disruptions are detectable by machine learning classifiers applied to PPG signals. However, the distinction between different arrhythmia types, the management of motion artifacts, and the transition from controlled laboratory settings to real-world wearable deployment present substantial technical challenges.

This article provides a comprehensive technical review of machine learning approaches for cardiac arrhythmia classification from PPG, covering feature engineering, classical ML classifiers, deep learning architectures, and clinical validation evidence. For background on PPG signal acquisition and processing, see our introduction to PPG technology. For related work on atrial fibrillation detection specifically, see our article on wearable AF detection.

The Arrhythmia Detection Problem in PPG

What PPG Can and Cannot See

PPG measures the hemodynamic consequences of cardiac electrical activity, not the electrical activity itself. This distinction is critical for understanding the inherent capabilities and limitations of PPG-based arrhythmia detection.

PPG can reliably capture:

  • Beat-to-beat timing irregularity (the hallmark of atrial fibrillation, frequent ectopy, and certain conduction disorders)
  • Pulse amplitude variations (which occur with varying ventricular filling times in AF and with compensatory pauses after premature beats)
  • Missing or reduced-amplitude beats (premature ventricular contractions that fail to generate adequate pulse pressure)
  • Rate abnormalities (tachycardia, bradycardia)
  • Pulse morphology changes associated with altered hemodynamics

PPG fundamentally cannot detect:

  • P-wave abnormalities (atrial flutter vs. AF distinction)
  • QRS morphology (wide vs. narrow complex differentiation)
  • ST-segment changes (ischemia detection)
  • PR interval prolongation (first-degree AV block)
  • Most conduction abnormalities that do not alter ventricular rate regularity

This means PPG is inherently a screening tool for a subset of arrhythmias, not a replacement for ECG. The clinical value lies in continuous, long-duration monitoring that can detect intermittent arrhythmias missed by brief clinic-based ECG recordings.

Signal Processing Prerequisites

Before any arrhythmia classification algorithm can operate, the raw PPG signal must undergo preprocessing to extract reliable beat-to-beat timing and morphological features. The standard pipeline includes:

  1. Bandpass filtering (typically 0.5-8 Hz) to isolate the cardiac pulsatile component
  2. Beat detection using systolic peak identification algorithms (e.g., Elgendi et al., 2013; doi:10.1371/journal.pone.0076585)
  3. Signal quality assessment to identify and reject motion-corrupted segments
  4. Inter-beat interval (IBI) extraction from successive systolic peaks

The accuracy of beat detection directly limits arrhythmia classification performance. False or missed beat detections create artificial irregularity that can mimic arrhythmias. Elgendi's two-event-related moving average (TERMA) algorithm achieves beat detection sensitivity of 99.5% and positive predictive value of 99.6% on clean PPG signals, but performance degrades to 85-92% during moderate motion (Elgendi, 2013). For motion artifact removal techniques that improve beat detection during activity, see our motion artifact removal guide.

Feature Engineering for Arrhythmia Classification

Pulse Interval Features

The irregularity of inter-beat intervals (IBIs) is the primary feature space for arrhythmia detection, particularly for atrial fibrillation. Key features include:

Root mean square of successive differences (RMSSD). RMSSD quantifies beat-to-beat variability and is elevated in AF compared to normal sinus rhythm. Typical RMSSD values in AF exceed 40-80 ms, compared to 20-40 ms in normal sinus rhythm (age-dependent). However, RMSSD alone cannot distinguish AF from sinus arrhythmia or frequent ectopy.

Shannon entropy of IBI distribution. Entropy measures quantify the randomness of the IBI sequence. AF produces a characteristic high-entropy, nearly uniform IBI distribution, distinct from the more structured variability of normal sinus rhythm. Dash et al. (2009) combined Shannon entropy with RMSSD and the turning point ratio of RR intervals and achieved 94.4% sensitivity and 95.1% specificity on the MIT-BIH Atrial Fibrillation Database (doi:10.1007/s10439-009-9740-z).

Poincare plot features. The Poincare plot (IBIn\mathrm{IBI}_n vs. IBIn+1\mathrm{IBI}_{n+1}) provides geometric features that capture different aspects of rhythm irregularity. SD1 (short-term variability), SD2 (long-term variability), and the SD1/SD2 ratio are commonly used. In AF, the Poincare plot shows a characteristic "shotgun" pattern with high dispersion in both axes and loss of the elongated elliptical shape seen in sinus rhythm. Sarkar et al. (2008) built an AF/atrial tachycardia detector for implantable monitors based on ventricular irregularity; it detected AF burden in all 124 AF records, with 94% specificity in 174 records without AF/AT (doi:10.1109/TBME.2007.903707).

Turning point ratio. The turning point ratio (TPR) counts the fraction of IBI samples where the value changes direction (local maxima or minima). For a random sequence, the expected TPR is 2/3. AF produces TPR values close to this theoretical random value, while normal sinus rhythm has lower TPR due to the physiological structure of heart rate variability. Dash et al. (2009) introduced TPR as one of the three statistics in their AF detector.

Coefficient of variation (CV) of IBIs. The CV (standard deviation / mean) normalizes variability for rate and provides a unitless irregularity measure. CV values above 0.10-0.12 are suggestive of AF, though frequent ectopy can also elevate CV.

Morphological Features

Beyond timing, the shape of individual PPG pulses and pulse-to-pulse shape variation carry arrhythmia information:

Pulse amplitude variability (PAV). Beat-to-beat variation in systolic peak amplitude increases in AF due to varying ventricular filling times. The coefficient of variation of pulse amplitudes, computed over 30-60 second windows, provides additional discriminative information beyond timing features alone.

Template correlation. Cross-correlating each pulse waveform against a running average template quantifies morphological consistency. Normal sinus beats produce high template correlations (r > 0.90), while PVCs and other aberrantly conducted beats produce lower correlations. This feature is valuable for PVC detection and for identifying aberrant conduction during AF.

Pulse width features. Systolic width, diastolic width, and the systolic/diastolic ratio change with premature beats and compensatory pauses, providing morphological markers for ectopic beat identification.

Classical Machine Learning Classifiers

Support Vector Machines (SVM)

SVMs with radial basis function (RBF) kernels have been widely applied to PPG arrhythmia detection, particularly in the early literature. Typical feature sets combine IBI statistics computed over fixed windows. The key advantage of SVMs is their strong performance with relatively small training datasets, which was important given the limited availability of labeled PPG arrhythmia data in earlier studies.

Random Forests and Gradient Boosting

Ensemble tree methods have become the dominant classical ML approach for PPG arrhythmia classification. Random Forests provide built-in feature importance ranking, which aids in understanding which signal characteristics drive classification decisions.

Signal quality handling matters as much as the classifier. Tarniceriu et al. (2018) detected AF from windows of 20 consecutive wrist-PPG inter-beat intervals in 29 post-operative patients, with 98.45% sensitivity and 99.13% specificity, but a decision could only be made for about 76% of the time because unreliable intervals were discarded (doi:10.1109/EMBC.2018.8513197).

Gradient boosting classifiers such as XGBoost are also used for these feature sets, including for multi-class problems that separate normal sinus rhythm, AF, and other arrhythmias.

Hidden Markov Models (HMMs)

HMMs are particularly well-suited for arrhythmia detection because they model temporal sequences of states, capturing the transitions between normal rhythm and arrhythmia. Bonomi et al. (2018) used a Markov model to estimate the probability of AF from irregular patterns in wrist-PPG inter-pulse intervals, with motion-corrupted intervals discarded. AF was detected with 97% sensitivity in 20 cardioversion patients and 93% sensitivity in 40 Holter patients, both with 100% specificity, although no classification was available for 44% of the Holter monitoring period because of motion artifacts (doi:10.1161/JAHA.118.009351).

Deep Learning Architectures

1D Convolutional Neural Networks

1D CNNs operating on raw or minimally processed PPG waveforms have become the most popular deep learning approach for arrhythmia detection. Their key advantage is automatic feature learning, eliminating the need for hand-crafted feature engineering.

Architecture patterns. Successful 1D CNN architectures for PPG arrhythmia classification typically use 4-8 convolutional layers with increasing filter counts (32, 64, 128, 256), batch normalization, ReLU activation, and max pooling. The input is typically a 10-30 second PPG segment sampled at 64-256 Hz. Global average pooling before the output layer reduces the parameter count and provides some regularization.

Shen et al. (2019) trained a 50-layer CNN on more than 4,000 hours of annotated wrist PPG recorded in free-living conditions and achieved a test AUC of 0.95 for AF despite motion artifacts (doi:10.1145/3292500.3330657). Tison et al. (2018) trained a deep neural network on smartwatch heart rate and step count data from 9,750 participants; it reached a C statistic of 0.97 (sensitivity 98.0%, specificity 90.2%) against 12-lead ECG in 51 cardioversion patients, but only 0.72 in an exploratory ambulatory analysis (doi:10.1001/jamacardio.2018.0136).

Recurrent Neural Networks and LSTMs

Recurrent architectures are a natural fit for sequential PPG data, as they can model temporal dependencies across extended time windows. Long Short-Term Memory (LSTM) networks have been applied to both IBI sequences and raw PPG waveforms.

Shashikumar et al. (2017) applied deep learning to wearable PPG and accelerometry for AF monitoring (doi:10.1109/BHI.2017.7897225). Bidirectional architectures let a model use both past and future context when classifying each segment.

For wearable deployment, LSTM models face challenges due to their sequential computation requirement (each time step depends on the previous hidden state), which limits parallelization and increases latency. Gated Recurrent Units (GRUs) offer a simpler alternative with comparable performance and reduced computational cost.

Hybrid CNN-LSTM Models

Combining CNNs for local feature extraction with LSTMs for temporal modeling has proven particularly effective. The CNN layers extract morphological features from individual beats or short segments, while the LSTM layers model the temporal evolution of these features to detect sustained arrhythmias.

Torres-Soto and Ashley (2020) developed DeepBeat, a multitask model that jointly assesses signal quality and detects AF from wearable PPG. Pretrained on about one million simulated signals with convolutional denoising autoencoders and fine-tuned on over 500,000 labeled signals from more than 100 individuals, it improved AF detection F1 from 0.54 (single-task) to 0.96, and reached sensitivity 0.98 and specificity 0.99 in a prospective ambulatory replication cohort (doi:10.1038/s41746-020-00320-4).

Transformer Models

Attention-based transformer architectures have recently been applied to PPG arrhythmia detection, leveraging their ability to capture long-range dependencies without the sequential processing bottleneck of RNNs. Their computational cost is higher than CNN-based approaches, which makes real-time wearable deployment challenging.

Clinical Validation Studies

Apple Heart Study

The Apple Heart Study (Perez et al., 2019) enrolled 419,297 participants wearing Apple Watch devices with a PPG-based irregular rhythm notification algorithm. Over 8 months of monitoring, 0.52% of participants received an irregular pulse notification. Among the 450 notified participants who returned analyzable ECG patches, 34% had AF. The positive predictive value was 0.84 for observing AF on the ECG simultaneously with a subsequent irregular pulse notification (doi:10.1056/NEJMoa1901183).

This study established the feasibility of population-scale AF screening using wearable PPG but also highlighted the challenge of low positive predictive value when screening a low-prevalence population. The 34% AF confirmation rate among notified participants means that 66% received false-positive notifications, underscoring the need for high specificity in screening algorithms.

Huawei Heart Study

The Huawei Heart Study (Guo et al., 2019) enrolled 187,912 participants using Huawei smartwatches and bands. The PPG-based algorithm flagged 424 participants (0.23%) with suspected AF; of the 262 who were effectively followed up, 227 (87.0%) were confirmed to have AF, and the positive predictive value of the PPG signals was 91.6% (doi:10.1016/j.jacc.2019.08.019).

Fitbit Heart Study

The Fitbit Heart Study (Lubitz et al., 2022) enrolled 455,699 participants and used a PPG algorithm that analyzed overlapping 5-minute pulse windows (tachograms) and required 11 consecutive irregular tachograms before a notification. Among 1,057 notified participants with analyzable ECG patches, 32.2% had AF; when another detection occurred during patch monitoring, the positive predictive value for concurrent AF was 98.2% (doi:10.1161/CIRCULATIONAHA.122.060291).

Deployment Considerations

Computational Constraints

Wearable devices impose strict computational limits: ARM Cortex-M class processors, limited RAM (32-256 KB), and battery life constraints. Models deployed on these platforms must be compressed through quantization (INT8 or binary), pruning, and knowledge distillation. Successful deployments have achieved model sizes under 100 KB while maintaining AUC > 0.94 for AF detection. For more on embedded PPG signal processing, see our algorithms documentation.

Signal Quality Gating

Real-world PPG data contains substantial periods of motion artifact, sensor disconnection, and low perfusion. All production arrhythmia detection systems include signal quality assessment (SQA) as a gating mechanism. Only segments that pass SQA thresholds are forwarded to the arrhythmia classifier. This approach trades reduced sensitivity (arrhythmia episodes during motion may be missed) for improved specificity (reduced false positives from motion artifact).

Typical SQA features include: peak-to-peak amplitude thresholds, perfusion index minimums, template matching scores, and accelerometer-based motion intensity thresholds. Well-designed SQA can reject 30-60% of ambulatory PPG data while retaining >95% of arrhythmia-containing segments.

Multi-Class vs. Binary Classification

Most deployed systems use binary classification (AF vs. non-AF) because AF is the most clinically impactful arrhythmia detectable by PPG and has the strongest evidence base. Multi-class classification (AF, PVC, PAC, flutter, tachycardia, bradycardia) remains primarily a research endeavor, with reported accuracies 10-15% lower than binary AF detection due to the increased complexity and the hemodynamic similarity between certain arrhythmia types.

Conclusion

Machine learning classification of cardiac arrhythmias from PPG has matured from a laboratory demonstration to a clinically deployed capability for atrial fibrillation screening, validated in studies enrolling over one million participants collectively. The combination of robust feature engineering, deep learning architectures, and rigorous signal quality gating has produced systems with sensitivity exceeding 95% and specificity above 97% for AF detection under controlled conditions.

The next frontiers include multi-class arrhythmia discrimination, detection of lower-prevalence rhythm disorders, improved performance during physical activity, and integration with on-demand ECG confirmation. For researchers entering this field, the combination of publicly available PPG databases (MIMIC, IEEE SP Cup), open-source beat detection algorithms, and established feature sets provides a solid foundation. For current clinical applications and regulatory status, see our guide to wearable AF detection and our overview of health conditions monitorable by PPG.

References

  • Elgendi, M., Norton, I., Brearley, M., Abbott, D., & Schuurmans, D. (2013). Systolic peak detection in acceleration photoplethysmograms measured from emergency responders in tropical conditions. PLoS ONE, 8(10), e76585. https://doi.org/10.1371/journal.pone.0076585
  • Dash, S., Chon, K. H., Lu, S., & Raeder, E. A. (2009). Automatic real time detection of atrial fibrillation. Annals of Biomedical Engineering, 37(9), 1701-1709. https://doi.org/10.1007/s10439-009-9740-z
  • Sarkar, S., Ritscher, D., & Mehra, R. (2008). A detector for a chronic implantable atrial tachyarrhythmia monitor. IEEE Transactions on Biomedical Engineering, 55(3), 1219-1224. https://doi.org/10.1109/TBME.2007.903707
  • Tarniceriu, A., et al. (2018). The accuracy of atrial fibrillation detection from wrist photoplethysmography: a study on post-operative patients. 2018 40th Annual International Conference of the IEEE EMBC, 1-4. https://doi.org/10.1109/EMBC.2018.8513197
  • Bonomi, A. G., et al. (2018). Atrial fibrillation detection using a novel cardiac ambulatory monitor based on photo-plethysmography at the wrist. Journal of the American Heart Association, 7(15), e009351. https://doi.org/10.1161/JAHA.118.009351
  • Tison, G. H., et al. (2018). Passive detection of atrial fibrillation using a commercially available smartwatch. JAMA Cardiology, 3(5), 409-416. https://doi.org/10.1001/jamacardio.2018.0136
  • Shen, Y., et al. (2019). Ambulatory atrial fibrillation monitoring using wearable photoplethysmography with deep learning. Proceedings of the 25th ACM SIGKDD International Conference on Knowledge Discovery & Data Mining, 1909-1916. https://doi.org/10.1145/3292500.3330657
  • Shashikumar, S. P., Shah, A. J., Li, Q., Clifford, G. D., & Nemati, S. (2017). A deep learning approach to monitoring and detecting atrial fibrillation using wearable technology. 2017 IEEE EMBS International Conference on Biomedical & Health Informatics (BHI), 141-144. https://doi.org/10.1109/BHI.2017.7897225
  • Torres-Soto, J., & Ashley, E. A. (2020). Multi-task deep learning for cardiac rhythm detection in wearable devices. npj Digital Medicine, 3, 116. https://doi.org/10.1038/s41746-020-00320-4
  • Perez, M. V., et al. (2019). Large-scale assessment of a smartwatch to identify atrial fibrillation. New England Journal of Medicine, 381(20), 1909-1917. https://doi.org/10.1056/NEJMoa1901183
  • Guo, Y., et al. (2019). Mobile photoplethysmographic technology to detect atrial fibrillation. Journal of the American College of Cardiology, 74(19), 2365-2375. https://doi.org/10.1016/j.jacc.2019.08.019
  • Lubitz, S. A., et al. (2022). Detection of atrial fibrillation in a large population using wearable devices: the Fitbit Heart Study. Circulation, 146(19), 1415-1424. https://doi.org/10.1161/CIRCULATIONAHA.122.060291

Related articles

Dehydration Detection from PPG Signal Features: Methods, Evidence & Challenges

**Dehydration affects an estimated 75% of Americans chronically and causes approximately 500,000 hospitalizations annually in the United States alone,...

PPG vs ECG Accuracy Comparison: Heart Rate, HRV, and Arrhythmia Detection Data

PPG vs ECG accuracy compared for heart rate, HRV metrics, arrhythmia detection, and respiratory rate with published validation data and comparison tables.

PPG for Cardiac Monitoring: From Heart Rate to Heart Failure Detection

PPG is becoming a first-line cardiac monitoring tool. This guide covers validated applications: heart rate, HRV, atrial fibrillation, heart failure, and emerging ECG-free arrhythmia detection.

How Accurate Is Apple Watch Heart Rate? Clinical Evidence Review

A comprehensive clinical evidence review of Apple Watch heart rate accuracy, covering PPG sensor design, resting and exercise accuracy data from Shcherbina et al. (2017) and other studies, factors affecting accuracy like skin tone and tattoos, and comparison to chest strap monitors.

PPG as an Aortic Stiffness Biomarker: Evidence, Limitations, and Clinical Use

Aortic stiffness is one of the most powerful predictors of cardiovascular mortality — and it's been measured invasively since the 1960s. PPG waveform ...

Tachycardia Detection on Smartwatches: Accuracy, False Alarms, and When to Trust PPG

How accurate are smartwatch tachycardia alerts? Learn when PPG is useful, why false alarms happen, and when ECG confirmation is needed for safer care decisions.

Devices in this article

Research records with the datasets, papers and published validation results for each device.