Skip to main content

Library with some less common or extended spatial functions

Project description

PyGeoOps

Actions Status codecov PyPI version Conda version

PyGeoOps provides some less common or extended spatial algorithms and utility functions.

Introduction

This is a shortlist of the available functions:

  • centerline: centerline/medial axis calculation for a polygon, including optional cleanup of short branches.
  • view_angles: determine the start and end angle a polygon is visible from the viewpoint specified
  • simplify: simplify a polygon, with some extended options like
    • choice in simplification algorithms: Lang (+ a variant), Ramer Douglas Peuker, Visvalingal Whyatt
    • specify points/locations where points should not be removed by the simplification
    • topologic simplification: common boundaries between input features should stay common
  • utility functions to create and split grids (create_grid, split_tiles)
  • general utility functions on geometries like remove_inner_rings, collection_extract,…

Full documentation can be found on Read the Docs.

Usage

The centerline for a polygon, including the default cleanup of short branches, can be calculated like this:

import pygeoops
import shapely

polygon = shapely.from_wkt("POLYGON ((0 0, 0 8, -2 10, 4 10, 2 8, 2 2, 10 2, 10 0, 0 0))")
centerline = pygeoops.centerline(polygon)

centerline

Installation

PyGeoOps is available on PyPi, so can be installed using pip:

pip install pygeoops

Another option is to use conda or mamba, as it is also available on conda-forge:

conda install pygeoops --channel conda-forge

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pygeoops-0.6.1.dev1.tar.gz (32.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pygeoops-0.6.1.dev1-py3-none-any.whl (36.9 kB view details)

Uploaded Python 3

File details

Details for the file pygeoops-0.6.1.dev1.tar.gz.

File metadata

  • Download URL: pygeoops-0.6.1.dev1.tar.gz
  • Upload date:
  • Size: 32.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.13

File hashes

Hashes for pygeoops-0.6.1.dev1.tar.gz
Algorithm Hash digest
SHA256 72718f92a4c7faac0644b2676ce2a88bf74125a092a923841aee8d3dd1cce70f
MD5 3cfb235ec313c4df71a90814301061d7
BLAKE2b-256 60537f5607fdaf33e359e3bcf8af80a076e63a9fcdbaf3f21cac8927785eccaa

See more details on using hashes here.

File details

Details for the file pygeoops-0.6.1.dev1-py3-none-any.whl.

File metadata

  • Download URL: pygeoops-0.6.1.dev1-py3-none-any.whl
  • Upload date:
  • Size: 36.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.13

File hashes

Hashes for pygeoops-0.6.1.dev1-py3-none-any.whl
Algorithm Hash digest
SHA256 f4aea6dad2981d79ae0608735724920d5da804357b84994ec9db18ce2acda7b0
MD5 e3a54a005b6e1681e47ac8f17007539e
BLAKE2b-256 08531543db1840eeda6ae53a7bc3bd104cb554a8f1d1c829de81a0362eec048f

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page