arXiv:2609.01956cs.LGcs.NA2026-09

用新方法加速KAN网络,速度提升显著且更稳定。

InKAN: B-Spline KANs via Truncated Power Form

  • 改用截断幂形式替代递归计算,消除多轮遍历
  • 输入范围限制在[0,4]内,避免数值崩溃问题
  • 开源可直接替换现有KAN层,适合追求效率的开发者

Kolmogorov-Arnold网络(KAN)将可学习的B样条激活函数置于网络边而非节点。标准的Cox-de Boor递归对k次样条需进行k次序列遍历,占前向传播时间超90%。FlashKAN采用逼近论中的截断幂形式,将每个均匀三次B样条表示为五个移位节点处的 (x)_+^3 项。本文贡献包括:(1) 基于torch.compile融合的实现,将所有操作合并为单一GPU核函数,彻底消除递归、跨度查找和散乱聚集;(2) 有界坐标稳定化策略,将归一化输入钳制在[0, k+1]区间,防止历史上促使使用Cox-de Boor递归的灾难性抵消;(3) 开发了生产就绪的开源包(pip install flashkan),可作为现有KAN层的即插即用替代品。

原文摘要 · Abstract (English)

Kolmogorov-Arnold Networks (KANs) place learnable B-spline activations on network edges rather than fixed activations on nodes. The standard Cox-de Boor recursion evaluates these activations through $k$ sequential passes for degree-$k$ splines, consuming over 90% of forward-pass time. InKAN replaces this recursion with the truncated power form, a classical result from approximation theory that expresses each uniform cubic B-spline as five $(x)_+^3$ terms at shifted knot positions. This paper makes three contributions: (1) a torch.compile-fused implementation that collapses these operations into a single GPU kernel, eliminating all recursion, span lookup, and scatter-gather operations; (2) a bounded-coordinate stabilization that clamps the normalized input to $[0, k{+}1]$, preventing the catastrophic cancellation that historically motivated the Cox-de Boor recursion; and (3) a production-ready, open-source package (pip install inkan) that serves as a drop-in replacement for existing KAN layers.

神经网络KAN加速B样条

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。