Medformer: A Multi-Granularity Patching Transformer for Medical Time-Series Classification
Yihe Wang, Nan Huang, Taida Li, Yujun Yan, Xiang Zhang
Abstract
Medical time series (MedTS) data, such as Electroencephalography (EEG) and Electrocardiography (ECG), play a crucial role in healthcare, such as diagnosing brain and heart diseases. Existing methods for MedTS classification primarily rely on handcrafted biomarkers extraction and CNN-based models, with limited exploration of transformer-based models. In this paper, we introduce Medformer, a multi-granularity patching transformer tailored specifically for MedTS classification. Our method incorporates three novel mechanisms to leverage the unique characteristics of MedTS: cross-channel patching to leverage inter-channel correlations, multi-granularity embedding for capturing features at different scales, and two-stage (intra- and inter-granularity) multi-granularity self-attention for learning features and correlations within and among granularities. We conduct extensive experiments on five public datasets under both subject-dependent and challenging subject-independent setups. Results demonstrate Medformer's superiority over 10 baselines, achieving top averaged ranking across five datasets on all six evaluation metrics. These findings underscore the significant impact of our method on healthcare applications, such as diagnosing Myocardial Infarction, Alzheimer's, and Parkinson's disease. We release the source code at https://github.com/DL4mHealth/Medformer.
Ask about this paper
Your agent reads all of it.
Lune indexed this paper to the last equation, along with the top-tier papers that cite it. Ask a question and the answer quotes them.
Your agent calls
Luneget_paper_fulltext
Free to start. No credit card required.
Terminal
Install the CLIlune papers fulltext ec50da9a-6537-4e09-9f8f-5ae28e759c5fCited by top-tier papers28
- CSBrain: A Cross-scale Spatiotemporal Brain Foundation Model for EEG DecodingYuchen Zhou, Jiamin Wu, Zichen Ren, Zhouheng Yao et al.NeurIPS 2025 · 71 citations
- MoFo: Empowering Long-term Time Series Forecasting with Periodic Pattern ModelingJiaming Ma, Binwu Wang, Qihe Huang, Guanjun Wang et al.NeurIPS 2025 · 21 citations
- FeDaL: Federated Dataset Learning for General Time Series Foundation ModelsShengchao Chen, Guodong Long, Michael Blumenstein, Jing JiangICLR 2026 · 11 citations
- MambaSL: Exploring Single-Layer Mamba for Time Series ClassificationYoo-Min Jung, Leekyung KimICLR 2026 · 8 citations
- DualSG: A Dual-Stream Explicit Semantic-Guided Multivariate Time Series Forecasting FrameworkKuiye Ding, Fanda Fan, Yao Wang, Ruijie Jian et al.ACM MM 2025 · 6 citations
Builds on26
- A Simple Framework for Contrastive Learning of Visual RepresentationsTing Chen, Simon Kornblith, Mohammad Norouzi, Geoffrey E. HintonICML 2020 · 24,064 citations
- An Image is Worth 16x16 Words: Transformers for Image Recognition at ScaleAlexey Dosovitskiy, Lucas Beyer, Alexander Kolesnikov, Dirk Weissenborn et al.ICLR 2021 · 21,477 citations
- Informer: Beyond Efficient Transformer for Long Sequence Time-Series ForecastingHaoyi Zhou, Shanghang Zhang, Jieqi Peng, Shuai Zhang et al.AAAI 2021 · 7,289 citations
- Autoformer: Decomposition Transformers with Auto-Correlation for Long-Term Series ForecastingHaixu Wu, Jiehui Xu, Jianmin Wang, Mingsheng LongNeurIPS 2021 · 5,824 citations
- FEDformer: Frequency Enhanced Decomposed Transformer for Long-term Series ForecastingTian Zhou, Ziqing Ma, Qingsong Wen, Xue Wang et al.ICML 2022 · 2,912 citations
Related papers
- MedSpaformer: A Transferable Transformer with Multi-Granularity Token Sparsification for Medical Time Series ClassificationJiexia Ye, Weiqi Zhang, Ziyue Li, Jia Li et al.AAAI 2026 · 1 citation
- Decentralized Attention Fails Centralized Signals: Rethinking Transformers for Medical Time SeriesGuoqi Yu, Juncheng Wang, Chen Yang, Jing Qin et al.ICLR 2026 · 6 citations
- Reading Between the Channels: Knowledge-Augmented Medical Time Series ClassificationXiaoyan Yuan, Wei Wang, Junxin Chen, Xiping HuACM MM 2025 · 1 citation
- A foundation model with multi-variate parallel attention to generate neuronal activityFrancesco S. Carzaniga, Michael Hersche, Abu Sebastian, Kaspar Schindler et al.ICLR 2026 · 6 citations
- Contrast Everything: A Hierarchical Contrastive Framework for Medical Time-SeriesYihe Wang, Yu Han, Haishuai Wang, Xiang ZhangNeurIPS 2023 · 106 citations
