simplification
Fast linestring simplification using RDP or Visvalingam-Whyatt and a Rust binary
What it is and what it does
Simplification is a Python library that reduces the number of points in a LineString while preserving its overall shape using two well-established algorithms: Ramer–Douglas–Peucker (RDP) and Visvalingam-Whyatt (VW). It wraps a Rust binary via FFI and integrates with numpy, accepting both Python lists and numpy arrays as input. The library supports a topology-preserving variant of VW for cases where valid geometry output is critical.
The package is designed for geographic and geometric applications where coordinate reduction is needed—such as map rendering, data compression, or polyline simplification. It offers variants that return either simplified coordinates or the indices of retained points, allowing flexible integration into downstream workflows. Prebuilt wheels cover Python 3.10–3.14 across Linux, macOS, and Windows.
Use it for:
- Reduce map tile complexity by simplifying LineStrings before rendering on web maps or mobile applications.
- Compress GPS traces or trajectory data for storage and transmission while retaining navigable geometry.
- Decimate high-resolution polylines (e.g., from OSRM or Google Maps APIs) to reduce API response size.
- Prepare geographic data for analysis by removing noise-induced coordinate redundancy before spatial operations.
- Validate geometry integrity using the topology-preserving VW variant when simplification must not break polygon/line validity.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Simplify LineStrings using the Ramer–Douglas–Peucker or Visvalingam-Whyatt algorithms, reducing coordinate counts while preserving geometry shape.
Yes, if you work with geographic data or need to reduce coordinate counts in LineStrings. The library is actively maintained, has no known vulnerabilities, and offers prebuilt wheels for modern Python versions. Install friction is moderate due to compilation, but binary wheels mitigate this. Verify the Blue Oak Model Licence 1.0.0 compatibility with your project before committing.
Install
simplification on PyPI
pip
pip install simplificationuv
uv add simplificationpoetry
poetry add simplificationInstalling simplification
Before you install
Medium install friction due to compiled wheels; prebuilt binaries available for Python 3.10–3.14 on Linux, macOS, and Windows. Active maintenance with recent release (67 days ago) and no known vulnerabilities.
License in practice
Licensed under Blue Oak Model Licence 1.0.0 (BlueOak-1.0.0), a permissive open-source license. License treatment is marked unclear in the package metadata, so verify the license terms directly if commercial use is a concern.
Quickstart
from simplification.cutil import simplify_coords
import numpy as np
coords = [[0.0, 0.0], [5.0, 4.0], [11.0, 5.5], [17.3, 3.2], [27.8, 0.1]]
simplified = simplify_coords(coords, 1.0)
Requires Python >=3.10; numpy is a runtime dependency.
Verify before relying
- Whether the Blue Oak Model Licence 1.0.0 is compatible with your project's license requirements (marked 'unclear' in metadata).
- Performance characteristics on your specific data size and complexity (benchmarks in documentation are illustrative, not guaranteed).
Package facts
| License | BlueOak-1.0.0 (unclear) |
| Python support | supports the current Python release (>=3.10) |
| Install friction | medium — platform-specific wheel |
| Runtime dependencies | 1 — numpy |
| Maintenance | actively maintained — 67 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 336,213/month — #7,467 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: simplification-1.0.0-cp310-cp310-macosx_11_0_arm64.whl; simplification-1.0.0-cp310-cp310-macosx_11_0_x86_64.whl; simplification-1.0.0-cp310-cp310-manylinux_2_28_aarch64.whl; simplification-1.0.0-cp310-cp310-manylinux_2_28_x86_64.whl; simplification-1.0.0-cp310-cp310-win_amd64.whl; simplification-1.0.0-cp311-abi3-macosx_11_0_arm64.whl; simplification-1.0.0-cp311-abi3-macosx_11_0_x86_64.whl; simplification-1.0.0-cp311-abi3-manylinux_2_28_aarch64.whl; simplification-1.0.0-cp311-abi3-manylinux_2_28_x86_64.whl; simplification-1.0.0-cp311-abi3-win_amd64.whl
Keywords: Geo, Polyline, Linestring, Ramer-Douglas-Peucker, Douglas-Peucker, Visvalingam-Whyatt
Tags
More Python Modules packages
Converts domain names between Unicode and…
permissive · top 100 on PyPI
setuptoolsSetuptools is a Python build backend and…
permissive · top 100 on PyPI
PyYAMLPyYAML parses and emits YAML 1.1 data format,…
permissive · top 100 on PyPI
pydanticPydantic validates Python data structures…
permissive · top 100 on PyPI
annotated-typesProvides reusable metadata objects for use with…
permissive · top 100 on PyPI
typing-inspectionProvides runtime tools to inspect and…
permissive · top 100 on PyPI
rdpImplements the Ramer-Douglas-Peucker algorithm…
permissive · top 15,000 on PyPI
topojsontopojson encodes spatial data into TopoJSON…
permissive · top 15,000 on PyPI
polylineEncodes and decodes geographic coordinate…
unclear · top 5,000 on PyPI
pypolylineEncodes and decodes Google Polyline format…
unclear · top 15,000 on PyPI
onnxsimSimplifies ONNX neural network models by…
permissive · top 15,000 on PyPI
pygeoifPyGeoIf provides lightweight, pure-Python…
copyleft · top 15,000 on PyPI
affineAffine provides a Python class for representing…
permissive · top 5,000 on PyPI
flexpolylineEncodes and decodes geographic coordinate…
permissive · top 15,000 on PyPI
mgrsConverts between MGRS (Military Grid Reference…
permissive · top 15,000 on PyPI
fast-simplificationSimplifies 3D meshes by reducing the number of…
permissive · top 15,000 on PyPI