@_held_figure
def delaunay_plot_2d(tri, ax=None):
 if (tri.points.shape[1] != 2):
  raise ValueError('Delaunay triangulation is not 2-D')
 ax.plot(tri.points[:, 0], tri.points[:, 1], 'o')
 ax.triplot(tri.points[:, 0], tri.points[:, 1], tri.simplices.copy())
 _adjust_bounds(ax, tri.points)
 return ax.figure

@ _held_figure def delaunay_plot_2d ( tri , ax = None ) : if ( tri . points . shape [ 1 ] != 2 ) : raise ValueError ( 'Delaunay triangulation is not 2-D' ) ax . plot ( tri . points [ : , 0 ] , tri . points [ : , 1 ] , 'o' ) ax . triplot ( tri . points [ : , 0 ] , tri . points [ : , 1 ] , tri . simplices . copy ( ) ) _adjust_bounds ( ax , tri . points ) return ax . figure
plot the given delaunay triangulation in 2-d parameters tri : scipy .