Skip to content

Commit df69796

Browse files
committed
Added window size check to preprocessing
1 parent 95c3a2c commit df69796

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

stumpy/core.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1255,6 +1255,7 @@ def preprocess(T, m):
12551255
T = transpose_dataframe(T)
12561256
T = np.asarray(T)
12571257
check_dtype(T)
1258+
check_window_size(m, max_size=T.shape[-1])
12581259

12591260
T[np.isinf(T)] = np.nan
12601261
M_T, Σ_T = compute_mean_std(T, m)
@@ -1294,6 +1295,7 @@ def preprocess_non_normalized(T, m):
12941295
T = transpose_dataframe(T)
12951296
T = np.asarray(T)
12961297
check_dtype(T)
1298+
check_window_size(m, max_size=T.shape[-1])
12971299

12981300
T[np.isinf(T)] = np.nan
12991301
T_subseq_isfinite = rolling_isfinite(T, m)

0 commit comments

Comments
 (0)