Table of Contents
Fetching ...

Cubical Ripser: Software for computing persistent homology of image and volume data

Shizuo Kaji, Takeki Sudo, Kazushi Ahara

TL;DR

Cubical Ripser extends persistent homology computations to weighted cubical complexes derived from images and volumes, addressing a gap where traditional Ripser targets point-cloud data. It provides a cohomology-based reduction algorithm tailored to cubical cells, enabling fast, memory-efficient computation of PH in 1D–3D data and offers Python bindings for easy integration with machine learning workflows. The paper benchmarks Cubical Ripser against DIPHA, demonstrates practical preprocessing and localised PH features (e.g., lifetime-enhanced images, persistent histogram images), and shows that PH features can modestly aid CNN-based classification in 2D while enabling a pipeline for combining global topological information with deep learning. The tool is open-source and designed to facilitate rapid access for practitioners, with a discussion of limitations and comparisons to other software.

Abstract

We introduce Cubical Ripser for computing persistent homology of image and volume data (more precisely, weighted cubical complexes). To our best knowledge, Cubical Ripser is currently the fastest and the most memory-efficient program for computing persistent homology of weighted cubical complexes. We demonstrate our software with an example of image analysis in which persistent homology and convolutional neural networks are successfully combined. Our open-source implementation is available online.

Cubical Ripser: Software for computing persistent homology of image and volume data

TL;DR

Cubical Ripser extends persistent homology computations to weighted cubical complexes derived from images and volumes, addressing a gap where traditional Ripser targets point-cloud data. It provides a cohomology-based reduction algorithm tailored to cubical cells, enabling fast, memory-efficient computation of PH in 1D–3D data and offers Python bindings for easy integration with machine learning workflows. The paper benchmarks Cubical Ripser against DIPHA, demonstrates practical preprocessing and localised PH features (e.g., lifetime-enhanced images, persistent histogram images), and shows that PH features can modestly aid CNN-based classification in 2D while enabling a pipeline for combining global topological information with deep learning. The tool is open-source and designed to facilitate rapid access for practitioners, with a discussion of limitations and comparisons to other software.

Abstract

We introduce Cubical Ripser for computing persistent homology of image and volume data (more precisely, weighted cubical complexes). To our best knowledge, Cubical Ripser is currently the fastest and the most memory-efficient program for computing persistent homology of weighted cubical complexes. We demonstrate our software with an example of image analysis in which persistent homology and convolutional neural networks are successfully combined. Our open-source implementation is available online.

Paper Structure

This paper contains 5 sections, 1 equation, 5 figures, 3 tables.

Figures (5)

  • Figure 1: 0- and 1-cells and their cofaces in a 2-dimensional image. The numbers in the boxes indicates the function value. Our convention is that the coordinates of the upper-left voxel is $(0,0,0)$ and that of the cell to the right is $(1,0,0)$.
  • Figure 2: 0-th persistence of a 2D image. From left to right, in the sublevel set $\phi \le -2$ a connected component is born, in $\phi \le -1$ two other connected components are born, in $\phi \le 1$ the upper one with birth-time $-1$ is killed and merged into the one with birth-time $-2$, in $\phi \le 2$ the right one with birth-time $-1$ is killed. Therefore, the 0-th barcodes are $[-2,\infty), [-1,1)$, and $[-1,2)$.
  • Figure 3: A binary image (left) and its distance transform with respect to the $L^1$-norm (right)
  • Figure 4: Lifetime enhanced image: the original greyscale images is displayed as the red channel, the $d=0$ lifetime image is displayed as the green channel, and the $d=1$ as the blue channel.
  • Figure 5: Reduced MNIST classification results: (Left) accuracy and Top-2 accuracy measured twenty times, (Right) breakdown for each class