_unfold(arr, axis, size, step)
All windows are of size size and begin with every step elements.
The input array
Axis along which the windows are extracted
Size of the windows
Stride between first elements of subsequent windows.
Append an extra dimension containing sliding windows along axis.
>>> i, j = np.ogrid[:3,:7]
... a = i*10 + j
... a array([[ 0, 1, 2, 3, 4, 5, 6], [10, 11, 12, 13, 14, 15, 16], [20, 21, 22, 23, 24, 25, 26]])
>>> _unfold(a, axis=1, size=3, step=2) array([[[ 0, 1, 2], [ 2, 3, 4], [ 4, 5, 6]], [[10, 11, 12], [12, 13, 14], [14, 15, 16]], [[20, 21, 22], [22, 23, 24], [24, 25, 26]]])See :
The following pages refer to to this document either explicitly or contain code examples using this.
matplotlib.cbook._unfold
Hover to see nodes names; edges to Self not shown, Caped at 50 nodes.
Using a canvas is more power efficient and can get hundred of nodes ; but does not allow hyperlinks; , arrows or text (beyond on hover)
SVG is more flexible but power hungry; and does not scale well to 50 + nodes.
All aboves nodes referred to, (or are referred from) current nodes; Edges from Self to other have been omitted (or all nodes would be connected to the central node "self" which is not useful). Nodes are colored by the library they belong to, and scaled with the number of references pointing them