Back to models
Transformer (Pairwise Panel)

DtwPythonDist

Interface to dynamic time warping distances in the dtw-python package.

Quickstart

python
from sktime.dists_kernels.dtw import DtwPythonDist

estimator = DtwPythonDist(dist='euclidean', step_pattern='symmetric2', window_type='none', open_begin=False, open_end=False)

Parameters(5)

dist: str, or estimator following sktime BasePairwiseTransformer API

distance to use, a distance on real n-space, default = “euclidean” if str, must be name of one of the functions in scipy.spatial.distance.cdist if estimator, must follow sktime BasePairwiseTransformer API

step_patternstr, optional, default = “symmetric2”,
or dtw_python stepPattern object, optional step pattern to use in time warping one of: ‘symmetric1’, ‘symmetric2’ (default), ‘asymmetric’, and dozens of other more non-standard step patterns; list can be displayed by calling help(stepPattern) in dtw
window_type: str optional, default = “none”
the chosen windowing function “none”, “itakura”, “sakoechiba”, or “slantedband” “none” (default) - no windowing “sakoechiba” - a band around main diagonal “slantedband” - a band around slanted diagonal “itakura” - Itakura parallelogram
open_beginboolean, optional, default=False
open_end: boolean, optional, default=False
whether to perform open-ended alignments open_begin = whether alignment open ended at start (low index) open_end = whether alignment open ended at end (high index)