fuzzyclust.relational.dtw_alignment#

fuzzyclust.relational.dtw_alignment(x, y, window=None)[source]#

Optimal warping path between two series (for inspection and plotting).

Parameters:
x, yarray_like of shape (length,) or (length, n_channels)
windowint, float or None, default=None

Sakoe–Chiba band, see dtw_distance_matrix().

Returns:
distancefloat

The DTW distance (square root of the minimal accumulated cost).

pathndarray of shape (n_steps, 2)

Index pairs (t, s) of the optimal path from (0, 0) to (len(x)-1, len(y)-1).