Transformer
SlidingWindowSegmenter
Sliding window segmenter transformer.
This class is to transform a univariate series into a multivariate one by extracting sets of subsequences. It does this by firstly padding the time series on either end floor(window_length/2) times. Then it performs a sliding window of size window_length and hop size 1.
e.g. if window_length = 3
S = 1,2,3,4,5, floor(3/2) = 1 so S would be padded as
1,1,2,3,4,5,5
then SlidingWindowSegmenter would extract the following:
(1,1,2),(1,2,3),(2,3,4),(3,4,5),(4,5,5)
the time series is now a multivariate one.
Schnellstart
python
from sktime.transformations.segment import SlidingWindowSegmenter
estimator = SlidingWindowSegmenter(window_length=5)Parameter(2)
- window_lengthint, optional, default=5.
- length of sliding window interval
- Used by the ShapeDTW algorithm.