alphashape
Toolbox for generating alpha shapes.
What it is and what it does
Alphashape is a computational geometry library that wraps point clouds in tight, adaptive bounding shapes. Unlike a convex hull—which always produces the outermost perimeter—an alpha shape lets you control how tightly the boundary fits by adjusting an alpha parameter: lower values yield convex shapes, higher values produce concave hulls that hug the data more closely. The library works in 2, 3, 4, or higher dimensions and returns either a polygon (2D), a mesh (3D+), or a set of simplices depending on dimensionality.
You can specify the alpha parameter directly, define it as a function of local point density, or let the library solve for an optimal value automatically. A command-line tool is included for batch processing. The package depends on shapely for 2D geometry, trimesh for 3D visualization, and standard scientific Python stack (numpy, scipy, networkx, rtree) for computational backbone.
Use it for:
- Compute concave hulls around GPS traces or sensor readings to define coverage regions without over-fitting to outliers.
- Mesh 3D point clouds from LiDAR or photogrammetry by generating alpha shapes at varying scales.
- Automatically determine tight bounding polygons for geospatial features where convex hulls are too loose.
- Solve for optimal alpha values in exploratory analysis to find the best-fitting boundary without manual parameter tuning.
- Generate n-dimensional simplicial complexes for topological or statistical analysis of high-dimensional point sets.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Generates n-dimensional alpha shapes—concave or convex bounding polygons around point sets—with support for static, dynamic, or automatically-solved alpha parameters.
Yes. The package is stable (Production/Stable classifier), actively maintained, permissively licensed, has no known vulnerabilities, and installs with low friction. It fills a genuine gap between convex hulls and manual boundary fitting. Install it if you need adaptive bounding shapes; skip it only if you require only convex hulls or if your use case is strictly 2D and you prefer a lighter dependency tree.
Install
alphashape on PyPI
pip
pip install alphashapeuv
uv add alphashapepoetry
poetry add alphashapeInstalling alphashape
Before you install
Low friction: pure-Python wheel with no compiled dependencies. Actively maintained as of 2026-07-23 with 313 repository stars and no known vulnerabilities.
License in practice
MIT license permits commercial and private use with minimal restrictions; attribution required but no copyleft obligations.
Quickstart
pip install alphashape
import alphashape
import numpy as np
points = [(0., 0.), (0., 1.), (1., 1.), (1., 0.), (0.5, 0.25)]
alpha_shape = alphashape.alphashape(points, 2.0)
Verify before relying
- Performance characteristics on large datasets (fact sheet notes solving for alpha can be slow but does not quantify thresholds)
- Numerical stability or precision guarantees for edge cases in high dimensions
Package facts
| License | MIT license (permissive) |
| Python support | not specified |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 8 — Click, click-log, shapely, numpy, trimesh, networkx, rtree, scipy |
| Maintenance | actively maintained — 1,946 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 1,434,301/month — #3,903 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: alphashape-1.3.1-py2.py3-none-any.whl
Keywords: alphashape
Tags
More Scientific/Engineering packages
NumPy provides an N-dimensional array object…
permissive · top 100 on PyPI
pandaspandas provides fast, flexible data structures…
permissive · top 100 on PyPI
scipyscipy provides numerical algorithms for…
permissive · top 100 on PyPI
scikit-learnscikit-learn provides a comprehensive Python…
permissive · top 1,000 on PyPI
dilldill extends Python's pickle module to…
permissive · top 1,000 on PyPI
multiprocessMultiprocess is an enhanced fork of Python's…
permissive · top 1,000 on PyPI
bermudaProvides Rust-accelerated triangulation…
permissive · top 15,000 on PyPI
vhacdxComputes approximate convex decomposition of…
unclear · top 5,000 on PyPI
cmeel-qhullProvides precompiled qhull binaries (convex…
unclear · top 15,000 on PyPI
trimeshTrimesh loads, manipulates, and analyzes…
permissive · top 5,000 on PyPI
umap-learnUMAP reduces high-dimensional data to lower…
permissive · top 5,000 on PyPI
cvxoptcvxopt is a Python library for solving convex…
unclear · top 5,000 on PyPI
paretosetComputes the Pareto (non-dominated) set from…
permissive · top 15,000 on PyPI
gstoolsGSTools provides geostatistical tools for…
copyleft · top 15,000 on PyPI
pygmshpygmsh provides a Python interface to Gmsh, a…
copyleft · top 15,000 on PyPI
descartesConverts geometric objects and GeoJSON-like…
permissive · top 15,000 on PyPI