Abstract
Unsupervised clustering of curves according to their shapes is an important problem with broad scientific applications. The existing model-based clustering techniques either rely on simple probability models (e.g., Gaussian) that are not generally valid for shape analysis or assume the number of clusters. We develop an efficient Bayesian method to cluster curve data using an elastic shape metric that is based on joint registration and comparison of shapes of curves. The elastic-inner product matrix obtained from the data is modeled using a Wishart distribution whose parameters are assigned carefully chosen prior distributions to allow for automatic inference on the number of clusters. Posterior is sampled through an efficient Markov chain Monte Carlo procedure based on the Chinese restaurant process to infer (1) the posterior distribution on the number of clusters, and (2) clustering configuration of shapes. This method is demonstrated on a variety of synthetic data and real data examples on protein structure analysis, cell shape analysis in microscopy images, and clustering of shaped from MPEG7 database.
Introduction
Clustering objects by their "shape" is notoriously difficult because shape is a non-Euclidean property. If you rotate, scale, or move a curve, its shape remains the same, but its raw coordinates change drastically. Traditional clustering methods like K-means or Gaussian Mixture Models (GMMs) struggle here because they aren't naturally invariant to these transformations. Furthermore, most existing shape-clustering methods require the user to specify the number of clusters ($K$) in advance. In exploratory scientific fields—like analyzing new protein structures or identifying pathological cell deformations—the "true" number of groups is exactly what researchers are trying to discover. This paper introduces a model-based approach that handles the mathematical complexities of shape spaces while automatically inferring the most likely number of clusters.
Methodology
The proposed framework relies on three main pillars to achieve robust, invariant clustering:
- Square-Root Velocity Function (SRVF): This representation is the foundation for shape invariance. By representing curves as SRVFs, the complex "elastic" distance between shapes (which accounts for stretching and bending) simplifies into a standard $L^2$ distance. This representation is mathematically invariant to translation, scaling, and rotation.
- Modeling the Inner Product Matrix: Instead of defining a probability distribution over the infinite-dimensional space of all possible curves, the authors model the inner product matrix ($S$) of the data. This matrix captures the similarity between every pair of curves, significantly reducing computational burden by avoiding the repeated calculation of "Karcher means."
- Wishart-CRP Model: The matrix $S$ is modeled using a Wishart distribution. The scale matrix is decomposed as $\Sigma = \alpha(I + \theta B)$, where $B$ is a "membership matrix" defining cluster assignments. To allow the number of clusters to vary, the Chinese Restaurant Process (CRP) is used as a prior for $B$, which naturally favors a parsimonious number of clusters while allowing new ones to form as needed.
Inference is performed using a Markov chain Monte Carlo (MCMC) procedure, specifically Gibbs sampling, to explore the posterior distribution of cluster configurations.
Experimental Evaluation
The method was validated on a variety of datasets, ranging from computer vision benchmarks to biological structures.
MPEG-7 and Cell Shape Analysis
The MPEG-7 database contains various silhouettes (e.g., bones, hearts, tools) used to test shape recognition. The proposed method achieved a 100% classification rate and a Rand Index of 1.0, outperforming HMM-based methods (97.4%) and K-medians (81.5%). Additionally, the model successfully separated normal DLEX-p46 cells from pathological NIH-3T3 cells based purely on contour shape, identifying three meaningful sub-clusters where traditional methods only found two.
Protein Structure Analysis
The framework was applied to 3D coordinates of protein backbones from the SCOP (Structural Classification of Proteins) database. In a study involving 602 sequences, the model identified 38 distinct clusters with 84.1% accuracy compared to manual ground-truth labels. It successfully identified "outlier" structures that did not fit into major groups, demonstrating its utility for automated biological discovery.
Discussion and Conclusion
The authors highlight that standard Dirichlet Process Mixtures (DPM) of Gaussians can be inconsistent when estimating the number of clusters, often creating extraneous tiny clusters. Their Wishart-CRP approach on the inner product matrix appears more robust and provides a cleaner estimate of $K$.
However, limitations remain. The MCMC process involves sampling over a membership matrix, and for extremely large datasets, the $O(n^2)$ nature of the inner product matrix may become a bottleneck. Furthermore, parameters like cluster tightness ($\theta$) and CRP concentration ($\xi$) require careful selection to avoid over- or under-clustering. Future work may focus on streamlining the registration process for closed curves and improving computational scaling for massive datasets.
Summary updated