Next Article in Journal
Advanced Dynamic Vibration of Terfenol-D Control Law on Functionally Graded Material Plates/Cylindrical Shells in Unsteady Supersonic Flow
Previous Article in Journal
GATransformer: A Graph Attention Network-Based Transformer Model to Generate Explainable Attentions for Brain Tumor Detection
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

ECG Signal Classification Using Interpretable KAN: Towards Predictive Diagnosis of Arrhythmias

1
School of Computer and Communication Engineering, University of Science and Technology Beijing, Beijing 100083, China
2
School of Electronics and Information Engineering, Liaoning University of Technology, Jinzhou 121001, China
3
Key Laboratory of Computing Power Network and Information Security, Ministry of Education, Shandong Computer Science Center (National Supercomputer Center in Jinan), Qilu University of Technology (Shandong Academy of Sciences), Jinan 250353, China
4
Shandong Provincial Key Laboratory of Computing Power Internet and Service Computing, Shandong Fundamental Research Center for Computer Science, Jinan 250000, China
*
Authors to whom correspondence should be addressed.
Algorithms 2025, 18(2), 90; https://doi.org/10.3390/a18020090
Submission received: 1 January 2025 / Revised: 30 January 2025 / Accepted: 4 February 2025 / Published: 6 February 2025

Abstract

:
To address the need for accurate classification of electrocardiogram (ECG) signals, we employ an interpretable KAN to classify arrhythmia diseases. Experimental evaluation of the MIT-BIH and PTB datasets demonstrates the significant superiority of the KAN in classifying arrhythmia diseases. Specifically, preprocessing steps such as sample balancing and variance sorting effectively optimized the feature distribution and significantly enhanced the model’s classification performance. In the MIT-BIH, the KAN achieved classification accuracy and precision rates of 99.08% and 99.07%, respectively. Similarly, on the PTB dataset, both metrics reached 99.11%. In addition, experimental results indicate that compared to the traditional multi-layer perceptron (MLP), the KAN demonstrates higher classification accuracy and better fitting stability and adaptability to complex data scenarios. Applying three clustering methods demonstrates that the features extracted by the KAN exhibit clearer cluster boundaries, thereby verifying its effectiveness in ECG signal classification. Additionally, convergence analysis reveals that the KAN’s training process exhibits a smooth and stable loss decline curve, confirming its robustness under complex data conditions. The findings of this study validate the applicability and superiority of the KAN in classifying ECG signals for arrhythmia and other diseases, offering a novel technical approach to the classification and diagnosis of arrhythmias. Finally, potential future research directions are discussed, including the KAN in early warning and rapid diagnosis of arrhythmias. This study establishes a theoretical foundation and practical basis for advancing interpretable networks in clinical applications.

1. Introduction

Cardiovascular disease remains one of the leading causes of morbidity and mortality among middle-aged and elderly individuals worldwide. Its detrimental effects on the heart, arteries, and venous systems result in alarmingly high rates of mortality and disability. According to the World Health Organization (WHO), cardiovascular disease accounts for approximately 17.9 million deaths annually, representing 32% of global mortality [1]. This sobering statistic underscores the critical need for early prevention and diagnosis. Arrhythmia represents a prevalent and intricate pathological condition within the spectrum of cardiovascular diseases. Accurate classification of electrocardiogram (ECG) signals enables early intervention, thereby substantially reducing mortality risk. Consequently, achieving a higher accurate and cost-effective diagnosis of arrhythmias, along with the assessment of normal heart rhythms, constitutes a primary objective of ongoing research.
The ECG is a widely utilized, non-invasive diagnostic tool that provides critical physiological insights by recording the heart’s electrical activity. Compared to the traditional stethoscope [2], the ECG offers superior resolution and diagnostic accuracy. However, as the volume of ECG data grows and signal complexity increases, manual interpretation has become insufficient to meet clinical demands. Consequently, automated ECG signal classification has emerged as a vital research focus in advancing arrhythmia diagnosis.
The pathological mechanisms of arrhythmias are multifaceted and diverse, primarily involving abnormal activities in the heart’s origin and conduction processes [3]. Based on heart rate differences, arrhythmias are categorized as rapid or slow. Rapid arrhythmias feature a resting heart rate exceeding 100 beats per minute, whereas slow arrhythmias involve a resting heart rate below 60 beats per minute. Per the classification standards of the American Association for the Advancement of Medical Instrumentation (AAMI), non-life-threatening arrhythmias are classified into five types: non-ectopic (N), supraventricular ectopic (S), ventricular ectopic (V), fusion rhythm (F), and unknown type (Q) [4]. These ECG classifications hold significant clinical importance, and their accurate identification is crucial for formulating effective treatment plans.
In recent years, deep learning (DL) techniques have emerged as promising solutions for the automated classification of ECG signals. Unlike traditional machine learning (ML) approaches, DL algorithms enable direct feature extraction within an end-to-end framework, eliminating the labor-intensive task of manual feature engineering. Notably, the Kolmogorov–Arnold Network (KAN) [5] demonstrates significant promise in addressing complex signal classification tasks, owing to its theoretical interpretability and robust nonlinear mapping capabilities. Nonetheless, research on the application of the KAN in ECG signal classification remains blank, necessitating further investigation into its classification performance and transferability across various arrhythmia categories.
This study employs the KAN to automate the classification of ECG signals and evaluates its efficacy in arrhythmia classification tasks using the MIT-BIH dataset. To further assess the generalization of KAN, the model was transferred to the PTB dataset for classification predictions in MI diagnosis. Additionally, the performance of the KAN was compared with that of classical machine learning, such as the multi-layer perceptron (MLP) and recent DL, to comprehensively evaluate its classification accuracy, generalization capability, and computational efficiency.
The remainder of this paper is structured as follows: Section 2 reviews related research on arrhythmia classification; Section 3 details the study’s methodology; Section 4 presents the experimental results and comparative analysis; and Section 5 concludes with a summary of the research contributions and prospective future directions.

2. Literature Study

Artificial intelligence (AI), described by John McCarthy as “the science and engineering of making intelligent machines” [6], has profoundly influenced numerous fields over the past two decades, including visual perception, intelligent manufacturing, and knowledge representation and reasoning. In recent years, AI has been increasingly adopted in the medical field due to its robust data analysis capabilities and ability to deeply mine complex patient information, enabling accurate disease prediction and diagnosis through data-driven insights.
As a vital branch of AI, machine learning (ML) constructs data models to perform classification tasks by leveraging adaptive learning and evolving mathematical algorithms. However, traditional ML is constrained by its reliance on manual feature extraction, which introduces inherent limitations. Deep learning (DL), an advancement of ML, surpasses traditional methods in data modeling efficiency and accuracy through its multi-layer neural network architecture and capability to automatically learn features from hidden layers. Consequently, DL has become a pivotal tool for medical image classification, disease diagnosis, and medical signal analysis. Nonetheless, the “black box” nature of DL [7], referring to the lack of interpretability in its feature learning processes, constrains its potential applications in high-reliability fields like arrhythmia classification.
Machine learning has been extensively employed in arrhythmia classification, primarily due to its inherent interpretability. Some representative studies are outlined below. Dolatabadi et al. [8] utilized support vector machines (SVMs) for classifying ECG signals in long-term ST datasets. They integrated heart rate variability (HRV) signal extraction and principal component analysis to achieve a classification accuracy of 99.20%. Kumar S. U. et al. [9] developed the NRSC based on the MIT-BIH dataset, utilizing a discrete wavelet transform for noise reduction and feature extraction, followed by classification using Euclidean Distance, achieving a diagnostic accuracy of 99.32%. For the PTB, Acharya et al. [10] extracted nonlinear features using the wavelet transform combined with statistical analysis techniques to optimize classification results, achieving a classification accuracy of 98.80% for distinguishing cardiac diseases from normal signals. The integration of encoders has expanded the diversity of ECG signal classification tasks. Using the PTB, Zhang et al. [11] employed stacked sparse autoencoders and Tree Bagger classifiers to enhance classification interpretability.
While these machine learning-based approaches have achieved notable success in ECG signal analysis, they often depend on manual feature extraction, which increases model development complexity and limits scalability in large-scale applications. DL has exhibited exceptional performance in ECG signal classification, leveraging automated feature learning and end-to-end training to address these limitations.
Feng et al. [12] attained 95.4% accuracy and 98.2% sensitivity on the PTB by integrating a 16-layer convolutional neural network (CNN) with a long short-term memory (LSTM) network. Leveraging the feature-capturing capabilities of neural networks and the attention mechanism enhances the focus and representation of key features. Consequently, Liu et al. [13] introduced an attention-based convolutional neural network (ABCNN), achieving an accuracy of 98.53% on the MIT-BIH dataset. Additionally, Hu et al. [14] developed a transformer-based deep model, ECG DETR, which attained an accuracy of 99.23% on the MIT-BIH. While DL outperforms traditional machine learning in ECG signal analysis, its inherent lack of interpretability remains a significant challenge, reducing clinicians’ trust in the model’s decision-making process. To address this limitation, this paper investigates the application of the interpretable KAN for classifying ECG signals related to arrhythmia-like diseases.
This study introduces a KAN model grounded in the Kolmogorov–Arnold theorem. By incorporating a learnable activation function into the deep learning framework, the model integrates interpretability with superior ECG signal classification performance. Specifically, by substituting traditional linear weights with nonlinear weights, the KAN preserves the benefits of deep learning for processing large-scale data while improving adaptability to intricate functional relationships.
The primary advantages are as follows:
(1)
Integration of automation and interpretability: The KAN not only automatically extracts multi-layered features from ECG signals but also offers clear explanations for the physical significance of these features.
(2)
Enhanced capability to address the complexity of ECG data: The KAN’s structural design is particularly suited for processing multi-view and multi-scale features inherent in arrhythmia signals.
(3)
Reliability and practical applicability: By improving the model’s adaptability to the distribution and characteristics of ECG data, the KAN achieves higher classification accuracy, offering a dependable foundation for clinical diagnosis.
In summary, the KAN model not only retains the strengths of deep learning but also addresses its interpretability limitations, offering a novel approach to ECG signal classification. The following section delves into recent ML and DL in arrhythmia research, highlighting the KAN’s innovations and advancements in tackling ECG classification challenges.

3. Materials and Methods

This study seeks to classify ECG signals for the diagnosis of various arrhythmia diseases using an interpretable KAN. The methodology comprises three primary components: data preprocessing, model architecture, and evaluation analysis. Sample balanced and variance sorting are employed to preprocess ECG signals. Subsequently, the classification performance of ECG signals is compared between the KAN and MLP models, highlighting the advantages of the interpretable KAN model through data analysis techniques such as feature clustering and fuzzy matrices. Figure 1 outlines the entire workflow, which is elaborated upon in subsequent sections.

3.1. Data Description

This study utilizes the MIT-BIH arrhythmia dataset and the PTB diagnostic dataset as primary data sources [15] for annotating ECG signals, as detailed below. The MIT-BIH dataset, a widely recognized standard in arrhythmia classification tasks, comprises ECG signals recorded from 47 subjects at a sampling rate of 360 Hz. Each record was annotated by at least two cardiologists and categorized into five classes based on the EC57 standard of the Association for the Advancement of Medical Instrumentation (AAMI) [4]. These categories correspond to clinically prevalent arrhythmia patterns. The mapping relationships between heartbeat annotations in each category are in Table 1. This dataset serves as a high-quality benchmark for automated arrhythmia detection and classification.
The PTB dataset consists of 549 ECG records from 290 subjects, including 148 diagnosed with myocardial infarction (MI), 52 healthy controls, and the remainder encompassing diagnostic records for seven additional heart diseases. Each ECG record comprises a 12-lead signal sampled at 1000 Hz, offering exceptionally high temporal resolution. In this study, only lead II data were analyzed, focusing on signal differences between myocardial infarction patients and healthy controls to support diagnosis and classification tasks in related experiments.
The selection of these two high-quality datasets ensures the diversity and accuracy of the experimental data, offering a robust foundation for training and evaluating ECG signal classification models.

3.2. Data Preprocessing

Regarding the applicable data of the interpretable model KAN, we were inspired by Kachuee M. et al. [16] and improved the data preprocessing process of MIT-BIH, as shown in Figure 2.
The original data were segmented using a 10 s time window, followed by normalization, filtering of the maximum value set for first-order derivative zero features, threshold-based filtering of the R-peak candidate set, setting a 1.2 T heartbeat cycle, and standardizing to a uniform dimension. Additionally, feature extraction was conducted using a combination of sample balanced and variance reordering.
Each selected segment was zero-padded to ensure a fixed length of 188. The range [0, 186] represents the ECG signal, while the 187th position serves as the arrhythmia category marker. Variance feature analysis was applied to both the original and sample-equalized ECG data. For both data types, the datasets were reordered based on the variance of their time series. This reordering resulted in a pseudo-time series representation of the ECG. Figure 3 illustrates the time feature distribution before and after sorting.

3.3. Feature Analysis of Data

Cluster analysis [17] is an unsupervised learning technique that organizes data objects into distinct groups or clusters. The primary objective of clustering is to ensure that data points within the same cluster exhibit high similarity, while maintaining significant differences between points in different clusters. By uncovering the intrinsic structure of data, clustering methods facilitate visualization and provide valuable insights for explanatory analysis of feature distributions. In this study, three classic clustering techniques are employed to analyze and visualize both the original ECG signal data and the features extracted by the KAN, highlighting the advantages of the KAN in feature extraction.
(1)
BIRCH (Balanced Iterative Reducing and Clustering Using Hierarchies) [18] is a hierarchical clustering method that efficiently performs clustering operations by constructing a clustering feature tree (CF Tree). The CF Tree, similar in structure to a balanced B+ tree, contains nodes composed of clustering features (CFs), which are represented as a triple (N, LS, SS). Here, N denotes the number of sample points in a cluster, LS represents the linear sum of feature dimensions, and SS is the sum of squares vector. In the context of ECG signal feature clustering, BIRCH captures both the global structure and local patterns of signals through hierarchical and recursive cluster merging, making it well-suited for fast clustering of large-scale datasets. This study compares the clustering outcomes of original features and KAN-extracted features using BIRCH, aiming to demonstrate the ability of the KAN to optimize feature distribution.
(2)
MeanShift [19] is a nonparametric, density-based clustering method that estimates the probability density of a dataset using a kernel function. It iteratively shifts data points along the density gradient toward regions of highest density, known as mode points. Each data point converges to a high-density region, achieving automatic clustering. In this study, MeanShift clustering is applied to identify high-density feature distribution regions within ECG signals.
(3)
Spectral Clustering [20] is a graph theory-based method that constructs a similarity graph among data points, representing data relationships as a weighted graph matrix. The eigenvalues and eigenvectors of the graph’s Laplacian matrix are then utilized for dimensionality reduction and clustering. Spectral clustering excels at handling complex, nonlinear data distributions and is particularly effective for uncovering latent high-dimensional nonlinear structures within ECG signals. This study visualizes the clustering results of both original features and KAN-extracted features through spectral clustering, highlighting the KAN’s superior performance in preserving nonlinear signal characteristics and capturing intricate relationships within the feature space.

3.4. Interpretable KAN Model

The Kolmogorov–Arnold Network (KAN) is an innovative neural network architecture developed based on the Kolmogorov–Arnold representation theorem [5]. Unlike traditional neural networks, which rely on a fixed combination of linear weights and activation functions for feature extraction, the KAN incorporates a dynamically learnable univariate function. This enhancement significantly improves the model’s capacity to address nonlinear problems and its interpretability. Given the complexity of ECG signals and the pronounced nonlinear characteristics of arrhythmia classification tasks, the KAN emerges as a particularly well-suited modeling approach for this domain. For ECG signal classification tasks, the Kolmogorov–Arnold representation theorem [5] demonstrates that any continuous multivariate function can be expressed as the sum of several continuous univariate functions.
f ( x ) = q = 1 2 n + 1 Φ q ( p = 1 n φ q , p ( x p ) )
where f ( x ) is the function output, which represents the predicted value of input x . 2n + 1 is the upper limit of the outer summation, which is related to the input dimension n. Φ q is the q-th function of the outer summation, φ q , p ( x p ) is the combination of the q-th and p-th functions, and x p is the p-th component of the input vector.
The original KAN [5] is fixed at [n, 2n + 1, 1], and the original structure is changed by introducing the KAN layer definition, where the KAN layer is a one-dimensional function matrix defined as equation
  Φ = { φ q , p }
In the Kolmogorov–Arnold representation theorem [5], a KAN layer is composed of several internal functions. For example, Equation (1) is composed of two KAN layers. The shape of the KAN is represented by an integer array as   [ n 0 ,   n 1 ,   ,   n L ] .   n i is the number of nodes in the i -th layer of the computational tree, and   ( l , i ) is used to represent the   i -th neuron in the   l -th layer. There are   n l n l + 1 activation functions between the   l layer and the next layer (   l + 1 ). The activation function connecting   ( l , i ) and   ( l + 1 , j ) is
φ l , j , i ,   l = 0 ,     ,   L - 1 ,   i = 1 ,     ,   n l ,   j = 1 ,   ,   n l + 1
Simply stacking KANs can expand the KAN structure to any width and depth and further determine the transfer matrix between input and output. In other words, the activation value of the   ( l + 1 , j ) neuron is simply the sum of all incoming post-activations. The calculation process is shown in Equation (4).
x l + 1 = φ l , 1 , 1 ( ) φ l , 1 , 2 ( ) φ l , 1 , n l ( ) φ l , 1 , 1 ( ) φ l , 2 , 2 ( ) φ l , 2 , n l ( ) φ l , n l + 1 , 1 ( ) φ l , n l + 1 , 2 ( ) φ l , n l + 1 , n l ( ) Φ l x l
Among them, x l + 1 is the output of the   l + 1 layer. φ l , j , i ( ) is the activation function of each oblique edge, and x l is the input of the l -th layer. In addition, Φ l is the function matrix corresponding to the l -th KAN layer. If the above multi-layer function cascade relationship is written in matrix form, the output expression of the KAN is
KAN ( x ) = ( Φ l - 1 Φ l - 2 Φ 1 Φ 0 ) x
In the ECG signal classification task, x represents the input ECG signal, and KAN ( x ) represents the output of the KAN. This paper sets the KAN model as a 2-layer structure for the ECG signal classification task, and the framework principle is shown in Figure 4. The activation function in the KAN structure is dynamic, and the vertical slash in the structure diagram represents the learning activation function, while the node only represents the summation of the function.
For the arrhythmia classification task, the input dimension of the KAN corresponds to the length of the ECG signal (187), the classification output dimension is 5, and the intermediate node count is 128. The residual activation function serves as the core component of the KAN model. During training, the quadratic spline residual value sampling method iteratively samples and fits the function, thereby learning an optimal activation function. A critical step in optimizing the KAN layer involves defining the activation function as the sum of the basis and the spline function. This means that the activation function φ ( x ) is represented as the sum of the basis function b ( x ) and the spline function [5]. The calculation formula is as follows:
φ ( x ) = b ( x ) + spline ( x )
b ( x ) = silu ( x ) = x 1 + e x
The spline function is usually parameterized as a linear combination of splines:
spline ( x ) = i c i B i ( x )
In the classification of arrhythmia diseases by ECG signals, c i is a trainable parameter used to adjust the weight of each spline function. B i ( x ) is the spline function of B , which is used to form a spline combination. In addition, we further explored the characteristics of the KAN in adapting to ECG signal classification of arrhythmia diseases. It includes three parts, as described below:
(1)
KAN incorporates a learnable univariate function. As demonstrated in Equation (8), the weight of each edge is not a fixed value but rather a dynamically learnable univariate function. This design enables flexible application of complex nonlinear transformations on each edge, thus enhancing the capture of characteristic distributions in ECG signals.
(2)
Feature visualization facilitates the interpretation of ECG signal feature distributions. In the arrhythmia classification task, when different categories of ECG signals are input, key features—such as QRS waveforms or characteristic signal change curves—exhibit progressively significant classification differences.
(3)
The tree structure diagram illustrates the forward propagation process. As illustrated in Figure 4, the tree structure represents each node as a feature combination, with edges denoting the dependency relationships between features. This representation strategy aids in understanding the model’s decision-making mechanism and offers potential clinical interpretability, such as elucidating synergies among ECG signals.
In summary, the KAN’s [5] dynamic nonlinear modeling capabilities and robust interpretability render it particularly well-suited for ECG signal classification tasks, offering new opportunities for precise intelligent diagnosis of arrhythmia diseases and clinical decision-making support.

3.5. Loss Calulation Method for ECG Signal Classification

The ECG signals exhibit non-stationarity, multi-class challenges, and class imbalance. Specifically, the heart rhythm patterns fluctuate over time, with the signal exhibiting significant variability. In the presence of various arrhythmias, normal heart rhythm data typically outnumber the abnormal categories. These characteristics pose challenges to the identification of heart rhythm patterns in ECG signals. However, cross-entropy loss [21] (CEL) is a classification model with probabilistic outputs adaptable to the multi-class classification challenges posed by ECG signals. CEL excels at class distinction by optimizing the predicted probability distribution, reducing confusion between heart rhythm categories and improving classification accuracy.
Additionally, ECG signals may contain artifacts or noise. The CEL function, optimized in the probability space, possesses inherent noise resistance, making it particularly suitable for the ECG signal classification task. Therefore, in the ECG signal classification, we employ the CEL function to quantify the discrepancy between the predicted output and the ground true classification label, evaluating the degree of deviation in the probability distribution of ECG signals, as shown in the following equation:
L o s s = 1 N i = 0 N 1 c = 1 C y i , c l o g ( y ^ i , c )
N denotes the total number of samples used in ECG signal classification training. C is the number of categories (N, S, V, F, Q). y i , c is the ground true label of ECG signal sample i belonging to category c , while y ^ i , c is the predicted probability of sample i corresponding to category c , and c = 1 C y i , c = 1 . By minimizing the classification Loss, the predicted label y ^ i , c is made as close to the true label y i , c as possible, thereby improving the accuracy of heart rhythm pattern identification.

4. Experimental Results and Analysis

4.1. Experimental Detail

To demonstrate the suitability of the KAN for ECG signal classification tasks, we conducted comprehensive experimental analyses on the MIT-BIH dataset. Initially, we employed a Multi-Layer Perceptron (MLP) to classify ECG signals, establishing a baseline for evaluating the effectiveness of the KAN. Subsequently, we compared the performance of various models proposed in previous studies on ECG signal classification, highlighting the superiority of the KAN in arrhythmia triage. Furthermore, we evaluated the migration and generalization capabilities of the KAN using the PTB dataset. Finally, we analyzed the convergence properties and clinical application potential of the KAN during the experiments.
The KAN was trained using a learning rate of 5 × 10−5 and the Adam optimizer [22]. The batch size was set to 64, and the number of epochs was set to 150. The input dimension was 187, the hidden layer size was 128, with output dimensions of 5 for MIT-BIH and 2 for PTB. Other parameters, including the scale spline and grid eps, were set to 1.0 and 0.02, respectively. Additionally, SiLU was employed as the activation function, and the grid range was set to [−1, 1]. All experiments were conducted and evaluated using Python 3.9 and PyTorch 1.12.1, with the experimental hardware comprising an NVIDIA GeForce RTX 4050 Laptop GPU.
During the experiment, we used repeated random sampling to equalize the heart rhythm categories (N, S, V, F, Q) of the samples, with the random_state set to 42, 123, 124, 125, and 126, respectively. Additionally, the random_state ensures consistency in the results of KAN construction and ECG data splitting, facilitating reproducibility and comparison of the model.

4.2. Experimental Evaluation Metrics

We use multiple performance metrics (including F1 score, AUC, accuracy (Acc), precision (P), and recall (R)) to compare the experimental results. These comparison metrics are consistent with the research of Majhi B. et al. [23]. The basic result of calculating all performance metrics is a two-dimensional confusion matrix, which represents true positives (TPs), true negatives (TNs), false positives (FPs), and false negatives (FNs). The calculation formula for each performance metric stands for the following equations:
A c c = T P + T N T P + T N + F P + F N
P = T P T P + F P
R = T P T P + F N
F 1 = 2 × P × R P + R
Among them, TP represents the number of actual positive results, TN is the number of actual negative results, FP is the number of false positive results, and FN is the number of false negative results. In addition to TPR (True Positive Rate) and FPR (False Positive Rate), the AUC (Area Under the Curve) score can also be calculated through the receiver operating characteristic (ROC) curve.

4.3. Experimental Results

The ECG signal classification experiments using the KAN were performed on the original MIT-BIH dataset, the original PTB dataset, and their respective versions after balanced and variance sorting. To demonstrate its superiority, we conducted comparative experiments with an MLP, and the results are presented in Table 2, Table 3, Table 4 and Table 5.
As shown in Table 2, on the original MIT-BIH dataset, the average accuracy (97.68%) and precision (93.19%) of the KAN exceed those of MLP (97.62% and 87.06%), with a particularly notable improvement in precision. This demonstrates that the KAN achieves higher accuracy and precision in classifying specific categories of unbalanced raw data and effectively captures arrhythmia features. Moreover, the F1 score (87.50%) is slightly better than that of MLP (85.08%), further highlighting the overall superior performance of the KAN. Although the recall rate of the KAN (82.47%) is slightly lower than that of MLP (83.18%), the KAN’s performance surpasses MLP after data balancing and variance sorting.
As shown in Table 3, the KAN achieves a precision of 99.07% and recall of 98.99%, compared to MLP’s precision of 98.22% and recall of 98.14%. The processed KAN achieves an F1 score of 99.03% and an average accuracy of 99.08%, demonstrating superior adaptability and feature extraction capabilities for processed signal data. These findings suggest that the KAN’s performance is fully optimized after data distribution adjustments, allowing it to excel in a more balanced environment.
In the classification of arrhythmia diseases using ECG signals, the KAN’s nonlinear feature extraction capabilities can more accurately capture subtle pattern variations in ECG signals. Notably, the KAN demonstrates unique advantages in distinguishing categories with similar signal morphologies yet significant pathological differences.
To demonstrate the transferability and generalization capability of the KAN in ECG signal classification tasks, the KAN exhibited clear advantages on the original PTB dataset. As shown in Table 4, the KAN achieves a precision of 97.90% and recall of 97.97%, surpassing MLP’s precision of 95.06% and recall of 95.26%. The F1 score and average accuracy improved to 97.97% and 97.68%, respectively. Table 2 and Table 4 demonstrate that the KAN is more effective in extracting key features from complex ECG signals.
Notably, the KAN’s classification performance is further optimized after data balanced and variance sorting. Similarly, as shown in Table 5, the KAN achieves an accuracy of 99.11%, with precision and recall exceeding 98.82%, slightly better than MLP’s accuracy (97.40%), precision (97.45%), and recall (97.35%). These results indicate that the KAN is better suited to adapt to the characteristic changes in ECG signals after data processing.
To further demonstrate the model’s stability and robustness during training, we analyzed the average accuracy fit between the training and validation sets for both models across different datasets, as shown in Appendix A.1. The accuracy fitting analysis in Appendix A.1 reveals that in four cases, the accuracy fit between the training and validation sets for the KAN is significantly better than that of MLP. On the MIT-BIH dataset, the accuracy fit between the training and validation sets was nearly identical, with the smoothest data and minimal fluctuations in accuracy. However, on both the MIT-BIH and PTB datasets, MLP exhibited the lowest accuracy fit during the early stages of the fitting process (epochs <30), accompanied by significant fluctuations in validation set accuracy. For epochs >30, MLP’s accuracy interpolation was significantly higher than that of the KAN.
Consequently, in classifying arrhythmia diseases using ECG signals, the KAN demonstrates higher accuracy and superior robustness and fitting stability than MLP. This analysis underscores the KAN’s superiority in handling ECG signal classification tasks, as evidenced by its overall performance and accuracy fitting. To evaluate the classification performance for specific categories of heart failure, we plotted the confusion matrix [24] and ROC curve [25] for the MIT-BIH dataset after balanced and variance sorting, highlighting the KAN’s superiority in classification precision across various heart failure categories, as shown in Figure 5.
On the MIT-BIH dataset, after balanced and variance sorting, the overall classification performance of the KAN surpasses that of MLP. As depicted in Figure 5, MLP demonstrates high sensitivity to categories 3 and 1, achieving accuracies exceeding 99%. However, its classification performance for categories 0, 1, and 2 is relatively weaker, particularly for category 0, where accuracy only reaches 94.63%. Furthermore, Figure 5a reveals that category 0 is frequently misclassified as category 1. Although the KAN also exhibits occasional misclassification for category 0, its recognition accuracy improves significantly, reaching 96.77%. Moreover, the KAN achieves classification accuracies exceeding 99% for categories 1, 3, and 4, while maintaining a strong performance of 98.99% for category 2, as shown in Figure 5c.
In Figure 5b, the AUC values for MLP across all categories range between 0.9962 and 0.9998, indicating its solid classification performance on the dataset post-processing. However, category 0 shows the lowest AUC value, suggesting a slightly weaker discriminatory capability in this category. In contrast, Figure 5d demonstrates that the AUC values for all categories with the KAN are exceptional, reaching 0.999, which approaches the theoretical upper-performance limit for classification models. The ROC curve for the KAN is near the upper-left corner, reflecting balanced and superior classification performance across all categories.
Figure 5 illustrates that the KAN outperforms MLP in terms of ROC curve performance, particularly when the discrimination performance nears the upper limit. This highlights the KAN’s enhanced adaptability for feature extraction and its ability to effectively separate categories, further cementing its advantage in ECG signal classification tasks.
In summary, balanced and variance sorting of the dataset significantly enhance the model’s ability to distinguish between different categories, particularly in addressing the challenges posed by uneven category distribution. While MLP demonstrates a commendable capacity to classify ECG signals, it still exhibits misclassification issues for certain categories. In contrast, the KAN outperforms MLP across all categories, achieving a remarkably low misclassification rate and presenting an ROC curve that approaches the ideal state. It indicates the KAN’s superior classification capability for heart failure signals.
Given its exceptional classification performance and strong generalization ability, the KAN is well-suited for application in high-risk clinical scenarios. Its reliable and accurate classification makes it a valuable tool for supporting the automatic diagnosis of heart failure, offering robust and trustworthy assistance in medical decision-making.

4.4. Cluster Feature Distribution

This study applies three clustering algorithms to the original MIT-BIH dataset and the feature vectors output by the KAN for comparison. The experimental results are illustrated in Figure 6. A comparison of the clustering effects reveals that the performance on the original MIT-BIH dataset under the MeanShift and Spectral algorithms is suboptimal. The data boundaries are indistinct, with significant overlap between multiple clusters, making effective differentiation challenging, as depicted in Figure 6A. Notably, under the Spectral algorithm, only one cluster is discernible, indicating that the dataset’s graph features are insufficient to support effective clustering.
In contrast, when clustering is applied to the feature vectors produced by the KAN, as shown in Figure 6B, the boundaries between categories become distinctly visible. This demonstrates the KAN’s significant efficacy in feature extraction from the original MIT-BIH dataset, providing enhanced support for predicting heart failure classifications.

4.5. Comparison with the Existing Models of the Literature

We conducted a comparative analysis of the results from various prior studies on the MIT-BIH and PTB datasets. Evidently, the KAN, after balanced and variance sorting, demonstrates superior performance in classifying ECG signals. Table 6 presents the state-of-the-art results achieved on the MIT-BIH, while Table 7 highlights the advanced outcomes on the PTB.
The accuracy of the KAN in Table 6 reaches 99.08%, which is 0.43% higher than the 98.66% achieved by the highest-performing study from Kumar S. et al. [30]. It also shows improvements of 0.44% and 0.45% over the results of Liu. et al. [13] and Wang J. et al. [27], respectively. The most notable gains are observed when compared to the accuracies of Kachuee M. et al. [16] (93.40%) and Al-Shammary D. et al. [32] (86.67%), with increases of 6.08% and 14.32%, respectively. In terms of classification precision, the KAN achieves the highest value of 99.07%, surpassing the second-best result of 98.92% by Kumar S. et al. [30] by 0.15%. The improvements are particularly significant compared to Al-Shammary D. et al. [32], showing an increase of 14.74%.
However, the recall rate of the KAN is not the highest, with Shaker et al. [26] and Hammad M. et al. [29] achieving 99.77% and 99.70%, respectively. Nonetheless, the KAN demonstrates comparable recall performance to Wang J. et al. [27], and its recall rate shows a significant improvement over several other models.
Overall, the KAN achieves substantial improvements in accuracy and precision, marking a new performance benchmark for ECG signal classification. While its recall rate is slightly lower than the top-performing models, the gap is minimal. For classification tasks in medical signal processing (especially ECG signal classification) enhancements in accuracy are crucial, as even small improvements can greatly reduce misdiagnosis and missed diagnosis rates. Compared to studies with lower performance (e.g., Kachuee M. et al. [16] and Al-Shammary D. et al. [32]), the KAN exhibits superior adaptability, highlighting its suitability for complex categories and imbalanced data distributions.
To further validate the universality and generalization capability of the proposed ECG signal classification strategy, we conducted comparative analyses on the PTB, as shown in Table 7.
The statistical results in Table 7 further confirm that the KAN is highly suitable for the classification of ECG signals, demonstrating its advanced performance. Notably, the improvements in accuracy and precision are particularly significant. While Sharma L. N. et al. [33] achieved a precision of 99.00%, it remains slightly lower than the KAN’s 99.11%. In terms of recall, the KAN outperforms existing classification methods, with a best result of 98.82%, marginally exceeding Islam R. et al. [34]’s 98.00%. Taken together, the KAN emerges as the most effective classification method overall. Table 7 underscores the universality, generalization capability, and superior performance of the KAN in the ECG signal classification task.

4.6. Convergence Study of Loss

The convergence characteristics of the KAN and MLP models were compared using both the original MIT-BIH dataset and the dataset after balanced and variance sorting, as shown in Figure 7 and Figure 8. The KAN converged after approximately 80 training epochs, whereas the MLP model stabilized and reached convergence within about 30 epochs. Although the MLP model demonstrated a faster convergence speed, the KAN exhibited superior stability in loss reduction, with a significantly lower final convergence value compared to MLP. This indicates that the convergence trend and final loss value of the KAN are more favorable than those of MLP. Additionally, the loss curve of the KAN displays a stable and smooth downward trajectory, reflecting its enhanced robustness and stability when handling complex or noisy data.
Closer examination of Figure 7b and Figure 8b reveals that MLP experiences noticeable jumps in its loss value during the initial training phase, despite showing relatively minor fluctuations in the validation set. This behavior suggests that MLP may be prone to overfitting during the training process.

5. Discussion

This study proposed an interpretable KAN for the classification of ECG signals and evaluated its performance and adaptability using the MIT-BIH and PTB datasets. The findings highlight that data preprocessing plays a critical role in enhancing classification outcomes. By applying balanced and variance sorting, the data distribution was effectively optimized, significantly improving the KAN’s feature representation capabilities. On the MIT-BIH, the classification accuracy reached 99.08%, with a precision rate of 99.07%, while on the PTB, both classification accuracy and precision reached 99.11%. These results underscore the importance of data preprocessing and demonstrate the robustness and transferability of the KAN across different datasets.
To further analyze the performance of the KAN, this study compared the classification results of the KAN and MLP models under four experimental conditions. The results reveal that the KAN exhibited superior fitting capabilities during both the training and testing phases, achieving significantly higher accuracy than MLP. Additionally, the training process of the KAN was more stable, effectively avoiding overfitting. Furthermore, to validate the discriminative power of the features extracted by the KAN, hierarchical clustering, density clustering, and spectral clustering were applied to analyze its feature vectors. A comparison between the clustering distributions of original features and KAN-extracted features reveals significant improvements in capturing key mode points and the underlying distribution patterns of ECG signals, validating the KAN’s adaptability for classification tasks in complex signal processing. The experiments demonstrated that, compared to the original data, the feature boundaries extracted by the KAN were more distinct and better support ECG signal-based disease classification tasks.
Compared to existing research results (e.g., Shaker et al. [26] and Wang J. et al. [27]), the KAN demonstrates significant advantages across multiple metrics. On the MIT-BIH, its classification accuracy is notably higher, and its precision reaches a state-of-the-art level. Similar advancements are observed in the PTB, further validating its robustness. These improvements are evident not only in classification performance but also in the model’s convergence behavior. Experimental results indicate that, regardless of whether the data undergoes preprocessing, the KAN exhibits a smooth and rapid convergence curve during training, highlighting its stability and adaptability in complex data scenarios.
The findings of this study propose a novel approach for disease classification and triage based on ECG signals and reveal the potential of the KAN for wide application in diagnosing conditions such as arrhythmias and heart failure. Future research will focus on integrating the KAN with other network architectures, such as convolutional neural networks, to enhance classification performance. Additionally, large-scale and diverse datasets will evaluate the model’s robustness. Efforts will also aim to strengthen the interpretability of the model, providing deeper insights to support clinical decision-making. Developing real-time monitoring modules represents another critical direction, enabling early warning and rapid diagnosis of arrhythmias.

6. Conclusions

This study proposed an interpretable KAN for ECG signal classification, aimed at the classification and triage of cardiac diseases such as arrhythmias. Experimental validation on the MIT-BIH and PTB datasets demonstrated that data preprocessing techniques, including balanced processing and variance sorting, significantly enhanced the model’s classification performance. The preprocessed KAN achieved classification accuracies exceeding 99% on both datasets, with precision and recall rates also reaching optimal levels. Compared to existing studies, the KAN exhibited notable advantages in classification accuracy, fitting stability, and the discriminative power of feature extraction. Further analysis revealed that the KAN not only effectively captures key features in ECG signals but also produces feature representations with clearer classification boundaries under three clustering methods, underscoring its adaptability and generalization capabilities in complex data scenarios.
This research offers a novel technical approach for ECG signal classification and identifies future directions for development, such as integrating the KAN with other network architectures, incorporating large-scale datasets to evaluate the model’s robustness, and developing real-time monitoring functionalities. These advancements provide robust support for clinical diagnosis and highlight the potential of interpretable networks in advancing clinical research applications.

Author Contributions

H.C.: Conceptualization, Data curation, Formal analysis, Investigation, Methodology, Software, Validation, Visualization, Writing—original draft. S.N.: Conceptualization, Formal analysis, Investigation, Resources, Visualization. S.W.: Formal analysis, Software, Validation. W.Z.: Formal analysis, Methodology, Software, Validation, Funding acquisition. Y.P.: Supervision. All authors have read and agreed to the published version of the manuscript.

Funding

This research was funded by the open project of the Key Laboratory of Computing Power Network and Information Security, Ministry of Education, grant number 2023ZD015.

Data Availability Statement

The data used in this study are online available at https://www.kaggle.com/datasets/shayanfazeli/heartbeat?resource=download (1 January 2025).

Conflicts of Interest

The authors declare no conflicts of interest.

Abbreviations

The following abbreviations are used in this manuscript:
AAMIAmerican Association for the Advancement of Medical Instrumentation
DLDeep Learning
MLMachine Learning
KANKolmogorov–Arnold Network
MLPMulti-Layer Perceptron
AIArtificial Intelligence

Appendix A

Appendix A.1. Comparative Analysis of the Accuracy of the Training Set and the Validation Set

Appendix A.1 gives the fitting analysis of the accuracy (ACC) during training and validation on four different datasets. Obviously, the accuracy of the KAN in the four cases is better than that of MLP, and the fitting degree is the best.
Figure A1. Comparison of the accuracy of the original MIT-BIH dataset.
Figure A1. Comparison of the accuracy of the original MIT-BIH dataset.
Algorithms 18 00090 g0a1
Figure A2. Comparison of the accuracy of the MIT-BIH dataset after balanced and variance sorting.
Figure A2. Comparison of the accuracy of the MIT-BIH dataset after balanced and variance sorting.
Algorithms 18 00090 g0a2
Figure A3. Comparison of the accuracy of the original PTB dataset.
Figure A3. Comparison of the accuracy of the original PTB dataset.
Algorithms 18 00090 g0a3
Figure A4. Comparison of the accuracy of the PTB dataset after balanced and variance sorting.
Figure A4. Comparison of the accuracy of the PTB dataset after balanced and variance sorting.
Algorithms 18 00090 g0a4

References

  1. Factsheet Cardiovascular Diseases (cvds). Available online: https://www.who.int/news-room/fact-sheets/detail/cardiovascular-diseases-(cvds) (accessed on 13 October 2021).
  2. Deng, M.; Meng, T.; Cao, J.; Wang, S.; Zhang, J.; Fan, H. Heart sound classification based on improved MFCC features and convolutional recurrent neural networks. Neural Netw. 2020, 130, 22–32. [Google Scholar] [CrossRef] [PubMed]
  3. Huizar, J.F.; Kaszala, K.; Tan, A.; Koneru, J.; Mankad, P.; Kron, J.; Ellenbogen, K.A. Abnormal conduction-induced cardiomyopathy: JACC review topic of the week. J. Am. Coll. Cardiol. 2023, 81, 1192–1200. [Google Scholar] [CrossRef]
  4. American National Standards Institute. Testing and Reporting Performance Results of Cardiac Rhythm and ST Segment Measurement Algorithms. Available online: https://webstore.ansi.org/standards/aami/ansiaamiec572012r2020 (accessed on 1 January 2025).
  5. Liu, Z.; Wang, Y.; Vaidya, S.; Ruehle, F.; Halverson, J.; Soljačić, M.; Hou, T.Y.; Tegmark, M. Kan: Kolmogorov-arnold networks. arXiv 2024, arXiv:2404.19756. [Google Scholar]
  6. Rajaraman, V. JohnMcCarthy—Father of artificial intelligence. Resonance 2014, 19, 198–207. [Google Scholar] [CrossRef]
  7. Petch, J.; Di, S.; Nelson, W. Opening the black box: The promise and limitations of explainable machine learning in cardiology. Can. J. Cardiol. 2022, 38, 204–213. [Google Scholar] [CrossRef]
  8. Dolatabadi, A.D.; Khadem SE, Z.; Asl, B.M. Automated diagnosis of coronary artery disease (CAD) patients using optimized SVM. Comput. Methods Programs Biomed. 2017, 138, 117–126. [Google Scholar] [CrossRef] [PubMed]
  9. Kumar, S.U.; Inbarani, H. Neighborhood rough set based ECG signal classification for diagnosis of cardiac diseases. Soft Comput. 2017, 21, 4721–4733. [Google Scholar] [CrossRef]
  10. Acharya, U.R.; Fujita, H.; Sudarshan, V.K.; Oh, S.L.; Adam, M.; Koh, J.E.; Tan, J.H.; Ghista, D.N.; Martis, R.J.; Chua, C.K.; et al. Automated detection and localization of myocardial infarction using electrocardiogram: A comparative study of different leads. Knowl. Based Syst. 2016, 99, 146–156. [Google Scholar] [CrossRef]
  11. Zhang, J.; Lin, F.; Xiong, P.; Du, H.; Zhang, H.; Liu, M.; Hou, Z.; Liub, X. Automated detection and localization of myocardial infarction with staked sparse autoencoder and treebagger. IEEE Access 2019, 7, 70634–70642. [Google Scholar] [CrossRef]
  12. Feng, K.; Pi, X.; Liu, H.; Sun, K. Myocardial infarction classification based on convolutional neural network and recurrent neural network. Appl. Sci. 2019, 9, 1879. [Google Scholar] [CrossRef]
  13. Liu, Z.; Zhang, X. ECG-based heart arrhythmia diagnosis through attentional convolutional neural networks. In Proceedings of the 2021 IEEE International Conference on Internet of Things and Intelligence Systems (IoTaIS), Bandung, Indonesia, 23–24 November 2021; pp. 156–162. [Google Scholar]
  14. Hu, R.; Chen, J.; Zhou, L. A transformer-based deep neural network for arrhythmia detection using continuous ECG signals. Comput. Biol. Med. 2022, 144, 105325. [Google Scholar] [CrossRef]
  15. Available online: https://www.kaggle.com/datasets/shayanfazeli/heartbeat?resource=download (accessed on 1 January 2025).
  16. Kachuee, M.; Fazeli, S.; Sarrafzadeh, M. Ecg heartbeat classification: A deep transferable representation. In Proceedings of the 2018 IEEE International Conference on Healthcare Informatics (ICHI), New York, NY, USA, 4–7 June 2018; pp. 443–444. [Google Scholar]
  17. Wang, Y.; Qian, J.; Hassan, M.; Zhang, X.; Zhang, T.; Yang, C.; Zhou, X.; Jia, F. Density peak clustering algorithms: A review on the decade 2014–2023. Expert Syst. Appl. 2024, 238, 121860. [Google Scholar] [CrossRef]
  18. Zhang, T.; Ramakrishnan, R.; Livny, M. BIRCH: An efficient data clustering method for very large databases. ACM Sigmod Rec. 1996, 25, 103–114. [Google Scholar] [CrossRef]
  19. Peng, Y.; Luo, Y.; Zhang, Q.; Xie, C. A mean shift algorithm incorporating reachable distance for spatial clustering. Inf. Sci. 2025, 689, 121456. [Google Scholar] [CrossRef]
  20. Zhong, G.; Pun, C.M. Self-taught multi-view spectral clustering. Pattern Recognit. 2023, 138, 109349. [Google Scholar] [CrossRef]
  21. Mao, A.; Mohri, M.; Zhong, Y. Cross-entropy loss functions: Theoretical analysis and applications. In Proceedings of the International Conference on Machine Learning, Honolulu, HI, USA, 23–29 July 2023; pp. 23803–23828. [Google Scholar]
  22. Reyad, M.; Sarhan, A.M.; Arafa, M. A modified Adam algorithm for deep neural network optimization. Neural Comput. Appl. 2023, 35, 17095–17112. [Google Scholar] [CrossRef]
  23. Majhi, B.; Kashyap, A. Explainable AI-driven machine learning for heart disease detection using ECG signal. Appl. Soft Comput. 2024, 167, 112225. [Google Scholar] [CrossRef]
  24. Arias-Duart, A.; Mariotti, E.; Garcia-Gasulla, D.; Alonso-Moral, J.M. A confusion matrix for evaluating feature attribution methods. In Proceedings of the 2023 IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPRW), Vancouver, BC, Canada, 17–24 June 2023. [Google Scholar]
  25. Thompson, M.L.; Zucchini, W. On the statistical analysis of ROC curves. Stat. Med. 1989, 8, 1277–1290. [Google Scholar] [CrossRef]
  26. Shaker, A.M.; Tantawi, M.; Shedeed, H.A.; Tolba, M.F. Generalization of convolutional neural networks for ECG classification using generative adversarial networks. IEEE Access 2020, 8, 35592–35605. [Google Scholar] [CrossRef]
  27. Wang, J.; Qiao, X.; Liu, C.; Wang, X.; Liu, Y.; Yao, L.; Zhang, H. Automated ECG classification using a non-local convolutional block attention module. Comput. Methods Programs Biomed. 2021, 203, 106006. [Google Scholar] [CrossRef]
  28. Le, M.D.; Rathour, V.S.; Truong, Q.S.; Mai, Q.; Brijesh, P.; Le, N. Multi-module recurrent convolutional neural network with transformer encoder for ECG arrhythmia classification. In Proceedings of the 2021 IEEE EMBS International Conference on Biomedical and Health Informatics (BHI), Virtually, 27–30 July 2021; pp. 1–5. [Google Scholar]
  29. Hammad, M.; Iliyasu, A.M.; Subasi, A.; Ho, E.S.L.; El-Latif, A.A.A. A multitier deep learning model for arrhythmia detection. IEEE Trans. Instrum. Meas. 2020, 70, 2502809. [Google Scholar] [CrossRef]
  30. Kumar, S.; Mallik, A.; Kumar, A.; Del Ser, J.; Yang, G. Fuzz-ClustNet: Coupled fuzzy clustering and deep neural networks for Arrhythmia detection from ECG signals. Comput. Biol. Med. 2023, 153, 106511. [Google Scholar] [CrossRef] [PubMed]
  31. Pradeep, C.S.; Sinha, N. Time-invariant latent space signatures for enhanced time-frequency domain representation. In Proceedings of the 2024 International Joint Conference on Neural Networks (IJCNN), Yokohama, Japan, 30 June–5 July 2024; pp. 1–8. [Google Scholar]
  32. Al-Shammary, D.; Radhi, M.; AlSaeedi, A.H.; Mahdi, A.M.; Ibaida, A.; Ahmed, K. Efficient ecg classification based on the probabilistic kullback-leibler divergence. Inform. Med. Unlocked 2024, 47, 101510. [Google Scholar] [CrossRef]
  33. Sharma, L.N.; Tripathy, R.K.; Dandapat, S. Multiscale energy and eigenspace approach to detection and localization of myocardial infarction. IEEE Trans. Biomed. Eng. 2015, 62, 1827–1837. [Google Scholar] [CrossRef]
  34. Islam, R.; Rahman, M.; Ismail, S.M.; Akter, S. Transfer learning in deep neural network model of ecg signal classification. In Proceedings of the 2022 International Conference on Recent Progresses in Science, Engineering and Technology (ICRPSET), Rajshahi, India, 26–27 December 2022; pp. 1–4. [Google Scholar]
  35. Kojuri, J.; Boostani, R.; Dehghani, P.; Nowroozipour, F.; Saki, N. Prediction of acute myocardial infarction with artificial neural networks in patients with nondiagnostic electrocardiogram. J. Cardiovasc. Dis. Res. 2015, 6, 51. [Google Scholar] [CrossRef]
Figure 1. Flowchart of the research method for classifying arrhythmia diseases using KAN and ECG signal data.
Figure 1. Flowchart of the research method for classifying arrhythmia diseases using KAN and ECG signal data.
Algorithms 18 00090 g001
Figure 2. Preprocessing of ECG signal data.
Figure 2. Preprocessing of ECG signal data.
Algorithms 18 00090 g002
Figure 3. Comparative analysis of ECG signal data before and after variance sorting.
Figure 3. Comparative analysis of ECG signal data before and after variance sorting.
Algorithms 18 00090 g003
Figure 4. Schematic diagram of the 2-layer framework of the KAN model in the ECG signal classification task.
Figure 4. Schematic diagram of the 2-layer framework of the KAN model in the ECG signal classification task.
Algorithms 18 00090 g004
Figure 5. Classification confusion matrix and ROC curve of different categories of heart failure in the MIT-BIH dataset after balanced and variance sorting.
Figure 5. Classification confusion matrix and ROC curve of different categories of heart failure in the MIT-BIH dataset after balanced and variance sorting.
Algorithms 18 00090 g005
Figure 6. Visualization effects of three clustering methods on ECG signal data and feature vectors.
Figure 6. Visualization effects of three clustering methods on ECG signal data and feature vectors.
Algorithms 18 00090 g006
Figure 7. Comparison of model loss values on the MIT-BIH dataset after balanced and variance sorting.
Figure 7. Comparison of model loss values on the MIT-BIH dataset after balanced and variance sorting.
Algorithms 18 00090 g007
Figure 8. Comparison of model loss values under the original MIT-BIH dataset.
Figure 8. Comparison of model loss values under the original MIT-BIH dataset.
Algorithms 18 00090 g008
Table 1. ECG categories and data volumes of the MIT-BIH arrhythmia dataset defined based on the AAMI standard.
Table 1. ECG categories and data volumes of the MIT-BIH arrhythmia dataset defined based on the AAMI standard.
AAMI ECGNSVFQ
Class descriptionNormal heart that not included in S, V, F or Q classesSupraventricular ectopic beatVentricular ectopic beatFusion beatUnknown beat
MIT-BIH ECG classesNormal beat (N)
Left bundle branch block beat (L)
Right bundle branch block beat (R)
Atrial escape beat (e)
Nodal (junctional) escape beat (j)
Atrial premature beat (A)
Aberrated atrial premature beat (a)
Nodal (junctional) premature beat (J)
Supraventricular premature or ectopic beat (S)
Premature ventricular contraction (V)
Ventricular escape beat (E)
Fusion of ventricular and normal beat (F)Paced beat (/)
Fusion of paced and normal beat (f)
Unclassifiable beat (Q)
Training set72,471222357886416431
Test set18,11855614481621608
Total90,589277972368038039
Table 2. Comparison of classification results on the original MIT-BIH.
Table 2. Comparison of classification results on the original MIT-BIH.
ModelAccuracy (%)Precision (%)Recall (%)F1_Score (%)
MLP97.6287.0683.1885.08
KAN97.6893.1982.4787.50
Table 3. Comparison of classification results of the MIT-BIH after balanced and variance sorting.
Table 3. Comparison of classification results of the MIT-BIH after balanced and variance sorting.
ModelAccuracy (%)Precision (%)Recall (%)F1_Score (%)
MLP98.2898.2298.1498.21
KAN99.0899.0798.9999.03
Table 4. Comparison of classification results on the original PTB.
Table 4. Comparison of classification results on the original PTB.
ModelAccuracy (%)Precision (%)Recall (%)F1_Score (%)
MLP96.0195.0695.2695.16
KAN97.6897.9097.9797.97
Table 5. Comparison of classification results of the PTB after balanced and variance sorting.
Table 5. Comparison of classification results of the PTB after balanced and variance sorting.
ModelAccuracy (%)Precision (%)Recall (%)F1_Score (%)
MLP97.4097.4597.3597.39
KAN99.1199.1198.8298.96
Table 6. ECG signal classification results on the MIT-BIH.
Table 6. ECG signal classification results on the MIT-BIH.
WorksAccuracy (%)Precision (%)Recall (%)
Shaker et al. [26]98.3090.0099.77
Wang J. et al. [27]98.64\99.00
Le M. D. et al. [28]98.29\\
Hammad M. et al. [29]98.0095.8099.70
Kumar S. et al. [30]98.6698.9293.88
Kachuee M. et al. [16]93.40\\
Pradeep C. S. et al. [31]98.1997.5897.66
Al-Shammary D. et al. [32]86.6786.3486.67
Liu et al. [13] 98.6598.6898.65
our99.0899.0798.99
Table 7. ECG signal classification results on the PTB dataset.
Table 7. ECG signal classification results on the PTB dataset.
WorksAccuracy (%)Precision (%)Recall (%)
Kumar S. et al. [30]95.7996.2985.38
Kachuee M. et al. [16]95.9095.2095.10
Sharma L. N. et al. [33]96.0099.0093.00
Islam R. et al. [34]97.0097.0098.00
Kojuri et al. [35]95.6097.9093.33
our99.1199.1198.82
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Cui, H.; Ning, S.; Wang, S.; Zhang, W.; Peng, Y. ECG Signal Classification Using Interpretable KAN: Towards Predictive Diagnosis of Arrhythmias. Algorithms 2025, 18, 90. https://doi.org/10.3390/a18020090

AMA Style

Cui H, Ning S, Wang S, Zhang W, Peng Y. ECG Signal Classification Using Interpretable KAN: Towards Predictive Diagnosis of Arrhythmias. Algorithms. 2025; 18(2):90. https://doi.org/10.3390/a18020090

Chicago/Turabian Style

Cui, Hongzhen, Shenhui Ning, Shichao Wang, Wei Zhang, and Yunfeng Peng. 2025. "ECG Signal Classification Using Interpretable KAN: Towards Predictive Diagnosis of Arrhythmias" Algorithms 18, no. 2: 90. https://doi.org/10.3390/a18020090

APA Style

Cui, H., Ning, S., Wang, S., Zhang, W., & Peng, Y. (2025). ECG Signal Classification Using Interpretable KAN: Towards Predictive Diagnosis of Arrhythmias. Algorithms, 18(2), 90. https://doi.org/10.3390/a18020090

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop