def _rolling_window(a, window):
<EOL>shape = a.shape[:-<NUM_LIT:1>] + (a.shape[-<NUM_LIT:1>] - window + <NUM_LIT:1>, window)<EOL>strides = a.strides + (a.strides[-<NUM_LIT:1>],)<EOL>return np.lib.stride_tricks.as_strided(a, shape=shape, strides=strides)<EOL>
[True, True, False, True, False], 2 ->

[
    [True,  True],
    [True, False],
    [False, True],
    [True, False],
]