Skip to content

Commit dd98c83

Browse files
committed
simplify function
1 parent 5a7f315 commit dd98c83

File tree

1 file changed

+1
-6
lines changed

1 file changed

+1
-6
lines changed

stumpy/sdp.py

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -52,12 +52,7 @@ def _convolve_sliding_dot_product(Q, T):
5252
output : numpy.ndarray
5353
Sliding dot product between `Q` and `T`.
5454
"""
55-
n = T.shape[0]
56-
m = Q.shape[0]
57-
Qr = np.flipud(Q) # Reverse/flip Q
58-
QT = convolve(Qr, T)
59-
60-
return QT.real[m - 1 : n]
55+
return convolve(np.flipud(Q), T, mode="valid")
6156

6257

6358
def _sliding_dot_product(Q, T):

0 commit comments

Comments
 (0)