MCPcopy Create free account
hub / github.com/CompVis/zigma / gilbert_zigzag_path

Function gilbert_zigzag_path

utils/utils_zigzag.py:123–130  ·  view source on GitHub ↗
(N)

Source from the content-addressed store, hash-verified

121
122
123def gilbert_zigzag_path(N):
124 width = height = N
125 order_index = np.zeros((width, height), dtype=int)
126 for x in range(width):
127 for y in range(height):
128 idx = gilbert_xy2d(x, y, width, height)
129 order_index[x, y] = idx
130 return order_index
131
132
133##################

Callers 1

hilbert_pathFunction · 0.70

Calls 1

gilbert_xy2dFunction · 0.70

Tested by

no test coverage detected