Skip to main content

Fast and storage-efficient spatial database engine for OpenStreetMap features

Project description

GeoDesk is a fast and storage-efficient geospatial database for OpenStreetMap data. Also available for C++ and for Java.

[!IMPORTANT] This is a preview release of GeoDesk for Python 2.0.

To use it, you will need to build GOLs with GOL Tool 2.0.

To read GOLs built with GOL Tool 1.x, use Version 1.3.0 of this toolkit (pip install geodesk)

Why GeoDesk?

  • Small storage footprint — GeoDesk's GOL files are only 20% to 50% larger than the original OSM data in PBF format — that's less than a tenth of the storage consumed by a traditional SQL-based database.

  • Fast queries — typically 50 times faster than SQL.

  • Fast to get started — Converting .osm.pbf data to a GOL is 20 times faster than an import into an SQL database. Alternatively, download pre-made data tiles for just the regions you need and automatically assemble them into a GOL.

  • Intuitive API — No need for object-relational mapping; GeoDesk queries return Python objects. Quickly discover tags, way-nodes and relation members. Get a feature's geometry, measure its length/area.

  • Proper handling of relations — (Traditional geospatial databases deal with geometric shapes and require workarounds to support this unique and powerful aspect of OSM data.)

  • Seamless integration with Shapely for advanced geometric operations, such as buffer, union, simplify, convex and concave hulls, Voronoi diagrams, and much more.

  • Modest hardware requirements — If it can run 64-bit Python, it'll run GeoDesk.

Get Started

Requirements

Download

pip install geodesk

Create a GOL

Create a Geographic Object Library based on any .osm.pbf file, using the GOL Tool.

For example:

gol build switzerland switzerland-latest.osm.pbf

Example Application

Find all the pubs in Zurich (Switzerland) and print their names:

from geodesk import *

# Open switzerland.gol
features = Features("switzerland")      

# Get the feature that represents the area of the city of Zurich
zurich = features("a[boundary=adminstrative][admin_level=8][name:en=Zurich]").one

# Define a set that contains nodes and areas that are pubs
pubs = features("na[amenity=pub]")

# Iterate through the pubs that are contained in the area of Zurich
# and print their names
for pub in pubs.within(zurich):
    print(pub.name)        

More Examples

Find all movie theaters within 500 meters from a given point:

movieTheaters = features("na[amenity=cinema]").around(
    meters=500, lat=47.37, lon=8.54)

Remember, OSM uses British English for its terminology.

Discover the bus routes that traverse a given street:

for route in street.parents("[route=bus]")):
    print(f"- {route.ref} from {route.from} to {route.to}")

Count the number of entrances of a building:

number_of_entrances = building.nodes("[entrance]").count

Documentation

GeoDesk Developer's Guide

Related Repositories

  • geodesk — GeoDesk for Java
  • libgeodesk — GeoDesk for C++
  • geodesk-gol — command-line utility for building, maintaining and querying GOL files

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

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

geodesk2-2.0.3-cp313-cp313-win_amd64.whl (326.7 kB view details)

Uploaded CPython 3.13Windows x86-64

geodesk2-2.0.3-cp313-cp313-musllinux_1_2_x86_64.whl (2.6 MB view details)

Uploaded CPython 3.13musllinux: musl 1.2+ x86-64

geodesk2-2.0.3-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.7 MB view details)

Uploaded CPython 3.13manylinux: glibc 2.17+ x86-64

geodesk2-2.0.3-cp313-cp313-macosx_11_0_x86_64.whl (1.2 MB view details)

Uploaded CPython 3.13macOS 11.0+ x86-64

geodesk2-2.0.3-cp313-cp313-macosx_11_0_arm64.whl (1.1 MB view details)

Uploaded CPython 3.13macOS 11.0+ ARM64

geodesk2-2.0.3-cp312-cp312-win_amd64.whl (326.7 kB view details)

Uploaded CPython 3.12Windows x86-64

geodesk2-2.0.3-cp312-cp312-musllinux_1_2_x86_64.whl (2.6 MB view details)

Uploaded CPython 3.12musllinux: musl 1.2+ x86-64

geodesk2-2.0.3-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.7 MB view details)

Uploaded CPython 3.12manylinux: glibc 2.17+ x86-64

geodesk2-2.0.3-cp312-cp312-macosx_11_0_x86_64.whl (1.2 MB view details)

Uploaded CPython 3.12macOS 11.0+ x86-64

geodesk2-2.0.3-cp312-cp312-macosx_11_0_arm64.whl (1.1 MB view details)

Uploaded CPython 3.12macOS 11.0+ ARM64

geodesk2-2.0.3-cp311-cp311-win_amd64.whl (326.6 kB view details)

Uploaded CPython 3.11Windows x86-64

geodesk2-2.0.3-cp311-cp311-musllinux_1_2_x86_64.whl (2.6 MB view details)

Uploaded CPython 3.11musllinux: musl 1.2+ x86-64

geodesk2-2.0.3-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.7 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.17+ x86-64

geodesk2-2.0.3-cp311-cp311-macosx_11_0_x86_64.whl (1.2 MB view details)

Uploaded CPython 3.11macOS 11.0+ x86-64

geodesk2-2.0.3-cp311-cp311-macosx_11_0_arm64.whl (1.1 MB view details)

Uploaded CPython 3.11macOS 11.0+ ARM64

geodesk2-2.0.3-cp310-cp310-win_amd64.whl (326.7 kB view details)

Uploaded CPython 3.10Windows x86-64

geodesk2-2.0.3-cp310-cp310-musllinux_1_2_x86_64.whl (2.6 MB view details)

Uploaded CPython 3.10musllinux: musl 1.2+ x86-64

geodesk2-2.0.3-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.7 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.17+ x86-64

geodesk2-2.0.3-cp310-cp310-macosx_11_0_x86_64.whl (1.2 MB view details)

Uploaded CPython 3.10macOS 11.0+ x86-64

geodesk2-2.0.3-cp310-cp310-macosx_11_0_arm64.whl (1.1 MB view details)

Uploaded CPython 3.10macOS 11.0+ ARM64

geodesk2-2.0.3-cp39-cp39-win_amd64.whl (326.8 kB view details)

Uploaded CPython 3.9Windows x86-64

geodesk2-2.0.3-cp39-cp39-musllinux_1_2_x86_64.whl (2.6 MB view details)

Uploaded CPython 3.9musllinux: musl 1.2+ x86-64

geodesk2-2.0.3-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.7 MB view details)

Uploaded CPython 3.9manylinux: glibc 2.17+ x86-64

geodesk2-2.0.3-cp39-cp39-macosx_11_0_x86_64.whl (1.2 MB view details)

Uploaded CPython 3.9macOS 11.0+ x86-64

geodesk2-2.0.3-cp39-cp39-macosx_11_0_arm64.whl (1.1 MB view details)

Uploaded CPython 3.9macOS 11.0+ ARM64

File details

Details for the file geodesk2-2.0.3-cp313-cp313-win_amd64.whl.

File metadata

  • Download URL: geodesk2-2.0.3-cp313-cp313-win_amd64.whl
  • Upload date:
  • Size: 326.7 kB
  • Tags: CPython 3.13, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.13

File hashes

Hashes for geodesk2-2.0.3-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 2e76b483a05aa084db1735ce02a7d3b25bb7716c2edc528662dbc4d8f517372b
MD5 7c3c9c669f58b04a509e6abf68148963
BLAKE2b-256 2cc026ccc8e912cb4fd3bd54840e62a221b62a9c1fa8103579a84ba88f960a2e

See more details on using hashes here.

File details

Details for the file geodesk2-2.0.3-cp313-cp313-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for geodesk2-2.0.3-cp313-cp313-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 4289477ff8aba35535c4a72c6ca41abf6a99354f9636f9f30fed1b5d9dc3be6c
MD5 83ff03faff130db3202069657ff76627
BLAKE2b-256 84dc92d18162b32466555c00041d8edb3bf56b5bc92c00c019310a2a248519f3

See more details on using hashes here.

File details

Details for the file geodesk2-2.0.3-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for geodesk2-2.0.3-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 a809e960a7fe6f6491efe1c09022ae07d448af109953f00887ab88ae942d3469
MD5 260399576406a472186d178f4d9bbbe7
BLAKE2b-256 0f92968f33323bb6195c7cab439bb31a34d5d80477c60b4247d455a67adc6f13

See more details on using hashes here.

File details

Details for the file geodesk2-2.0.3-cp313-cp313-macosx_11_0_x86_64.whl.

File metadata

File hashes

Hashes for geodesk2-2.0.3-cp313-cp313-macosx_11_0_x86_64.whl
Algorithm Hash digest
SHA256 c7885389585d6ecc5c3ae450dd0673f06414931ea11282f4055a4c1555391512
MD5 94a1ea348a8c46e700d843fa2efcd47f
BLAKE2b-256 9edaa4cfff003ea2a01073a0450a8bbd6b82d76970214529bae91babc75876a9

See more details on using hashes here.

File details

Details for the file geodesk2-2.0.3-cp313-cp313-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for geodesk2-2.0.3-cp313-cp313-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 f24293d44b5bc3f194a7498c03f6ed22f3d8c31355facfea3c5c8e017d2df28c
MD5 b9b61f34c07a401924e20d6ec1d96f4e
BLAKE2b-256 5dd235177e6a4a7a65a8783f218d5683c2f5dc96881274f50df500e48eb8c06f

See more details on using hashes here.

File details

Details for the file geodesk2-2.0.3-cp312-cp312-win_amd64.whl.

File metadata

  • Download URL: geodesk2-2.0.3-cp312-cp312-win_amd64.whl
  • Upload date:
  • Size: 326.7 kB
  • Tags: CPython 3.12, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.13

File hashes

Hashes for geodesk2-2.0.3-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 689ae5ad49da65f6005c0d83359cf133741ecc3c12be5ae2d1d994a226828812
MD5 968751e774e2a5b4676c342b164f9903
BLAKE2b-256 5db78fcb05222b0a93a3bdfe71e20bf8e3e4fa08bae230155ad70339af8caf97

See more details on using hashes here.

File details

Details for the file geodesk2-2.0.3-cp312-cp312-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for geodesk2-2.0.3-cp312-cp312-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 8aebb9b18376cb1baa178cb78068f55ce13cb3f7792326f6ad0c6c38fc9ab560
MD5 f97f3248d937f63b23ab58c702675896
BLAKE2b-256 dc6d57dfd4e08c9489fe02420ccc8d293803f6410f3cccb1063316f8eba9aac1

See more details on using hashes here.

File details

Details for the file geodesk2-2.0.3-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for geodesk2-2.0.3-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 6187517b3ceb7956c52ca36d192d850a7ec2a486780f7a57ae54c180f9c2f48c
MD5 2d5c836cb23e2f8c70c239d5bcc1620e
BLAKE2b-256 e9444c05464ed145fc6f73475560632a3c7bb046114cdf620671d9ff68dc227e

See more details on using hashes here.

File details

Details for the file geodesk2-2.0.3-cp312-cp312-macosx_11_0_x86_64.whl.

File metadata

File hashes

Hashes for geodesk2-2.0.3-cp312-cp312-macosx_11_0_x86_64.whl
Algorithm Hash digest
SHA256 f28365556a9cbd82849a2c305ab8a2ee4833fd2aefce9efddcba06c44a3e0d9f
MD5 7eeadf96a27e373487db53bfccfa2efb
BLAKE2b-256 24d176bc1eeab73f84da6dced3c0b20947f163a93a0fa774141f2c91acaab92f

See more details on using hashes here.

File details

Details for the file geodesk2-2.0.3-cp312-cp312-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for geodesk2-2.0.3-cp312-cp312-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 70cbe7aef3fe00bbd30a18b0b3fcd40781009851f4ab1bbaeef3e00a1aa922b4
MD5 fe82bb4cb2109aaa701605366941388e
BLAKE2b-256 2e30c6cb82128cc9e4f8ff5295c32b6825577423d7207228906375dd2af656f9

See more details on using hashes here.

File details

Details for the file geodesk2-2.0.3-cp311-cp311-win_amd64.whl.

File metadata

  • Download URL: geodesk2-2.0.3-cp311-cp311-win_amd64.whl
  • Upload date:
  • Size: 326.6 kB
  • Tags: CPython 3.11, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.13

File hashes

Hashes for geodesk2-2.0.3-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 064afc32fcb86083361b227441e97d8ba1723290cb322fd0d679cdc02aec9c60
MD5 8a1ba4e5f3287858e2dcac46256a3671
BLAKE2b-256 1e5de997f75cc30b8686ffd1b1c0ee64251482987c7c84a14853d549fa357c2c

See more details on using hashes here.

File details

Details for the file geodesk2-2.0.3-cp311-cp311-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for geodesk2-2.0.3-cp311-cp311-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 bf502e9b9f697c2bbd3a066c5817680f9a5aafb51ddf8a7ed0c0fc3f24c54945
MD5 4588543446c18226ee07c89496618945
BLAKE2b-256 ae73a7dcc9f6b17407ecfa39229e007bad575959eae57e87da3305d39e76e165

See more details on using hashes here.

File details

Details for the file geodesk2-2.0.3-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for geodesk2-2.0.3-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 c1a537f0d0f854fdd7c3e91fe90268d080d9322f096e021cffc987f0eb3cd423
MD5 ee2f94ecbe2292ac8e8655c6e2f4a66e
BLAKE2b-256 fd6fc264ec6f1cfb47da3bd40440e0e3da73de0ec8832e8f33b3b79f266be343

See more details on using hashes here.

File details

Details for the file geodesk2-2.0.3-cp311-cp311-macosx_11_0_x86_64.whl.

File metadata

File hashes

Hashes for geodesk2-2.0.3-cp311-cp311-macosx_11_0_x86_64.whl
Algorithm Hash digest
SHA256 ee8667bb62da56824b2df40df38bc742b2c5a944ee15c6d2c210a9fa5c77e42d
MD5 88e64805efe1a564e16c2a9c1d5c18bc
BLAKE2b-256 c2711b1379480aa7dbf7c528616cfddf9b12f45249c99b9b5d60ba06364a48eb

See more details on using hashes here.

File details

Details for the file geodesk2-2.0.3-cp311-cp311-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for geodesk2-2.0.3-cp311-cp311-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 1b4b26a4a65c9f3298e887432f4bec0f255363c23a90dba5770f62b59502d22c
MD5 c3d7938aa35772d4c60c9b0e99e56979
BLAKE2b-256 637dfdb9ce364513b9b378edbb80d9eff5188237ca0b1fc537e2a8693d67557d

See more details on using hashes here.

File details

Details for the file geodesk2-2.0.3-cp310-cp310-win_amd64.whl.

File metadata

  • Download URL: geodesk2-2.0.3-cp310-cp310-win_amd64.whl
  • Upload date:
  • Size: 326.7 kB
  • Tags: CPython 3.10, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.13

File hashes

Hashes for geodesk2-2.0.3-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 092d97d688c5dda098853cfcdbccbe7967aab74a3a6b6dd6d9a1604ee0a27616
MD5 8d1760c44feae2d0ff11dc678a4616d0
BLAKE2b-256 21c5c31edb5bc0690bb725e8b085b4ce11874222425ed035c265c5c3dfcd3c71

See more details on using hashes here.

File details

Details for the file geodesk2-2.0.3-cp310-cp310-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for geodesk2-2.0.3-cp310-cp310-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 096713b9c43652d4b1ea8290e9923d64f11a6c9e1eecca85837eef4c84a72e16
MD5 b308eab4059f4d6194d8305e3a2ad2ba
BLAKE2b-256 9090bd09194cad3fde99c9d9f5b42d79662fd049bf97d53951282b4331198613

See more details on using hashes here.

File details

Details for the file geodesk2-2.0.3-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for geodesk2-2.0.3-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 92622f4112546d85494f6a19b86c39b57441fdda764d8df66b4f624c1c143602
MD5 7e61eb3e40f730e8f6d570b7a1c1aa58
BLAKE2b-256 69476c8b50f639444a90fef4d79c0945057b35981a6a2d06129c2aa361a1094d

See more details on using hashes here.

File details

Details for the file geodesk2-2.0.3-cp310-cp310-macosx_11_0_x86_64.whl.

File metadata

File hashes

Hashes for geodesk2-2.0.3-cp310-cp310-macosx_11_0_x86_64.whl
Algorithm Hash digest
SHA256 6ae15695a79c35d309c5d795a8b556b7552398a490e1ad253ba9f2a2b367195f
MD5 a1dacdfc0e1105ad01381fcad4c315b8
BLAKE2b-256 27e3f926a975101e6bc53b77494308b7f43aaa54a8b37082d0f0f79ba022b1ce

See more details on using hashes here.

File details

Details for the file geodesk2-2.0.3-cp310-cp310-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for geodesk2-2.0.3-cp310-cp310-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 ddd70d617d2612b2d0aabcdf04ea78e453589d6524885c8a3a094c96b660575c
MD5 f407669266f0c9159178feb4eb334dc1
BLAKE2b-256 4f32294fe173e1b50fd3dd4050e02f1db483de74e2bd6a4467555c2ac6782ce5

See more details on using hashes here.

File details

Details for the file geodesk2-2.0.3-cp39-cp39-win_amd64.whl.

File metadata

  • Download URL: geodesk2-2.0.3-cp39-cp39-win_amd64.whl
  • Upload date:
  • Size: 326.8 kB
  • Tags: CPython 3.9, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.13

File hashes

Hashes for geodesk2-2.0.3-cp39-cp39-win_amd64.whl
Algorithm Hash digest
SHA256 62995c5f82ce7f41e7144fa4e6f0093adbfaac6a92bbfa33d4445c166232f6b5
MD5 1d43d16356cf111d55b9f98af25562c4
BLAKE2b-256 16ed720203013eccbfa880010265c7655f06c3f8fad82951bb7b449b466859a8

See more details on using hashes here.

File details

Details for the file geodesk2-2.0.3-cp39-cp39-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for geodesk2-2.0.3-cp39-cp39-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 0a2e3212b00acee3e5023059a7add8a7ce8144f2e3d878d670a1f9730f957f03
MD5 2a9d21eda4c947139e4891bc960aa00e
BLAKE2b-256 3da5c02b31f9346e04de6a94f7fd3e7b1807fa5772793db9f48402542881dbc8

See more details on using hashes here.

File details

Details for the file geodesk2-2.0.3-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for geodesk2-2.0.3-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 7615aa2d0e68e7f9fe24283db130d0e201c839f32b68e7d09c81d70bffd2adc4
MD5 d4ef5726649cd4b35cf79913e61c1ecb
BLAKE2b-256 d62e08c9f008daf04a004f7755cad68e30a30129481c52d487eb6e127cd0bba1

See more details on using hashes here.

File details

Details for the file geodesk2-2.0.3-cp39-cp39-macosx_11_0_x86_64.whl.

File metadata

File hashes

Hashes for geodesk2-2.0.3-cp39-cp39-macosx_11_0_x86_64.whl
Algorithm Hash digest
SHA256 944a84fa6df81a0b47a76d31b1e9d03e24c549b393639c081aa8218ba7af4812
MD5 4c33d78d2434a637a61cb996e31a2bf5
BLAKE2b-256 dee1b7eeb1b9539656e25338c6fda7dc3d897271c0183ed7e1791274de1b05c4

See more details on using hashes here.

File details

Details for the file geodesk2-2.0.3-cp39-cp39-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for geodesk2-2.0.3-cp39-cp39-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 42279c90bdf2867bca257b106b238d481e4564f5dea54f5e011a66e4147a38dd
MD5 190669a8a725e7616728b580a13faecc
BLAKE2b-256 35fbfd57a8484fcfe43c433c7ba66be41d148480b45996a9e9ce8a55e54bee43

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