<jupyter_start><jupyter_text>**Resources**:* scikit-image - [view-as-windows](https://scikit-image.org/docs/0.12.x/api/skimage.util.htmlskimage.util.view_as_windows)* scikit-image - [view_as_blocks](https://scikit-image.org/docs/0.12.x/api/skimage.util.htmlskimage.util.view_as_blocks)* [my function](https://github.com/jejjohnson/rbig_eo/blob/master/src/features/density.py)  Example I - Time Series<jupyter_code>A = np.arange(9)
A
window_shape = (3,)

B = skimage.util.view_as_windows(A, window_shape)

B<jupyter_output><empty_output><jupyter_text>Example 2 - 2D Arrays<jupyter_code>A = np.arange(4*4).reshape(4,4)
A
window_shape = (3,3)

B = skimage.util.view_as_windows(A, window_shape)

B<jupyter_output><empty_output><jupyter_text>Example 3 - 3D Arrays<jupyter_code>A = np.arange(4*4*4).reshape(4,4,4)
A
window_shape = (3,3,1)

B = skimage.util.view_as_windows(A, window_shape)

B.shape<jupyter_output><empty_output><jupyter_text>Example 4 - 3D Arrays w. Coordinates<jupyter_code>x = np.array([[1,2,3],[4,5,6],[7,8,9]]).reshape(-1,1)
x.shape
lat = np.linspace(-10, 10, 3)
lon = np.linspace(0, 10, 3)
time = ['2001', '2002', '2003']
data = np.random.randn(lon.shape[0], lat.shape[0], len(time))
data.shape
x_cube = skimage.util.view_as_windows(data, (2,2,1),step=(1,1,1))
x_cube<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.1865955826351866, 'fraction_numerical': 0.05255140898705255, 'mean_word_length': 6.595375722543353, 'pattern_counts': {'":': 0, '<': 17, '<?xml version=': 0, '>': 17, 'https://': 3, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '4', 'dir': 'jupyter-structured-clean-dedup', 'id': '140369', 'license': 'MIT', 'n_tokens_mistral': 617, 'n_tokens_neox': 591, 'n_words': 69, 'path': 'notebooks/explore/minicubes.ipynb', 'repo_name': 'jejjohnson/2019_rbig_rs', 'size': '1313'}