I am currently using the Delaunay function in scipy.spatial.Delaunay, like so (simplified):
import numpy as np
from scipy.spatial import Delaunay
points1 = np.random.rand(10,2)
points2 = np.random.rand(10,2)
tri = Delaunay(points1)
# tri2 = tri(points2)? - need help here
I would like to have the same triangulation applied to point2 - if I run Delaunay again I might get a different triangulation.
Is it possible to 'copy' one triangulation and apply it to a different set of points of the same size?
d.simplices
andd.neighbors
with whatever point array you want. – Davis HerringDelaunay
object, in its most basic usage (those two attributes), defines the topology of a triangulation whose geometry you already had (and provided as input). Whatever you want to do with the triangulation (e.g., render it) can be done by using that topology in conjunction with whatever geometry you like--the original is the obvious choice, but it makes no difference to use another of the same cardinality (so long as it's not "too different"). – Davis Herring