Generative modeling of biological shapes and images using a probabilistic α -shape sampler

Emily T. Winn-Nuñez, Hadley Witt, Dhananjay Bhaskar, Ryan Yuki Huang, Jonathan S. Reichner, Ian Y. Wong, Lorin CrawfordbioRxiv 2024 · DOI

TL;DR

The $\alpha$-shape sampler is a new probabilistic framework designed to generate realistic 2D and 3D biological shapes from small, real-world datasets. Unlike "black-box" generative models, this approach provides a transparent, mathematically grounded way to simulate morphological variation, enabling researchers to better benchmark computational tools in fields like cell biology and morphometrics.

What Problem Does This Paper Address?

In computational biology, understanding how shapes vary—such as the difference between a healthy cell and a diseased one—is crucial. However, researchers face two major hurdles:

  1. Data Scarcity: High-quality biological shape data (like 3D CT scans) is expensive and time-consuming to collect, often resulting in very small sample sizes.
  2. The "Black Box" Problem: Modern generative models (like GANs or diffusion models) can create realistic images, but they are often difficult to interpret. This makes it hard to systematically test how well a new analysis tool performs because the underlying "ground truth" of the generated shapes is obscured.

The authors address this by creating a generative pipeline that is both statistically transparent and capable of learning from limited "reference" shapes.

Methods

The core of the framework relies on $\alpha$-shapes, a way to represent a shape using a "simplicial complex" (a collection of points, edges, and triangles). The "$\alpha$" parameter controls the level of detail: a small $\alpha$ might result in a cloud of disconnected points, while a large $\alpha$ creates a coarse, filled-in shape.

Key innovations include:

  • Data-Driven Reach Estimation: The authors introduce a scalable algorithm to estimate the "reach" ($\tau$) of a shape—a concept from differential geometry that describes how much a shape can bend before it self-intersects. They theoretically link this reach to the optimal $\alpha$ parameter for reconstruction.
  • Probabilistic Sampling: Instead of just interpolating between shapes, the sampler combines point clouds from multiple reference objects and uses a "rejection-sampling-like" rule. It accepts new points based on the local density of the reference data, ensuring the new shape stays "close" to the underlying biological manifold without simply mimicking a single input.

Datasets

The authors validated the sampler across four distinct scenarios:

  • Simulated 2D Annuli: A toy dataset of 50 ring shapes to test homology (ensuring the model preserves the "hole").
  • Simulated 3D Tori: 50 donut shapes to test 3D geometric preservation.
  • Primary Human Neutrophils: 2D phase microscopy images of healthy vs. septic immune cells. This tested the model's ability to capture complex biological textures like "ruffling."
  • Primate Mandibular Molars: 3D CT scans of teeth from two primate genera (Microcebus and Tarsius). This evaluated the model's ability to preserve specific evolutionary features, like the paraconid cusp.

Key Insights and Ideas

  • Transparency over Complexity: By using $\alpha$-shapes and reach estimation, the model provides a clear mathematical path from input data to generated output. This allows researchers to know why a generated shape looks the way it does.
  • Reach as an Outlier Detector: The estimated reach ($\tau$) can be used as a quality-control metric. If a reference shape has a wildly different reach than the rest of the group, it’s likely an outlier or a poor-quality scan that should be pruned before generation.
  • Preserving Topology: The sampler is remarkably good at preserving the "homology" (the number of holes and connected components) of the input data, which is often a failure point for traditional image-based generative models.

Key Results

  • Biological Realism: In the neutrophil study, the sampler successfully generated "septic" cells that were larger and more elongated than "healthy" ones, matching the real-world biological observations.
  • Feature Fidelity: For the primate teeth, the model accurately reproduced the paraconid cusp—a specific dental feature found in Tarsius but not in Microcebus—demonstrating that it captures fine-grained morphological traits.
  • Statistical Alignment: Using dimensionality reduction (PHATE and MRAE), the authors showed that the generated shapes cluster tightly with the real reference shapes, proving they are statistically representative of the original classes.

Limitations and Future Work

The authors note a few areas for improvement:

  • Alignment Sensitivity: The sampler performs best when input shapes are well-aligned. For cells (which lack clear landmarks), the model sometimes produced "chimeras"—shapes that combine features of two very different cells in a way that might not be biologically plausible.
  • Uniformity Assumption: The current math assumes points are sampled uniformly across the shape's surface. If a scan is highly detailed in one area but sparse in another, the reach estimation becomes less precise.
  • Future Directions: The team aims to extend the pipeline to "weighted" $\alpha$-shapes to handle multi-scale features and explore "$\beta$-shapes" for even broader applications in structural biology.

The $\alpha$-shape sampler is available as an open-source R package on GitHub.

Summary updated

Abstract

Understanding morphological variation is an important task in many areas of computational biology. Recent studies have focused on developing computational tools for the task of sub-image selection which aims at identifying structural features that best describe the variation between classes of shapes. A major part in assessing the utility of these approaches is to demonstrate their performance on both simulated and real datasets. However, when creating a model for shape statistics, real data can be difficult to access and the sample sizes for these data are often small due to them being expensive to collect. Meanwhile, the current landscape of generative models for shapes has been mostly limited to approaches that use black-box inference-making it difficult to systematically assess the power and calibration of sub-image models. In this paper, we introduce the <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML"><mml:mi>α</mml:mi></mml:math>-shape sampler: a probabilistic framework for generating realistic 2D and 3D shapes based on probability distributions which can be learned from real data. We demonstrate our framework using proof-of-concept examples and in two real applications in biology where we generate (<i>i</i>) 2D images of healthy and septic neutrophils and (<i>ii</i>) 3D computed tomography (CT) scans of primate mandibular molars. The <mml:math xmlns:mml="http://www.w3.org/1998/Math/MathML"><mml:mi>α</mml:mi></mml:math>-shape sampler R package is open-source and can be downloaded at https://github.com/lcrawlab/ashapesampler.
BibTeX
@misc{winnnunez2024generative,
  author = {Emily T. Winn-Nuñez and Hadley Witt and Dhananjay Bhaskar and Ryan Yuki Huang and Jonathan S. Reichner and Ian Y. Wong and Lorin Crawford},
  title = {{Generative modeling of biological shapes and images using a probabilistic <i>α</i> -shape sampler}},
  year = {2024},
  doi = {10.1101/2024.01.09.574919},
  howpublished = {bioRxiv},
}
Figure