compute-geometry is a research-focused computational geometry library for Python. This library is designed to provide a set of tools and algorithms for solving geometric problems.
You can install the compute-geometry library using uv:
uv add compute-geometryimport cgeomHere are some examples to demonstrate how to use the Geometry library:
import numpy as np
from cgeom.algorithms import VoronoiDiagram
from cgeom.visualization import plot_voronoi
# load a set of points
points = np.loadtxt("examples/points1.txt")
# create a voronoi diagram object
voronoi = VoronoiDiagram(points)
# build the voronoi diagram
cells = voronoi.build_voronoi_diagram()
# plot the voronoi diagram
plot_voronoi(voronoi, cells)This library is licensed under the MIT License, allowing you to use, modify, and distribute it for both commercial and non-commercial purposes.
Start exploring the world of computational geometry with the compute-geometry library in Python!

