arXiv cs.CV→ original

TopoGPU Computes Persistent Homology 53x Faster on Average

Researchers have introduced TopoGPU, a GPU pipeline that computes persistent homology for 2D and 3D images. It processes an image in chunks and leaves boundary matrix reduction on the CPU. On every benchmark, TopoGPU beat Cubical Ripser: by 53.24x on average and by up to 198.01x in total computation time. The authors built the method into a topology-preserving network, and training became cheaper. The code is open. • Average speedup: 53.24x, maximum 198.01x • Streaming GPU processing of image chunks • Binaries, Colab notebooks and Docker images are already available

AI-processed from arXiv cs.CV; edited by Hamidun News
TopoGPU Computes Persistent Homology 53x Faster on Average
Source: arXiv cs.CV. Collage: Hamidun News.
◐ Listen to article

Persistent homology is increasingly used in deep learning, but computing it inside a training loop is painfully slow. The authors of a new arXiv paper propose TopoGPU, a streaming GPU pipeline that builds persistence diagrams for cubical complexes generated from 2D and 3D images. Its competitor, Cubical Ripser, is considered one of the best existing implementations. TopoGPU outperformed it on every benchmark tested: by 53.24x on average in total (end-to-end) computation time, and by up to 198.01x. The code is open, with ready-made binaries, Google Colab notebooks and Docker images.

Where the bottleneck was

Persistent homology tracks how connected components, loops and cavities appear and disappear as the brightness threshold of an image changes. The output is a persistence diagram, a compact description of shape. In tasks such as segmentation, it is used as part of the loss function: the network is penalized for broken vessels or extra holes in the mask. But that means the diagram has to be recomputed at every training step. Cubical Ripser runs on the CPU, and on large 3D volumes the computation eats up a significant share of training time.

How the pipeline works

TopoGPU cuts the input image into chunks and feeds them to the GPU one at a time. Massively parallel kernels process each chunk on a grid of GPU blocks. The boundary relations they find accumulate in host memory, where the CPU then performs the boundary matrix reduction. The most parallelizable part of the work goes to the graphics card, while the sequential final step stays on the processor. Judging by the description, the streaming scheme does not require holding the entire volume on the GPU at once, although the abstract does not give exact memory limits.

The main technical idea relates to discrete Morse theory. It makes it possible to "collapse" a complex by removing pairs of cells without changing the homology, so the boundary matrix becomes noticeably smaller. The problem is that in streaming processing each chunk sees only part of the data, and naive Morse matching can distort the result. The authors introduce stratification-aware discrete Morse matching and prove that it preserves persistent homology under the streaming scheme. For GPU execution, they add parallel topological sorting and a parallel V-path parity algorithm that derives the Morse boundaries.

  • Average end-to-end speedup versus Cubical Ripser: 53.24x
  • Maximum speedup: 198.01x
  • Input data: 2D and 3D images, cubical complexes
  • Division of labor: the GPU builds boundary relations, the CPU reduces the matrix
  • License and distribution: open code, binaries, Colab, Docker

Who can use it

The authors tested the method in a topology-aware network and showed that the cost of computing persistent homology during training drops noticeably. This is the main practical takeaway. If your model uses topological losses, for example to segment thin structures in medical 3D scans, TopoGPU may remove the bottleneck without changing your training approach. With the ready-made Docker images and Colab notebooks, you can try it out in an evening.

There are caveats. The comparison is against Cubical Ripser, and the 53x and 198x figures depend on the benchmark set and on hardware, which the abstract does not describe. Matrix reduction stays on the CPU, so on complex data it may become the new limit. Before changing your pipeline, run TopoGPU on your own images and compare computation time at your own volume sizes, not just the average gain reported in the paper.

ZK
Hamidun News
AI news without noise. Daily editorial selection from 50+ sources. A product by Zhemal Khamidun, Head of AI at Alpina Digital.
✦ Hands-On AI Engineering

Build & Ship Production AI Apps with Vibe Coding

Join Zhemal Khamidun's hands-on Vibe Coding Intensive at hamidun.com/vibecoding — master Claude Code, Cursor, and autonomous agentic workflows.

Explore Vibe Coding →Vibe Academy Platform
What do you think?
Loading comments…