Expand description
Shapelet transform: turn a fitted ShapeletSet into an n×K distance
feature matrix, for both training and out-of-sample curves.
Given K discovered shapelets and a curve set of n series, the transform
produces an n×K FdMatrix whose entry X[(i, j)] is the shapelet
distance (shapelet_distance) from shapelet j to curve i:
X[(i, j)] = sdist(shapelet_j, curve_i)The K output columns are shapelet distances, not functional evaluation
points. Downstream (Phase 60) an fdars classifier consumes this matrix as
data — rows are observations, columns are the K shapelet-distance
features.
§Consistency and normalization
The shapelets carried by a ShapeletSet are stored already
z-normalized (Phase 57 provenance). The transform reuses those stored
values directly and never re-normalizes against the input series’ statistics.
Every window of each input series is z-normalized independently at comparison
time inside shapelet_distance. Because training and out-of-sample curves
flow through the identical code path with the identical stored shapelets and
best_so_far = f64::INFINITY, re-transforming the training set exactly
reproduces the fit-time distances (see ShapeletTransformFit).
Structs§
- Shapelet
Transform Fit - A fitted shapelet transform: the discovered
ShapeletSetplus the training feature matrix produced by applying it to the training curves.
Functions§
- shapelet_
transform - Apply a fitted
ShapeletSetto a curve set, producing ann×Kdistance feature matrix. - shapelet_
transform_ fit - Fit a shapelet transform: discover shapelets from a labeled training set,
then transform that training set into an
n×Kdistance feature matrix.