mirror of
https://github.com/wassname/scikit-image.git
synced 2026-06-28 22:37:50 +08:00
MAINT: skel3d: prune dead code (eg, is_surface_point)
This commit is contained in:
@@ -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.
|
||||
"""
|
||||
|
||||
Reference in New Issue
Block a user