environmentaltools.graphics.plot_voronoi_diagram

environmentaltools.graphics.plot_voronoi_diagram(vor, bounding_box, fname=False)[source]

Plot Voronoi diagram with vertices and regions.

Visualizes a Voronoi tessellation showing input points, region vertices, and boundaries within a specified bounding box.

Parameters:
  • vor (scipy.spatial.Voronoi) – Voronoi diagram object with attributes: - filtered_points: Input points used for tessellation - filtered_regions: List of region vertex indices - vertices: Coordinates of Voronoi vertices

  • bounding_box (tuple or list) – Box limits as (xmin, xmax, ymin, ymax).

  • fname (str or bool, optional) – Filename to save the figure. If False, doesn’t save. Defaults to False.

Returns:

(fig, ax) - Figure and axes objects.

Return type:

tuple