Table of Contents
Fetching ...

A User's Guide to $\texttt{KSig}$: GPU-Accelerated Computation of the Signature Kernel

Csaba Tóth, Danilo Jr Dela Cruz, Harald Oberhauser

TL;DR

The paper introduces KSig, a GPU-accelerated, Scikit-Learn-compatible library for computing the signature kernel on sequential data, uniting exact dual methods with scalable primal approximations. It formalizes dual approaches (Signature Kernels, Truncated Kernels, and SigPDE) and contrasts them with primal random-feature strategies (RFF, RFSF, DP, TRP, TS), analyzing computational trade-offs. A comprehensive scalability study demonstrates how sequence length, truncation level, and feature-map size impact memory, time, and accuracy, recommending DP-1D as a practical starting point for large-scale tasks. The work provides practical guidance, implementation details, and datasets to illustrate deployment, highlighting significant improvements in handling large time-series problems with GPU acceleration and modular design. The developed framework paves the way for scalable, kernel-based modeling of sequential data in real-world applications.

Abstract

The signature kernel is a positive definite kernel for sequential and temporal data that has become increasingly popular in machine learning applications due to powerful theoretical guarantees, strong empirical performance, and recently introduced various scalable variations. In this chapter, we give a short introduction to $\texttt{KSig}$, a $\texttt{Scikit-Learn}$ compatible Python package that implements various GPU-accelerated algorithms for computing signature kernels, and performing downstream learning tasks. We also introduce a new algorithm based on tensor sketches which gives strong performance compared to existing algorithms. The package is available at https://github.com/tgcsaba/ksig.

A User's Guide to $\texttt{KSig}$: GPU-Accelerated Computation of the Signature Kernel

TL;DR

The paper introduces KSig, a GPU-accelerated, Scikit-Learn-compatible library for computing the signature kernel on sequential data, uniting exact dual methods with scalable primal approximations. It formalizes dual approaches (Signature Kernels, Truncated Kernels, and SigPDE) and contrasts them with primal random-feature strategies (RFF, RFSF, DP, TRP, TS), analyzing computational trade-offs. A comprehensive scalability study demonstrates how sequence length, truncation level, and feature-map size impact memory, time, and accuracy, recommending DP-1D as a practical starting point for large-scale tasks. The work provides practical guidance, implementation details, and datasets to illustrate deployment, highlighting significant improvements in handling large time-series problems with GPU acceleration and modular design. The developed framework paves the way for scalable, kernel-based modeling of sequential data in real-world applications.

Abstract

The signature kernel is a positive definite kernel for sequential and temporal data that has become increasingly popular in machine learning applications due to powerful theoretical guarantees, strong empirical performance, and recently introduced various scalable variations. In this chapter, we give a short introduction to , a compatible Python package that implements various GPU-accelerated algorithms for computing signature kernels, and performing downstream learning tasks. We also introduce a new algorithm based on tensor sketches which gives strong performance compared to existing algorithms. The package is available at https://github.com/tgcsaba/ksig.
Paper Structure (31 sections, 61 equations, 6 figures, 5 tables)

This paper contains 31 sections, 61 equations, 6 figures, 5 tables.

Figures (6)

  • Figure 1: GPU memory footprint and runtime of each algorithm to compute the Gram matrix of 5-dimensional Brownian Motion for varying sequence lengths $L$. The sequence length was increased for each algorithm until failure due to insufficient memory. We set $M = 5, D=Q=100, N=10$.
  • Figure 2: GPU memory footprint and runtime of each algorithm to compute the Gram matrix of 5-dimensional Brownian Motion for increasing feature map size $F$ until exceeding the memory limit. We set $M = 5, N = 10, L = 100$. $D = Q$ is increased to increase $F$.
  • Figure 3: Approximation error of each method against feature map size, memory footprint and runtime. We set $M = 5, N = 20, L = 100$.
  • Figure 4: Approximation error of RFSF-TRP and RFSF-TS for various combinations of RFF and projection components, $D, Q$ respectively. We set $M = 5, N = 20, L = 100$.
  • Figure 5: Memory footprint, runtime and accuracy of each method against truncation level $M$. We set $N=100, L=100, Q = 1000$. $D = Q$ except for RFSF-DP which is adjusted to match $F$.
  • ...and 1 more figures

Theorems & Definitions (1)

  • remark 1