tsseg.algorithms.ticc package
TICC — Toeplitz Inverse Covariance-based Clustering.
Description
TICC simultaneously segments and clusters multivariate time series by modelling
each cluster as a Markov Random Field (MRF) defined over a short window of
length window_size. The MRF is characterised by a block-Toeplitz inverse
covariance matrix that captures temporal and cross-variable partial correlations.
The algorithm alternates between:
Assignment step — dynamic programming assigns each time step to the cluster maximising a log-likelihood + switching penalty \(\beta\).
Update step — ADMM updates the Toeplitz inverse covariance of each cluster subject to a sparsity penalty \(\lambda\).
n_states required)Parameters
Name |
Type |
Default |
Description |
|---|---|---|---|
|
int |
|
Sliding window size. |
|
int |
|
Number of states (clusters). |
|
float |
|
Sparsity parameter for the inverse covariance. |
|
float |
|
Switching penalty (temporal consistency). |
|
int |
|
Maximum EM iterations. |
|
float |
|
Convergence threshold. |
|
int |
|
Number of parallel processes. |
|
int |
|
Time axis. |
Usage
from tsseg.algorithms import TiccDetector
detector = TiccDetector(n_states=4, window_size=10, beta=200)
states = detector.fit_predict(X)
Implementation: Adapted from the original TICC code by Hallac et al.
Reference: Hallac, Vare, Boyd & Leskovec (2017), Toeplitz Inverse Covariance-Based Clustering of Multivariate Time Series Data, KDD.