The electrocardiogram (ECG) serves as a fundamental non-invasive tool for diagnosing cardiovascular diseases, yet its analysis is inherently challenging due to noise and significant inter-patient variability. Deep learning has revolutionized automated...
The electrocardiogram (ECG) serves as a fundamental non-invasive tool for diagnosing cardiovascular diseases, yet its analysis is inherently challenging due to noise and significant inter-patient variability. Deep learning has revolutionized automated electrocardiogram (ECG) diagnosis, but its black box nature impedes clinical adoption. Current interpretability solutions often rely on post-hoc methods that suffer from methodological inconsistency and limited reliability. To address this, we propose an intrinsically interpretable deep learning framework, leveraging a Multi-Instance Learning (MIL) approach. In contrast to conventional MIL approaches that define instances at the coarse heartbeat level, we introduce a fine-grained sub-beat level instance definition with a temporal resolution of 0.14 seconds. This granularity enables the precise localization of diagnostic evidence to specific morphological waveforms, such as the P-wave, QRS complex, and ST segment, which are essential for identifying subtle pathologies. To overcome the limitation of localized instances missing global context, the framework incorporates Rhythm Context Injection to explicitly capture beat-to-beat relationships, compensating for information loss inherent to constrained interpretable models by enriching each instance. We further integrate Anatomical Lead Grouping to structure the 12-leads signals into five anatomically relevant groups, preserving spatial information regarding pathology localization. Finally, a Two-Stage Hierarchical MIL mechanism is utilized, comprising Intra-Group Temporal Attention Pooling and Inter-Group Attention Pooling, to simultaneously localize critical temporal segments and significant lead groups. Experiments on the PTB-XL dataset achieve competitive classification performance while demonstrating more faithful interpretability. Visualization of diagnostic evidence confirmed that the interpretation maps accurately focus on local regions consistent with clinical criteria. Quantitative perturbation analysis demonstrated that the model relies on evidence that is quantitatively more aligned with its decision-making process compared to post-hoc baselines. In conclusion, this study presents a novel deep learning framework that maintains high classification accuracy while providing clinicians with reliable and granular visual evidence.