Table of Contents
Fetching ...

A Method for Auto-Differentiation of the Voronoi Tessellation

Sergei Shumilin, Alexander Ryabov, Serguei Barannikov, Evgeny Burnaev, Vladimir Vanovskii

TL;DR

This work delivers an end-to-end differentiable framework for the 2D Voronoi tessellation by exploiting the duality with Delaunay triangulation and introducing ghost points to manage infinite regions. The method computes $DT(S)$ for adjacency while constructing $V(S)$ through circumcenters, enabling backpropagation of gradients with respect to site positions. It supports bounded diagrams via differentiable clipping and controls retriangulation with a frequency parameter $r$, achieving a worst-case complexity of $O(m\,N\log N)$. The approach is demonstrated on tasks such as minimizing the variance of Voronoi region areas and optimizing hospital locations under a population density, illustrating practical impact for geometry-aware inverse problems.

Abstract

Voronoi tessellation, also known as Voronoi diagram, is an important computational geometry technique that has applications in various scientific disciplines. It involves dividing a given space into regions based on the proximity to a set of points. Autodifferentiation is a powerful tool for solving optimization tasks. Autodifferentiation assumes constructing a computational graph that allows to compute gradients using backpropagation algorithm. However, often the Voronoi tessellation remains the only non-differentiable part of a pipeline, prohibiting end-to-end differentiation. We present the method for autodifferentiation of the 2D Voronoi tessellation. The method allows one to construct the Voronoi tessellation and pass gradients, making the construction end-to-end differentiable. We provide the implementation details and present several important applications. To the best of our knowledge this is the first autodifferentiable realization of the Voronoi tessellation providing full set of Voronoi geometrical parameters in a differentiable way.

A Method for Auto-Differentiation of the Voronoi Tessellation

TL;DR

This work delivers an end-to-end differentiable framework for the 2D Voronoi tessellation by exploiting the duality with Delaunay triangulation and introducing ghost points to manage infinite regions. The method computes for adjacency while constructing through circumcenters, enabling backpropagation of gradients with respect to site positions. It supports bounded diagrams via differentiable clipping and controls retriangulation with a frequency parameter , achieving a worst-case complexity of . The approach is demonstrated on tasks such as minimizing the variance of Voronoi region areas and optimizing hospital locations under a population density, illustrating practical impact for geometry-aware inverse problems.

Abstract

Voronoi tessellation, also known as Voronoi diagram, is an important computational geometry technique that has applications in various scientific disciplines. It involves dividing a given space into regions based on the proximity to a set of points. Autodifferentiation is a powerful tool for solving optimization tasks. Autodifferentiation assumes constructing a computational graph that allows to compute gradients using backpropagation algorithm. However, often the Voronoi tessellation remains the only non-differentiable part of a pipeline, prohibiting end-to-end differentiation. We present the method for autodifferentiation of the 2D Voronoi tessellation. The method allows one to construct the Voronoi tessellation and pass gradients, making the construction end-to-end differentiable. We provide the implementation details and present several important applications. To the best of our knowledge this is the first autodifferentiable realization of the Voronoi tessellation providing full set of Voronoi geometrical parameters in a differentiable way.
Paper Structure (13 sections, 14 equations, 6 figures, 2 tables, 1 algorithm)

This paper contains 13 sections, 14 equations, 6 figures, 2 tables, 1 algorithm.

Figures (6)

  • Figure 1: On the left is the initial Voronoi tessellation of 500 random points. On the right the final Voronoi tessellation after optimizing the position of the site points. We iteratively optimize the placement of the site points to align the areas of the Voronoi regions. As a result we obtain the Voronoi regions with uniform areas. The Voronoi regions are shown red. Site points are not shown. There is no border so the site points may move any place. We make the infinite region finite and their corresponding site points are also optimized. We define the retriangulation step $r$.
  • Figure 2: Intersections of the Voronoi edges are the centers of circumcircles of Delaunay triangles. These are red points in the center of the circumcircles. Voronoi edges are shown in grey dashed lines. The Delaunay triangles are shown in bold black lines. For every border edge there is a ghost point that we place in order to process infinite edges and areas. For every border edge $e_i$ there is a vector $R$ that is perpendicular to $e_i$ and starts from the middle point of $e_i$. The corresponding ghost point is placed on this vector.
  • Figure 3: Principled scheme of the backward pass. Red blocks are differentiable. $DT(S)$ only provides adjacency information for derivation. We show $\psi$ as a differentiable parameters, however, it can be non-differentiable. The AD will make $\psi$ a leaf-node in the computational graph as well as $x$.
  • Figure 4: We set the border for the Voronoi tessellation as a unit square. Initially points randomly placed inside the border. The site points are not shown for visual concern. Only the Voronoi edges shown in red. The top-left figure shows the initial Voronoi tessellation. The initial areas of the Voronoi regions differ. The top-right figure shows the distribution of the areas of the Voronoi regions at the start. We optimize the placement of the site points $S$ in order to reduce the variance of the areas of the Voronoi regions. We do 1400 optimization steps using the Adam optimizer with the learning rate 0.001. Bottom-left figure shows the placement of the site points after the optimization. The bottom-right figure shows the distribution of the areas of the Voronoi regions after the optimization. The distribution converges to the theoretical value: unit square with 1000 points means 0.001 square unit per Voronoi region.
  • Figure 5: We solve the optimization problem described in \ref{['optimization']}
  • ...and 1 more figures