MODULE REFERENCE
cost_matrix
anomx.data.processing.dtw.cost_matrixDTW Cost Matrix
classView source ↗
CostMatrix
CostMatrixBases: ABC
(n+1) x (m+1) Matrix Cell (i,j) corresponds to minimum total cost/distance of matching elements (i-1, j-1) in series1 and series2.
Row 0 and column 0, are typically set to infinity, to prevent matching before the first element
Members
nattribute
n: intmattribute
m: intfillmethod
fill(value: float)| Parameter | Type | Default |
|---|---|---|
value | float | required |
to_densemethod
to_dense() -> np.ndarrayReturns
- Dense n x m numpy array, where empty cells are set to np.inf
Returns np.ndarray
classView source ↗
DenseCostMatrix
DenseCostMatrixBases: np.ndarray, CostMatrix
Members
to_densemethod
Inherited members
classView source ↗
SparseCostMatrix
SparseCostMatrix(window: CRWindow)Bases: CostMatrix
| Parameter | Type | Default |
|---|---|---|
window | CRWindow | required |