Content uploaded by Tegan Emerson
All content in this area was uploaded by Tegan Emerson on Dec 21, 2018
Content may be subject to copyright.
Exploring 2D shape complexity
Erin Chambers, Tegan Emerson, Cindy Grimm, Kathryn Leonard
In this paper, we explore diﬀerent notions of shape complexity, draw-
ing from established work in mathematics, computer science, and com-
puter vision. Our measures divide naturally into three main categories:
skeleton-based, symmetry-based, and those based on boundary sampling.
We apply these to an established library of shapes, using k-medoids clus-
tering to understand what aspects of shape complexity are captured by
each notion. Our contributions include a new measure of complexity based
on the Blum medial axis, and the notion of persistent complexity as cap-
tured by histograms at multiple scales rather than a single numerical
Quantifying shape complexity and similarity has a rich history in many ﬁelds of
mathematics and computer science, including work in ﬁelds such as diﬀerential
geometry, topology, computational geometry, computer graphics, and computer
vision. This paper draws measures common to several of those ﬁelds in order
to compare and contrast their ability to capture complexity of a variety of two-
dimensional shapes, as well as introducing a new approach to complexity based
on measures taken along the Blum medial axis.
1.1 Prior work on shape complexity
Several examples of prior work on shape complexity draw from the information
theoretic framework. For example, in [CS05], the authors consider a notion of
complexity based on computing measures related to the Kolmogorov complexity
of a set of sample points from the boundary of the contour. This method has
the advantage of calculating a single complexity value which in practice does
well at distinguishing between various classes of shapes, in agreement with a
user study. Unfortunately, it is extremely diﬃcult to classify exactly what is
being measured given the loose connection to Kolmogorov complexity, which is
Similar work in computer vision has taken a diﬀerent approach, quantifying
complexity by how diﬃcult it is to capture or cover the shape by simpler ones.
For example, in [PA16], the authors measure complexity by attempting to de-
termine how many ellipses are necessary to cover a 2D shape. They compute
the medial axis for each edge, prune to reduce noise, then calculate an entropy
in order to determine how many ellipses are necessary to cover the total area as
closely as possible. The basic premise is that a shape requiring more ellipses,
or one resulting in less coverage with more ellipses, will correspond to a more
In [CI84], the authors focus on a classical computational geometric measure
of complexity, namely deciding how quickly they can triangulate a given input
polygon. While of theoretical interest, this measure does not translate to a
richer notion of shape complexity.
Curvature of the boundary appears in several complexity measures. In
[JF05], the authors determine which regions of a particular contour are more
”surprising” in a probabilistic sense, ﬁnding that regions of negative curvature
carry more information than those of positive curvature of the same magnitude.
Similarly, [PKS+03] deﬁnes probability distributions of curvatures in order to
assign an entropy to each shape. A discretization-independent approach of the
same idea can be found in [RFS05]. In [Leo07], total curvature of the boundary
gives the adaptive codelength for a contour, where one may view codelength as
a proxy for complexity. One drawback to the curvature-based derivations, how-
ever, is their lack of robustness to noise or small-scale detail on the boundary
which can dramatically alter curvature distributions.
It is also worth mentioning work that attempts to classify the complex-
ity of 3-dimensional objects, even though our work focuses on the 2D setting.
In [OFCD02], for example, the authors propose a signature for an object as
a shape distribution, which is a similar idea to how we approach the problem
in the 2D setting, but their shape function primarily measures local geometric
properties of an object. Similarly, in [SPG+06] the authors use curvature-based
and information theoretic measures to classify 3d shapes, although in this work
they focus on shape segmentation and identiﬁcation of prominent features, while
our work focuses on classifying overall shape complexity.
1.2 Our contribution
The purpose of this work is to lay the foundation for a deﬁnition, or collection
of deﬁnitions, of shape complexity that captures the full range of its natural
dimensions. To do so, we explore several classical complexity measures and
introduce a skeleton-based measure. Our main contribution is the idea of a
persistent measure of shape complexity, which examines complexity as a shape
is eroded into its least complex approximation. Complexity is then captured by
a collection of values or histogram rather than a single value.
The measures we implement below divide naturally into three categories:
skeleton-based, symmetry-based, and boundary sampling measures. For the
boundary approach, we extract measures as the boundary is downsampled,
which allows us to diﬀerentiate persistent from transient sources of complex-
We begin with Section 2, which establishes the context for our exploration
and provides an initial foray into general principles of shape complexity. Section
3 describes the complexity measures we use, with results from clustering based
on those measures displayed in Section 4. Finally, we discuss our results and
future directions to explore in Section 5.
2 Deﬁning complexity
As with many attributes assigned to shapes, the complexity of a given shape
seems intuitively straightforward but computationally elusive. We believe a few
principles should be satisﬁed in any reasonable deﬁnition of 2D shape complex-
1. A circle should have the minimum complexity.
2. Adding a part to a shape that is diﬀerent from all existing parts should
3. A shape with parts that are self-similar should be less complex than a
shape with the same number of parts where the parts are dissimilar.
4. Shapes, together with a complexity measure, should be a partially ordered
The above form an objective measure for shape complexity, independent of
a particular setting. In addition to exploring objective measures we are also
interested in deﬁnitions of complexity that are useful in a particular setting.
The next section explores the idea of domain-dependent complexity, and how
that might result in diﬀerent deﬁnitions or representations.
2.1 Qualitative complexity
We outline here two possible qualitative methods of deﬁning what complexity
means, and how those methods might relate to speciﬁc tasks or applications.
In this we take the view that deﬁning a complexity measure is not completely
independent of what you are using that measure for. For example, one measure
might capture how diﬃcult a shape is to build, while another might better
capture how diﬃcult it is for a human to recognize or classify a set of shapes.
2.1.1 Construction deﬁnition
This deﬁnition derives from the idea of procedural modeling [MWZ+14, SW15]
— specifying a sequence of operations that create the shape in question. Com-
plexity is a measure of how deep the tree of operations has to be; conversely,
the further down the tree you go the more complex the object. Obviously, this
depends on the set of available operators. We outline here a plausibly complete
set of operators and a few examples of how a shape could be constructed from
those operators. Note that there may not be a single, unique set of operations
for each shape.
Figure 1: A possible set of construction operators. This set is complete, but
Potential tasks or applications include shape representation, modeling, func-
tional shape comparison, and part decomposition. This is also a representational
deﬁnition, in that the encoding of the shape as a tree of operations means that
the shape can be recovered from the complexity measure. The deﬁnition is also
partially semantic, in that the operators form a language for describing shape.
The operators are illustrated in Figure 2.1.1. The assumption is that the
base shape is a circle. The operators are:
•Protrusions: Add one (or a pattern of) protrusions/extrusions.
•Pockets: Add one (or a pattern of ) pockets or indents
•Add handle: Add a handle/join a protrusion to the shape/close oﬀ a
•Bends: Bend or curve a protrusion or pocket to re-shape it.
•Sharpen or soften: Change the curvature along the boundary to produce
a feature (such as a corner or edge).
•Detail pattern: Add a regular or semi-regular pattern to some (or all) of
the boundary at a small scale (relative to the overall size of the shape).
In Figure 2.1.1 we show an example of applying the operators to produce one
of our test shapes. Note that there is a natural mapping between the operators
and skeleton editing.
Figure 2: Example construction sequence of two shapes from our data set. Note
that the construction order need not be unique — the heart top, for example,
can be seen as either a pocket or two protrusions.
2.1.2 Predictability deﬁnition
This deﬁnition is very perceptual or experience based. The essential notion is
that complex shapes both surprise us and require more thought or eﬀort to re-
member well enough to reproduce. For example, although a drawing of a horse
is fairly complex from a total curvature or parts standpoint, it is easily mapped
to a canonical image of a horse in our head. Similarly, a shape might consist
of self-similar or repeating patterns (for example, a Julia set or a symmetric
shape with a pattern added to the boundary) in which case, while the geom-
etry is complex, the mental image of it is not. On the other hand, a random
pattern (such as the blob in the top row of Figure 11) might be fairly simple
geometrically, but complex because it does not map to any template image in
Essentially, the complexity is a measure of how much the given shape de-
viates from a canonical set of template shapes. Possible applications or tasks
related to this deﬁnition are template matching, shape classiﬁcation, and sta-
bility of shape.
2.2 Evaluating quantitative measures of complexity
In the previous sections we presented both existing quantitative, global measures
of complexity from the literature, and two hypothetical qualitative measures of
complexity. In Section 3 we will deﬁne several families of complexity measures
using the notion of sampling and resulting histograms. The questions that link
our qualitative deﬁnitions to our quantitative ones are: How do we identify
quantitative measures that match our qualitative measures of complexity? How
do measures diﬀer in how they deﬁne complexity? In this work, we use clustering
as a ﬁrst step to answering these questions.
It is likely that complexity is not a 1D, well-deﬁned metric, which means
that simply ranking shapes from low-complexity to high-complexity with one
global measure may not be appropriate, particularly if we want to use multi-
ple measures to capture diﬀerent aspects of complexity. We therefore perform
unsupervised clustering on a particular measure or set of measures. An eﬀec-
tive measure, or set of measures, is one which consistently groups shapes with
certain recognizable complexity features with a recognizable similarity in com-
In the following section we describe our shape dataset and deﬁne our com-
plexity measures. In Section 4 we describe our clustering algorithm and display
the resulting clusters.
Given a particular quantitative measure, we can apply it either to the entire
shape to obtain a global measure, or to the shape at diﬀerent sampling rates
to determine the scales at which certain values of the measure persist. We
take as global measures four quantities derived from the medial axis represen-
tation [MGM05, Leo07, LCLJ11], which are computed on each medial branch
and three quantities measured on the boundary curve. The measures taken at
diﬀerent sampling rates, so-called sampling measures, are quantities that cap-
ture the changes in the shape as the resolution of the shape is decreased. We
employ two methods for downsampling the shape: boundary point subsampling
and image-based subsampling.
Although the boundary of the shape and its interior are linked, some mea-
sures focus primarily on measuring how the boundary changes (e.g., curvature)
while others are more concerned with the interior shape (covering the shape
with a set of ellipses). Some, such as the medial axis measures, capture both.
We store the sampling measures and the medial axis measures taken across
branches as histograms (n= 10 bins), rather than computing statistics such as
the mean or measuring entropy [CS05], to preserve the variation in the data.
3.1 Shape data base
We use the MPEG-7 database [Bob01] taking one shape from each of the 70
classes, as well as all shapes in a devices class that allows us to understand how
complexity varies as a very regular shape is perturbed in diﬀerent ways. All
shapes are represented as a single closed curve, ignoring interior detail. The orig-
inal images are 256 by 256 with the boundary curves extracted for [LMHC16].
This results in around 500 points per shape. We resample the boundary curves
using arclength parameterization and normalize the scale of the shape to ﬁt in
the unit square.
To calculate the curvatures we use the formulation in [MS08] which is based
on the angle change over the length. The arclength parameterization and scaling
to the unit square together keep the curvatures in roughly the range -100 to 100.
3.2 Global measures
We include four global measures from the literature: Ratio of perimeter length
to area, total curvature [Leo07], object symmetries [MGM05], and salience
measures on the medial axis such as erosion thickness and shape tubularity
[LCLJ11]. From the domain-independent standpoint, ratio of perimeter length
to area, symmetries, and the medial axis measures capture in various ways how
far a shape has deviated from a circle. The medial axis and symmetry measures
also capture self-similarity of parts. From the domain-dependent standpoint,
total curvature captures the bending and sharpen/soften operations, the ratio
of perimeter length to area captures protrusions, pockets, and handles, and the
medial axis measures capture an aspect of each of the operations. Predictabil-
ity is captured in a simplistic way by object symmetries, but requires a full
probabilistic study of shape occurrence that we do not take up here.
3.2.1 Skeleton measures
We compute the Blum medial axis corresponding to the boundaries of the shapes
at the full sampling rate, and compute several salience measures on the axis.
The Extended Distance Function (EDF) measures the depth of each medial
point within the shape, where depth is deﬁned as the second longest geodesic
distance along the axis from a given point to the boundary curve [LCLJ11].
The Weighted Extended Distance Function (WEDF) measures another kind of
depth, where the depth is the area of the part of the shape subtended by a
particular medial point [LMB+15]. The Erosion Thickness (ET) measures how
blob-like a shape is at a particular point [LCLJ11] and the Shape Tubularity
(ST) measures how tube-like it is [LCLJ11]. The values of these measures vary
continuously across primary branch points, but will exhibit discontinuities mov-
ing from a primary branch to a secondary branch. In this way, the measures
taken together provide a picture of the morphology and relative size of the var-
ious shape parts comprising the shape [LMHC16]. See Figure 3 for an example
of a hand contour and the variation of its ST, ET, WEDF, and EDF values.
We sample the WEDF, EDF, ST, and ET at medial branch points and their
neighbors, as these are the locations of the discontinuities that characterize the
shape parts. We normalize the histograms of ET and ST, but leave the WEDF
and EDF histograms as raw counts in order to preserve information about the
number and types of branches within the shape. Note that when we combine
all measures together, we normalize EDF and WEDF to prevent their values
from dominating the clustering.
Figure 3: Heat maps showing values of measures taken from the medial axis.
From left to right: EDF, a length-based depth; WEDF, an area-based depth;
ET, a measure of how blob-like a region is; and ST, a measure of how tube-like
a region is.
Figure 4: Downsampling the boundary. Top row, from left to right: Decreasing
the number of points used to represent the boundary (500, 100, 50, 25 and 8).
Bottom row: Shifting the starting point by 4 for the 4th image above (5 shifts
3.3 Sampling-based measures
We employ two sampling approaches, one based on downsampling the boundary
itself and the other downsampling the area enclosed by the boundary. We ﬁrst
describe the downsampling approaches then the measures we calculate on the
downsampled data. In general, boundary downsampling reduces the complexity
of the boundary by reducing the number of points used to represent it (not
smoothing), while area downsampling uses bigger and bigger blocks to represent
the area coverage of the shape.
3.3.1 Boundary downsampling
To downsample the boundary, we linearly approximate the boundary using a
reduced number of points (5 levels - 500, 100, 50, 25 and 8). For our shapes
this represents the spectrum from roughly full resolution to a convex shape (see
Figure 4). We use arclength sampling, dividing the original curve into equal-
length segments. Because the starting point inﬂuences the downsampled shape
we compute multiple downsampled versions, each with a shifted starting point
(by 4 points). We then average (values) or sum (histograms) the measures
as appropriate for each of the downsampled versions at that level. Table 1
summarizes the downsampling values.
When downsampling we also record which segment corresponds to each orig-
inal point in order to calculate the distance from the original points to the
3.3.2 Area downsampling
We begin by scan-converting the original boundary curve into a 256×256 image
Iwith 16 pixels of padding on all sides. We downsample by placing a grid with
an npixel neighborhood (n∈[2,4,8,16]) on top of I. We store two values per
grid cell: a binary value indicating whether or not the grid cell overlaps Iat all,
No. Points 500 100 50 25 8
No. Shifts 1 2 3 5 16
No. Pixels 128X128 64X64 32X32 16X16
No. Shifts 1 2 4 8
Table 1: Sampling rates. The Grid pixel count does not include an extra padding
of 1 pixel around the boundary.
Figure 5: Downsampling using a grid. The largest image is the original 256X256
image. Images are downsampled, with a shift added (all eight images for the
lowest resolution are shown enlarged).
and the percentage of the overlap. As in the boundary case, we shift the grid
starting point (2 pixels in each direction) and combine the results (see Table 1.
Resulting images are shown in Figure 5.
3.3.3 Boundary measures
We normalize the measures, where appropriate, by dividing by the same quantity
associated to the original, fully sampled shape. Continuous values are stored
as histograms. Denote by dithe distance from each of the original points to
the closest point on the corresponding segment of a downsampled boundary.
Three measures use the Voronoi diagram and Delaunay triangulation, which
are computed from the downsampled boundary. More precisely, we calculate:
•Length of downsampled boundary / Length of original boundary. This
captures the depth of protrusions and pockets and how many there are.
•Area enclosed by the downsampled boundary / Area of original boundary.
This captures the area of protrusions and pockets.
•L2norm on the approximation error produced by down-sampling: mean
of di. This captures the average distance of the original shape boundary
from successively simpler (more convex) versions of itself.
•Hausdorﬀ norm on the approximation error produced by downsampling:
max of di. This captures the maximum deviation of the original shape
boundary from successively simpler (more convex) versions of itself.
•Distribution of di(histogram). Bins are evenly spaced between 0 and
0.1, then at 0.5 and the maximum of di. The captures the variability in
distances between the original shape and successively simpler versions of
•Distribution of curvature (histogram). Bins are evenly spaced after taking
arc-tan (so-called Shape Index [KvD92]). This captures the persistence of
high curvature regions as the shape is simpliﬁed.
•Distribution of edge lengths in the Voronoi diagram. This provides a
measure of the average aspect ratios of shape parts.
•Distribution of triangle areas in the Delaunay triangulation. This captures
the percentage of smaller components to larger components in the shape.
•Percentage of Voronoi cell centers that lie inside the shape versus outside.
This is a measure of how non-convex a shape remains as it is simpliﬁed.
The boundary measures, in general, provide information about the size,
number, shape, and depth of protrusions. By using downsampling we can ad-
ditionally capture how “stable” those protrusions are — i.e., how quickly they
3.3.4 Moment measures
In order to capture a coarse self-similarity measure, we compute the seven com-
plex moment invariants described in [MGM05] at the diﬀerent boundary down-
sampling scales. Taken together, these moments capture all rotational symme-
tries. Note that these will not reﬂect the addition operations such as protrusions,
as long as they are added along all axes of symmetry; however, any additions
that are not symmetric will change the moment measures quite drastically. In
other words, the moment measures capture an aspect of the self-similarity of
the parts comprising a shape, one of our domain-independent complexity tests.
3.3.5 Area measures
We store the area of the occupied downsampled image over the occupied area in
the original image. Note that this measure tends to increase while the area based
on downsampling the boundary tends to decrease, and is potentially better at
capturing the shape of pockets versus protrusions, and also their alignment with
respect to the overall shape. We also store the distribution of occupied pixels
as a histogram.
In order to interpret what the diﬀerent complexity measures capture, we perform
k-medoids clustering using each set of measures as feature vectors. K-medoids
is a distance-based, unsupervised learning algorithm that groups the data set
into kclusters. Unlike its sister, the k-means algorithm, k-medoids requires
that the centroid of each cluster (the point to which distances are being com-
puted and compared) be a sample from the data set. In many applications this
forcing of the centroid to be a sample from the data allows for more signiﬁcant
The standard Euclidean distance is used to determine cluster membership
in the clustering results. For all clusterings illustrated we have let k= 6. This
number was determined based on comparing the average within-cluster distance
sum across clusterings produced for kranging from 1 to 15. When kis equal
to the number of points in the data set the within-cluster distance sum is zero
since each point is its own centroid. Reasonable values of kcan be identiﬁed by
looking for an elbow in the graph of average within-cluster distance sum versus
k. For the diﬀerent feature vectors considered, the elbow occurred between k= 3
and k= 7 in the majority of trials. For the sake of comparing the results across
diﬀerent feature vectors more smoothly we ﬁxed k= 6. We note that there
are more complex ways of identifying “optimal” cluster numbers that consider
both the within-cluster distance and across-cluster separation. However, for our
purposes the within-cluster measure appears suﬃcient. In future work a more
thorough analysis may be performed, allowing for diﬀerent numbers of clusters
for each set of feature vectors.
Results of the clusterings shown herein are based on running 50 trials of
k-medoids for each feature vector set and selecting the one with the smallest
within-cluster distance sum. Figures 8, 12, 14, 10, 6, 16, and 18 show the 6
diﬀerent medoids chosen for each of the feature vector sets. These medoids
are color-coded to provide cluster membership information in the full clustering
results shown in Figures 9, 13, 15, 11, 7, 17, and 19. In these ﬁgures the medoid
of each cluster is the ﬁrst shape for each new cluster color and has been given a
black border. The subsequent shapes in a given color are ordered from closest
to farthest from the medoid as measured by Euclidean distance.
The diﬀerent sets of feature vectors considered are produced as follows. We
group the features according to their appearance in Section 3.
– Non-skeleton global feature vectors: The global clusters use a
feature vector that is 12-dimensional. Included in the feature vector
are the seven moment measures computed at the full scale of the im-
age and also boundary length to area ratio, total curvature, curvature
entropy, angular entropy, and distance to original entropy. This set
of feature vectors are based exclusively on the complete sampling of
the shape and complexity values that can be found in existing litera-
ture. Figures 6 and 7 show the cluster centroids and entire clustering
based on the global feature vectors.
– Skeleton feature vectors: The skeleton feature vectors are com-
posed of histograms of the ET and ST values at all branch points
and neighbors of branch points. Separate histograms are produced
for ET, ST, and each point type. The ET/ST values are all normal-
ized relative to the max ET/ST for the speciﬁc shape and then the
histogram is normalized based on the total number of points (branch
or neighbor points) being considered. EDF and WEDF are also com-
puted for branch points and neighbor points. The values are scaled
relative to the maximum value of EDF/WEDF, but the number of
points are not normalized in order to preserve information about the
number of branches in each bin. This results in 40-dimensional skele-
ton based feature vector. The cluster centroids for the clustering
built on the skeleton feature vectors are shown in Figure 8 and the
full clustering is shown in Figure 9.
– Boundary feature vectors: Boundary features are all computed at
the ﬁve diﬀerent downsampling scales. Four values are histogrammed
into ten bins for each value as described in Section 3.3.3. Another
four values are computed at each scale, also listed in Section 3.3.3.
Consequently, the boundary feature vectors are 220-dimensional (5
scales x (4 histogrammed values x 10 bins per histogram + 4 non-
histogrammed values)=220). Results of clustering on the boundary
feature vectors and the cluster centroids are contained in Figures 11
and 10 respectively.
– Moment feature vectors: The moment measures considered are
the seven values described in [MGM05]. These seven values are com-
puted at the ﬁve diﬀerent boundary down-sampling scales. This re-
sults in a 35-dimensional feature vector for each shape that we use to
cluster on. Cluster centroids for clustering on the moment measure
feature vectors are shown in Figure 12 and the complete clustering
is shown in Figure 13.
– Coverage feature vectors: The coverage feature vector is 44-
dimensional and consists of one non-histogrammed value (area change)
and one histogrammed value (pixel occupied distribution, 10 bins)
for each of the four down-samplings. Centroids for each cluster and
the full clustering based on the coverage measure feature vectors are
provided in Figures 14 and 15, respectively.
•Concatenation of Global and Sampling Measures
– With moments: Clusterings based on concatenated sets of feature
vectors are shown in Figures 16, 17, 18, and 19. Figures 16 and
Figure 6: Mediods from clustering based on global measures.
17 show the medoids and clustering, respectively, where boundary,
coverage, moment, and normalized skeleton feature vectors are con-
– Without moments: Alternatively, the results based on clustering
boundary, coverage, and skeleton feature vectors (leaving out mo-
ment feature vectors) produce the medoids and clusters in Figures
18 and 19. The concatenated feature vectors built by combining
the boundary, moment, coverage, and skeleton feature vectors are
339-dimensional while those without the moment feature vector are
Our measures capture most of the aspects of complexity outlined in Section 2
— except for the predictive approach which we did not explore here. Indeed,
it appears that all of these aspects of complexity are required to fully capture
the range of shape complexity: the most successful clustering appears to be
the concatenated measures without moments shown in Figure 19. Interestingly,
most of the medoids of that cluster are drawn from the symmetric shape class.
In particular, clustering based on boundary feature vectors, see Figure 11, is
the only clustering that manages to group all mostly long, skinny shapes into the
same cluster: watch, bone, knife, hammer, guitar, key, fork, shoe, and phone.
The skeleton feature vectors, see Figure 9, oﬀer several convincing clus-
ters, but fail in two fundamental ways. One, visually simple shapes such
as the rounded square and the heart are grouped with much more complex
shapes. This is because the skeleton generates multiple branches to describe
near-circular regions, making the skeletal description much more complex than
the boundary. The skeleton measures also do not group the hammer in with
the visually most similar shapes: bone, fork, and knife. On the other hand, the
skeleton feature vectors produce the only clustering in which the deer, ﬂy, and
beetle, arguably the most complex shapes, all occur in the same grouping.
Area measures, shown in Figure 15, very successfully group together the large
low-complexity objects, except for the rounded square in a cluster by itself. As
the only shape that takes up almost the entire ﬁeld, the clustering result makes
sense. Other clusters, such as the one containing shapes with long, pointy parts,
Figure 7: Clustering based on global measures.
Figure 8: Mediods from clustering based on skeleton measures.
Figure 9: Clustering based on skeleton measures.
Figure 10: Mediods from clustering based on boundary measures.
Figure 11: Clustering based on boundary measures.
Figure 12: Mediods from clustering based on moments measures.
Figure 13: Clustering based on moments measures.
Figure 14: Mediods from clustering based on area measures.
Figure 15: Clustering based on area measures.
Figure 16: Mediods from clustering based on concatenated boundary, moment,
coverage, and skeleton feature vectors.
also seem appropriate. On the other hand, the complex beetle is in a cluster
with the much simpler fork instead of in the cluster with the ﬂy and deer.
Boundary measures, meanwhile, cluster the beetle and the deer together but
group the ﬂy with the less complex four-legged animals; see Figure 11. Boundary
measures do, however, cluster simple shapes like the rounded square and hat
together, and also cluster symmetric shapes together despite having no explicit
The global measures in Figure 7 cluster the symmetric shapes together as
well, though they include the moment invariants, but also fail to cluster the high-
complexity beetle, ﬂy, and deer together. At ﬁrst glance, the global feature
vectors appear to cluster all of the simpler animals together, but the dog is
grouped with ﬂowers and with detailed petals. It may be that the moment
invariants in some cases overwhelm the more geometric measures.
The combination of multiple feature vectors via concatenation seems to cap-
ture the best clustering characteristics of the individual feature vector sets. The
moments appear to distract, however, as shown in Figure 17. The single cluster
containing the spiral shape, the deer, and the grouping of some of the simplest
shapes (rounded triangle and semi-circle) with some of the most complex (beetle
and ﬂy) are some of the most obvious inconsistencies.
Combined multiple feature vectors without the moment invariants (bound-
ary, coverage, and normalized skeleton feature vectors) produces the most in-
tuitively correct results; see Figure 19. Simpler shapes with long, slender pro-
trusions (except for the deer) are grouped together, as are the simplest shapes
such as heart and rounded square.
In short, each of the types of measures provides important information about
a shape’s complexity and therefore the aggregate results are the most accurate.
Moreover, our results suggest that measuring complexity measures at multiple
scales captures something important. Finally, we note that while clustering
does not provide an ordering of shapes based on their complexity, we can attach
complexity orders to the clusters based on membership in a cluster of a shape
with a known complexity level.
5.1 Discussion of methodology and future work
Our overall goal is to explore the qualitative eﬀect of possible quantitative mea-
sures when those measures are no longer single numbers (and hence the shapes
Figure 17: Clustering based on concatenated boundary, moment, coverage, and
skeleton feature vectors.
Figure 18: Mediods from clustering based on concatenated boundary, coverage,
and skeleton feature vectors.
Figure 19: Clustering based on concatenated boundary, coverage, and skeleton
cannot be linearly sorted). Clustering by similarity allows us to visually exam-
ine the measures on actual shapes. We present six diﬀerent combinations of
measures here, each with six clusters in order to illustrate the approach.
There are many diﬀerent ways to vary this approach: 1) Use a broader
range of shapes, 2) Use non-linear clustering methods (the Euclidean distance
may not be adequate), 3) Use further analysis to determine which features are
the most important in any given clustering. Further exploratory analysis of this
kind could yield a “visual dictionary” that qualitatively deﬁnes the diﬀerent
measures, and a better understanding of how to mathematically combine them
to produce desired groupings. Additionally, we have not yet analyzed which
features are most signiﬁcant in determining cluster membership.
It also seems clear that our choice of 6 clusters might not be ideal for each
measure. We chose this number to ensure that the splitting is conservative —
i.e., we may have two clusters that are similar, but we will not have a cluster that
should be split further. This is a possible explanation for why some shapes that
seem similar (such as the devices) end up in two or more clusters. It should be
noted that decreasing the number of clusters will not, in general, simply merge
two clusters. Instead, we plan to explore the optimal number of clusters in each
instance separately in future work.
Finally, we intend to implement an edit-based complexity measure to cap-
ture more explicitly the process displayed in Figure 2.1.1. We may also begin
addressing probabilistic constructions that will allow us to explore the predictive
approach to complexity.
Another key direction to explore is supervised learning, where we are pro-
vided with desired clusters (or relative rankings) and the goal is to ﬁnd the
combination of measures that best produce those clusters or rankings. The rich
set of measures provided here (and their ability to produce diﬀerent qualitative
groupings) show promise for supporting this endeavor. For example, one direc-
tion we would like to explore is using user studies (such as the one in [CLH+16])
to produce labeled data, then using techniques such as Rank Support Vector
Machines[Joa06] to determine how to combine the measures in order to produce
similar relative rankings. Note that this will provide the complexity ordering
that our clustering method currently does not.
[Bob01] M. Bober. Mpeg-7 visual shape descriptors. IEEE Trans. Cir. and
Sys. for Video Technol., 11(6), June 2001.
[CI84] B. Chazelle and J. Incerpi. Triangulation and shape-complexity.
ACM Trans. Graph., 3(2):135–152, April 1984.
[CLH+16] Axel Carlier, Kathryn Leonard, Stefanie Hahmann, Geraldine
Morin, and Misha Collins. The 2d shape structure dataset: A user
annotated open access database. Computers & Graphics, 58:23–30,
[CS05] Yinpeng Chen and Hari Sundaram. Estimating the complexity of 2d
shapes. In Proc. Multimedia Signal Processing Workshop, October
[JF05] M.Singh J. Feldman. Information along contours and object bound-
aries. Psychological Reviews, 112(1):243–252, 2005.
[Joa06] Thorsten Joachims. Training linear svms in linear time. In Pro-
ceedings of the 12th ACM SIGKDD International Conference on
Knowledge Discovery and Data Mining, KDD ’06, pages 217–226,
New York, NY, USA, 2006. ACM.
[KvD92] Jan J. Koenderink and Andrea J. van Doorn. Surface shape and
curvature scales. Image Vision Comput., 10:557–565, October 1992.
[LCLJ11] Lu Liu, Erin W Chambers, David Letscher, and Tao Ju. Extended
grassﬁre transform on medial axes of 2d shapes. Computer-Aided
Design, 43(11):1496–1505, 2011.
[Leo07] Kathryn Leonard. Eﬃcient shape modeling: epsilon-entropy, adap-
tive coding, and boundary curves -vs- blum’s medial axis. Interna-
tional Journal of Computer Vision, 74(2):183–199, 2007.
[LMB+15] Lisa J Larsson, G´eraldine Morin, Antoine Begault, Rapha¨elle
Chaine, Jeannine Abiva, Evelyne Hubert, Monica Hurdal, Mao Li,
Beatriz Paniagua, Giang Tran, et al. Identifying perceptually salient
features on 2d shapes. In Research in Shape Modeling, pages 129–
153. Springer, 2015.
[LMHC16] K. Leonard, G. Morin, S. Hahmann, and A. Carlier. A 2d shape
structure for decomposition and part similarity. In International
Conference on Pattern Recognition, Dec 2016.
[MGM05] Muharrem Mercimek, Kayhan Gulez, and Tarik Veli Mumcu. Real
object recognition using moment invariants. Sadhana, 30(6):765–
[MS08] J. McCrae and K. Singh. Sketching piecewise clothoid curves. In
Proceedings of the Fifth Eurographics Conference on Sketch-Based
Interfaces and Modeling, SBM’08, pages 1–8, Aire-la-Ville, Switzer-
land, Switzerland, 2008. Eurographics Association.
[MWZ+14] Niloy J. Mitra, Michael Wand, Hao Zhang, Daniel Cohen-Or,
Vladimir Kim, and Qi-Xing Huang. Structure-aware shape process-
ing. In ACM SIGGRAPH 2014 Courses, SIGGRAPH ’14, pages
13:1–13:21, New York, NY, USA, 2014. ACM.
[OFCD02] Robert Osada, Thomas Funkhouser, Bernard Chazelle, and David
Dobkin. Shape distributions. ACM Trans. Graph., 21(4):807–832,
[PA16] Costas Panagiotakis and Antonis Argyros. Parameter-free mod-
elling of 2d shapes with ellipses. Pattern Recognition, 53:259 – 275,
[PKS+03] D. L. Page, A. F. Koschan, S. R. Sukumar, B. Roui-Abidi, and
M. A. Abidi. Shape analysis algorithm based on information theory.
In International Conference on Image Processing, pages 229–232,
[RFS05] Jaume Rigau, Miquel Feixas, and Mateu Sbert. Shape complexity
based on mutual information. In 2005 International Conference
on Shape Modeling and Applications (SMI 2005), 15-17 June 2005,
Cambridge, MA, USA, pages 357–362, 2005.
[SPG+06] S. Sukumar, D. Page, A. Gribok, A. Koschan, and M. Abidi. Shape
measure for identifying perceptually informative parts of 3d objects.
In 3D Data Processing, Visualization, and Transmission, Third In-
ternational Symposium on, pages 679–686, June 2006.
[SW15] Michael Schwarz and Peter Wonka. Practical grammar-based pro-
cedural modeling of architecture: Siggraph asia 2015 course notes.
In SIGGRAPH Asia 2015 Courses, SA ’15, pages 13:1–13:12, New
York, NY, USA, 2015. ACM.