This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def sliding_window(data, size, stepsize=1, padded=False, axis=-1, copy=True): | |
""" | |
Calculate a sliding window over a signal | |
Parameters | |
---------- | |
data : numpy array | |
The array to be slided over. | |
size : int | |
The sliding window size |