You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Distance from each unit-norm direction vector to its x-axis neighbor.
dx = [
np.sqrt(np.sum((v[:-1, :, :] - v[1:, :, :])**2, -1)) for v in directions
]
dx = [np.concatenate([v, v[-2:-1, :]], 0) for v in dx]
# Cut the distance in half, and then round it out so that it's
# halfway between inscribed by / circumscribed about the pixel.
radii = [v[..., None] * 2 / np.sqrt(12) for v in dx]`
`