It's what you think it is.
A tool for generating, visualizing, and processing geometric Voronoi diagrams.
The following Python packages must be installed to use this utility.
- numpy
- numpy-stl
- scipy
- matplotlib
-
Clone the repository.
git clone https://github.com/donsheehy/VoronoiWall.git
-
Move into the project directory.
cd VoronoiWall
-
Build and install the package.
python setup.py install
-
Import and use the project like any Python package.
import VoronoiWall as vw
The example driver program allows testing various functionality of the library.
Given a set of input points, the example driver will:
- Generate a Voronoi diagram data structure
- Generate an STL mesh object encoding the Voronoi facets
- Display the Voronoi diagram using matplotlib
- Optionally, output the mesh to an STL file
To execute the example driver, follow the instructions below.
-
Navigate to the examples directory.
cd VoronoiWall/examples
-
Run the driver program, providing an input file and optionally an output file.
python example_driver.py input_file [output_file]
Some sample input files are provided:
python example_driver.py input-random-50.txt random-50.stl python example_driver.py input-random-10.txt