MAINT: skel3d: prune dead code (eg, is_surface_point)

This commit is contained in:
Evgeni Burovski
2016-01-27 15:53:20 +00:00
parent ecf744542e
commit 5fa50a6765
-15
View File
@@ -223,13 +223,6 @@ cdef void get_neighborhood(pixel_type[:, :, ::1] img,
###### look-up tables
def fill_numpoints_LUT(n=256):
p = int(np.log2(n) + 1)
return np.sum(np.arange(n)[:, None] & (1 << np.arange(p)) != 0, axis=1)
NUMPOINTS_LUT = fill_numpoints_LUT()
def fill_Euler_LUT():
""" Look-up table for preserving Euler characteristic.
@@ -405,14 +398,6 @@ cdef int index_octants(int octant,
return n
def is_surfacepoint(neighbors, points_LUT):
for octant in OCTANTS:
n = index_octants(octant, neighbors)
if n not in (240, 165, 170) and points_LUT[n] > 2:
return False
return True
cdef inline bint is_endpoint(pixel_type neighbors[]):
"""An endpoint has exactly one neighbor in the 26-neighborhood.
"""