Skip to content
Discussion options

You must be logged in to vote

Another options is to put points in 2D or 3D space, then pass those to the Voronoi class. For instance, if you generate a triangular lattice of points using PoreSpy (see example here), with a radius of 1 to get points instead of spheres, then you can use pts = np.where(~im) to get the x,y locations of each point (in voxels). Passing these into the Voronoi class should generate the hexahedral grid above. It also occurs to me that if you use the DelaunayVoronoiDual class you will get the triangular mesh as the combination of delaunay and voronoi networks, plus the interconnections. I haven't tried this myself, but I'm 99% sure it should just work.

Replies: 2 comments 4 replies

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
4 replies
@jgostick
Comment options

@mourendong
Comment options

@jgostick
Comment options

@mourendong
Comment options

Answer selected by mourendong
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants