Patch-based transformers have emerged as efficient and improved long-horizon modeling architectures for time series modeling. Yet, existing approaches rely on temporally-agnostic patch construction, where arbitrary starting positions and fixed lengths fracture temporal coherence by splitting natural transitions across boundaries. This naive segmentation often disrupts short-term dependencies and weakens representation learning. We propose a novel Entropy-Guided Dynamic Patch Encoder (EntroPE), as a temporally informed framework that dynamically detects transition points via conditional entropy and dynamically places patch boundaries. This preserves temporal structure while retaining the computational benefits of patching. EntroPE consists of two key modules, namely an Entropy-based Dynamic Patcher (EDP) that applies information-theoretic criteria to locate natural temporal shifts and determine patch boundaries, and an Adaptive Patch Encoder (APE) that employs pooling and cross-attention to capture intra-patch dependencies and produce fixed-size latent representations. Extensive experiments on long-term forecasting, classification, and anomaly detection demonstrate that the proposed method improves both accuracy and efficiency, establishing entropy-guided dynamic patching as a promising new paradigm for time series modeling. Code is available at https://github.com/Sachithx/EntroPE.
翻译:基于片段的Transformer已成为时间序列建模中高效且改进的长时程建模架构。然而,现有方法依赖于时间无关的片段构建方式,其中任意的起始位置和固定长度会因跨越边界分割自然过渡而破坏时间连贯性。这种简单的分割方式通常会破坏短期依赖关系并削弱表示学习。我们提出了一种新颖的熵引导动态片段编码器(EntroPE),作为一个时间感知框架,通过条件熵动态检测过渡点并动态放置片段边界。这既保留了时间结构,又保持了片段化的计算优势。EntroPE包含两个关键模块:基于熵的动态分割器(EDP)——应用信息论准则定位自然时间偏移并确定片段边界;以及自适应片段编码器(APE)——采用池化和交叉注意力机制来捕获片段内依赖关系并生成固定大小的潜在表示。在长期预测、分类和异常检测任务上的大量实验表明,所提方法在精度和效率上均有提升,确立了熵引导动态分割作为时间序列建模的一种有前景的新范式。代码发布于 https://github.com/Sachithx/EntroPE。