###### Abstract  
Research on computer-aided arrhythmia classification is actively conducted, but the limited generalization capacity constrains its applicability in practical clinical settings. One of the primary challenges in deploying such techniques in real-world scenarios is the inter-patient variability and the consequent performance degradation. In this study, we leverage our previous innovation, the n-beat-score map (n-BSM), to introduce an adversarial framework to mitigate the issue of poor performance in arrhythmia classification within the inter-patient paradigm. The n-BSM is a 2D representation of the ECG signal, capturing its constituent beat characteristics through beat-score vectors derived from a pre-trained beat classifier. We employ adversarial learning to eliminate patient-dependent features during the training of the beat classifier, thereby generating the patient-independent n-BSM (PI-BSM). This approach enables us to concentrate primarily on the learning characteristics associated with beat type rather than patient-specific features. Through a beat classifier pre-trained with adversarial learning, a series of beat-score vectors are generated for the beat segments that make up a given ECG signal. These vectors are then concatenated chronologically to form a PI-BSM. Utilizing PI-BSMs as the input, an arrhythmia classifier is trained to differentiate between distinct types of rhythms. This approach yields a 14.27% enhancement in the F1-score in the MIT-BIH arrhythmia database and a 4.97% improvement in cross-database evaluation using the Chapman-Shaoxing 12-lead ECG database. arrhythmia classification; ECG individual differences; inter-patient scheme; adversarial learning +
Footnote †: journal:  
exist in the morphological and temporal properties of ECG signals between patients [9]. Even when patients share the same type of arrhythmia, the ECG signals may exhibit distinct characteristics. Moreover, the inter-patient scheme is preferable in realistic scenarios, albeit presenting challenges in overall classification performance degradation. In this study, we introduce a novel subject-independent modeling approach for ECG-based arrhythmia classification that leverages our previous work on the n-BSM [10]. The n-BSM was originally suggested to efficiently classify ECG rhythms based on the beat-score maps (BSMs) without R-peak detection. The BSM is a 2D representation of the ECG signal aligned with detected R-peak positions. It consists of a chronological arrangement of beat-score vectors with zero interval paddings that capture beat-by-beat characteristics. The beat-score vectors are derived from a pre-trained beat classifier. The n-BSM is an improved version of the BSM that is generated by dividing a given ECG signal into n consecutive segments with a sliding window, thus eliminating the need for R-peak detection for ECG rhythm classification. The n-BSM image varies significantly across arrhythmia types, thereby allowing us to achieve superior performance in ECG-based arrhythmia classification. However, like other methods, the n-BSM also experiences a performance drop in inter-patient evaluation. To alleviate the poor performance issue of the n-BSM-based approach within the patient-to-patient paradigm, we propose an adversarial framework to learn the characteristics of ECG signals, with a greater focus on beat-related features while eliminating patient-related features. We implemented this framework to make it applicable to the pre-training stage of the n-BSM beat classifier. Thus, a beat classifier pre-trained with an adversarial framework is used to generate beat-score vectors for a series of beat segments that make up a given ECG signal, followed by their chronological concatenation to form the corresponding n-BSM image. This resulting n-BSM is hereafter referred to as patient-independent BSM (PI-BSM). Utilizing the PI-BSM as an input to the arrhythmia rhythm classifier leads to improved classification performance compared to existing studies in the patient-to-patient paradigm.