Hello! , Could you tell me that the point cloud on this picture can be Delaunay Triangulation ?
def boundary_extract(points, err=10e-3): pts = np.copy(points) tree = KDTree(pts, leaf_size=2) # adapt_R = adaptive_alpha(tree, 21) tri = Delaunay(pts) # Report an error at this step s = tri.simplices N = s.shape[0] i = 0 edges = [] centers = [] while i <= N - 1: if s[i, 0] == -1: i = i + 1 continue p3 = s[i] e1 = np.array([points[p3[0], :], points[p3[1], :]]) e2 = np.array([points[p3[1], :], points[p3[2], :]]) e3 = np.array([points[p3[0], :], points[p3[2], :]]) e = [e1, e2, e3] for j in range(3): flag, center = edge_check_valid(e[j], tree, adapt_R[i], err) if flag: edges.append(e[j]) centers.append(center) nb = tri.neighbors[i] nb_valid = nb[nb != -1] # nb_valid_num = nb_valid.shape[0] # s[nb_valid] = -1 i = i + 1 return edges, centersTraceback (most recent call last): File "D:/pythonProjectForOpen3D/src/basic/area/AlphaShape.py", line 149, in <module> edges, centers = boundary_extract(final_pointCloud_array, err=10e-5) File "D:/pythonProjectForOpen3D/src/basic/area/AlphaShape.py", line 66, in boundary_extract tri = Delaunay(pts) File "qhull.pyx", line 1840, in scipy.spatial.qhull.Delaunay.__init__ File "qhull.pyx", line 356, in scipy.spatial.qhull._Qhull.__init__scipy.spatial.qhull.QhullError: QH6154 Qhull precision error: Initial simplex is flat (facet 1 is coplanar with the interior point)While executing: | qhull d Qz Qt Qc Qbb Q12Options selected for Qhull 2019.1.r 2019/06/21: run-id 1401204984 delaunay Qz-infinity-point Qtriangulate Qcoplanar-keep Qbbound-last Q12-allow-wide _pre-merge _zero-centrum Qinterior-keep Pgood _max-width 40 Error-roundoff 4e-14 _one-merge 3.6e-13 Visible-distance 2.4e-13 U-max-coplanar 2.4e-13 Width-outside 4.8e-13 _wide-facet 1.4e-12 _maxoutside 4.8e-13precision problems (corrected unless 'Q0' or an error) 142 zero divisors during gaussian eliminationThe input to qhull appears to be less than 4 dimensional, or acomputation has overflowed.Qhull could not construct a clearly convex simplex from points:- p0(v5): 19 4.5 0 2.2- p36(v4): 0.095 20 0 3- p110(v3): -0.033 -20 0 3.1- p140(v2): 20 -0.14 0 3- p78(v1): -20 0.77 0 1.7The center point is coplanar with a facet, or a vertex is coplanarwith a neighboring facet. The maximum round off error forcomputing distances is 4e-14. The center point, facets and distancesto the center point are as follows:center point 3.912 1.025 0 2.595facet p36 p110 p140 p78 distance= 0facet p0 p110 p140 p78 distance= 0facet p0 p36 p140 p78 distance= 0facet p0 p36 p110 p78 distance= 0facet p0 p36 p110 p140 distance= 0These points either have a maximum or minimum x-coordinate, orthey maximize the determinant for k coordinates. Trial pointsare first selected from points that maximize a coordinate.The min and max coordinates for each dimension are: 0: -19.87 19.97 difference= 39.84 1: -19.97 19.97 difference= 39.94 2: 0 0 difference= 0 3: 0 19.97 difference= 19.97If the input should be full dimensional, you have several options thatmay determine an initial simplex: - use 'QJ' to joggle the input and make it full dimensional - use 'QbB' to scale the points to the unit cube - use 'QR0' to randomly rotate the input for different maximum points - use 'Qs' to search all points for the initial simplex - use 'En' to specify a maximum roundoff error less than 4e-14. - trace execution with 'T3' to see the determinant for each point.If the input is lower dimensional: - use 'QJ' to joggle the input and make it full dimensional - use 'Qbk:0Bk:0' to delete coordinate k from the input. You should pick the coordinate with the least range. The hull will have the correct topology. - determine the flat containing the points, rotate the points into a coordinate plane, and delete the other coordinates. - add one or more points to make the input full dimensional.Process finished with exit code 1No solution has yet been found
Hopes to find out the cause of the error and solve the problem