Compute the k-dimensional matrix profile subspace for a given subsequence index and its nearest neighbor index Parameters ---------- T : numpy.ndarray The time series or sequence for which the multi-dimensional matrix profile, multi-dimensional matrix profile in
(
T,
m,
subseq_idx,
nn_idx,
k,
include=None,
discords=False,
discretize_func=None,
n_bit=8,
p=2.0,
)
| 64 | |
| 65 | |
| 66 | def maamp_subspace( |
| 67 | T, |
| 68 | m, |
| 69 | subseq_idx, |
| 70 | nn_idx, |
| 71 | k, |
| 72 | include=None, |
| 73 | discords=False, |
| 74 | discretize_func=None, |
| 75 | n_bit=8, |
| 76 | p=2.0, |
| 77 | ): |
| 78 | """ |
| 79 | Compute the k-dimensional matrix profile subspace for a given subsequence index and |
| 80 | its nearest neighbor index |
| 81 | |
| 82 | Parameters |
| 83 | ---------- |
| 84 | T : numpy.ndarray |
| 85 | The time series or sequence for which the multi-dimensional matrix profile, |
| 86 | multi-dimensional matrix profile indices were computed |
| 87 | |
| 88 | m : int |
| 89 | Window size |
| 90 | |
| 91 | subseq_idx : int |
| 92 | The subsequence index in T |
| 93 | |
| 94 | nn_idx : int |
| 95 | The nearest neighbor index in T |
| 96 | |
| 97 | k : int |
| 98 | The subset number of dimensions out of `D = T.shape[0]`-dimensions to return |
| 99 | the subspace for |
| 100 | |
| 101 | include : numpy.ndarray, default None |
| 102 | A list of (zero-based) indices corresponding to the dimensions in `T` that |
| 103 | must be included in the constrained multidimensional motif search. |
| 104 | For more information, see Section IV D in: |
| 105 | |
| 106 | `DOI: 10.1109/ICDM.2017.66 \ |
| 107 | <https://www.cs.ucr.edu/~eamonn/Motif_Discovery_ICDM.pdf>`__ |
| 108 | |
| 109 | discords : bool, default False |
| 110 | When set to `True`, this reverses the distance profile to favor discords rather |
| 111 | than motifs. Note that indices in `include` are still maintained and respected. |
| 112 | |
| 113 | discretize_func : func, default None |
| 114 | A function for discretizing each input array. When this is `None`, an |
| 115 | appropriate discretization function (based on the `normalize` parameter) will |
| 116 | be applied. |
| 117 | |
| 118 | n_bit : int, default 8 |
| 119 | The number of bits used for discretization. For more information on an |
| 120 | appropriate value, see Figure 4 in: |
| 121 | |
| 122 | `DOI: 10.1109/ICDM.2016.0069 \ |
| 123 | <https://www.cs.ucr.edu/~eamonn/PID4481999_Matrix%20Profile_III.pdf>`__ |
no outgoing calls