GeoDesk is a fast and storage-efficient geospatial database for OpenStreetMap data. Also available for C++ and for Java.
This is an interim release used for testing.
For production use, install the geodesk instead:
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.pbfdata 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
- Python 3.9 or above
- GOL Tool 2.0
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
Related Repositories
- geodesk — GeoDesk for Java
- libgeodesk — GeoDesk for C++
- geodesk-gol — command-line utility for building, maintaining and querying GOL files
Metadata
Release files for geodesk2 2.0.4
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Built distributions (wheels)
Total release size: 34.7 MB
Release files / geodesk2-2.0.4-cp313-cp313-win_amd64.whl
| Download URL | geodesk2-2.0.4-cp313-cp313-win_amd64.whl |
|---|---|
| Size | 326.7 kB |
| Tags | CPython 3.13 Windows x86-64 |
|
SHA-256 checksum How to use checksums |
b119c34e3a9407cf94146261b0e49b49a3c0de8444df3b53848de6c170ee7b15
|
|
BLAKE2b-256 checksum How to use checksums |
784ad2c29dadafc33e07ba798960f08fe9b7da82c010a3839204de706c9f23e7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.13
|
Release files / geodesk2-2.0.4-cp313-cp313-musllinux_1_2_x86_64.whl
| Download URL | geodesk2-2.0.4-cp313-cp313-musllinux_1_2_x86_64.whl |
|---|---|
| Size | 2.6 MB |
| Tags | CPython 3.13 Linux musl 1.2+ x86-64 |
|
SHA-256 checksum How to use checksums |
e4be09884c43b49ae742167eb6ebf45e5ad2d8603fd81786ecfebf62a4a06a00
|
|
BLAKE2b-256 checksum How to use checksums |
811803fbb55b864c93d5a4a0a6467f4331a1257f74d42966797a4bedbbb78977
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.13
|
Release files / geodesk2-2.0.4-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
| Download URL | geodesk2-2.0.4-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl |
|---|---|
| Size | 1.7 MB |
| Tags | CPython 3.13 Linux glibc 2.17+ x86-64 |
|
SHA-256 checksum How to use checksums |
6bd601e99ba7a85a9550f447b8b16644f43167421861bec46baaed721031b7da
|
|
BLAKE2b-256 checksum How to use checksums |
cba0047e335f8fa1efa4887172cc71d784c4c91ae45e6ac109d79923bb99f578
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.13
|
Release files / geodesk2-2.0.4-cp313-cp313-macosx_11_0_x86_64.whl
| Download URL | geodesk2-2.0.4-cp313-cp313-macosx_11_0_x86_64.whl |
|---|---|
| Size | 1.2 MB |
| Tags | CPython 3.13 macOS 11.0+ x86-64 |
|
SHA-256 checksum How to use checksums |
de475414975333b7ab407ce24aec79b7f6cb43a10222dd2c43b4b4cb348391ba
|
|
BLAKE2b-256 checksum How to use checksums |
c68fe4f9aa12cb42363c5c66cfc400d20b5a74e6e1b682d39e731b9609366f6a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.13
|
Release files / geodesk2-2.0.4-cp313-cp313-macosx_11_0_arm64.whl
| Download URL | geodesk2-2.0.4-cp313-cp313-macosx_11_0_arm64.whl |
|---|---|
| Size | 1.1 MB |
| Tags | CPython 3.13 macOS 11.0+ ARM64 |
|
SHA-256 checksum How to use checksums |
ea4a442d62a1df5475a0cda30f39cc85ebc871af193aecc56d98c4d8c1c579b3
|
|
BLAKE2b-256 checksum How to use checksums |
b2a24782e6e8ebde5a2b4786f95743c36bbec76c1733474b6d40b555d9912c7a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.13
|
Release files / geodesk2-2.0.4-cp312-cp312-win_amd64.whl
| Download URL | geodesk2-2.0.4-cp312-cp312-win_amd64.whl |
|---|---|
| Size | 326.7 kB |
| Tags | CPython 3.12 Windows x86-64 |
|
SHA-256 checksum How to use checksums |
7d7f224066bf7acc6dba74b50dcf1fbf39b1c9f73fb20c6cf3c217a1bfe8d11d
|
|
BLAKE2b-256 checksum How to use checksums |
4a83f7df5dd9d7d6f74c498defddf52af07f11e55af6eb10615add77737d5a52
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.13
|
Release files / geodesk2-2.0.4-cp312-cp312-musllinux_1_2_x86_64.whl
| Download URL | geodesk2-2.0.4-cp312-cp312-musllinux_1_2_x86_64.whl |
|---|---|
| Size | 2.6 MB |
| Tags | CPython 3.12 Linux musl 1.2+ x86-64 |
|
SHA-256 checksum How to use checksums |
661923abf356a76a2f3afc80695599242f9c054e5ba5dc7a6d3101bac84905a2
|
|
BLAKE2b-256 checksum How to use checksums |
20ca885b84bee0f454edd703bc767ec0fc7c844ba45d8dbd10c879b60efeca89
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.13
|
Release files / geodesk2-2.0.4-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
| Download URL | geodesk2-2.0.4-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl |
|---|---|
| Size | 1.7 MB |
| Tags | CPython 3.12 Linux glibc 2.17+ x86-64 |
|
SHA-256 checksum How to use checksums |
63af53cd6b8695182e7f965a11a52afc0939bdf6030a276f6d3928d7220bc2a6
|
|
BLAKE2b-256 checksum How to use checksums |
ba9ecf219a803f7e8e9f84383b8f582b68af03acef61cd1cd8ec9302c90d7ebc
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.13
|
Release files / geodesk2-2.0.4-cp312-cp312-macosx_11_0_x86_64.whl
| Download URL | geodesk2-2.0.4-cp312-cp312-macosx_11_0_x86_64.whl |
|---|---|
| Size | 1.2 MB |
| Tags | CPython 3.12 macOS 11.0+ x86-64 |
|
SHA-256 checksum How to use checksums |
21427df9b9092d971c3161a8c4edac76092b607fd9ce9de6a3c9ab65dcbb0b58
|
|
BLAKE2b-256 checksum How to use checksums |
f53e4b94f00ff04529d926a4cc31c44237f7404edf6795ce08530154cd1fe444
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.13
|
Release files / geodesk2-2.0.4-cp312-cp312-macosx_11_0_arm64.whl
| Download URL | geodesk2-2.0.4-cp312-cp312-macosx_11_0_arm64.whl |
|---|---|
| Size | 1.1 MB |
| Tags | CPython 3.12 macOS 11.0+ ARM64 |
|
SHA-256 checksum How to use checksums |
83b89172b92d4bb8ad1983eceb7a352b34478a460aca175dc12aa1f73bbde317
|
|
BLAKE2b-256 checksum How to use checksums |
e94a47adf52ef1dedf10cb28e6d09c868e5979ba544844669116a9622233daf6
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.13
|
Release files / geodesk2-2.0.4-cp311-cp311-win_amd64.whl
| Download URL | geodesk2-2.0.4-cp311-cp311-win_amd64.whl |
|---|---|
| Size | 326.6 kB |
| Tags | CPython 3.11 Windows x86-64 |
|
SHA-256 checksum How to use checksums |
66f27fdb5a38a1151976854c4eb734ca5621494cbf747a1f338fcc56d15cb9c5
|
|
BLAKE2b-256 checksum How to use checksums |
3d1cdb364c8591d24120c4ee3693fd5e2bfd7a2c459a41cb2336fbf8fb69c0c2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.13
|
Release files / geodesk2-2.0.4-cp311-cp311-musllinux_1_2_x86_64.whl
| Download URL | geodesk2-2.0.4-cp311-cp311-musllinux_1_2_x86_64.whl |
|---|---|
| Size | 2.6 MB |
| Tags | CPython 3.11 Linux musl 1.2+ x86-64 |
|
SHA-256 checksum How to use checksums |
0750799af7a0b929b34161520912944bb5c8e19716ed8e69ce4bc74b8cbe8d90
|
|
BLAKE2b-256 checksum How to use checksums |
6890fa964723de7bb6adc88fb9a17912227d0505e2659086e14e9a8504a39d89
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.13
|
Release files / geodesk2-2.0.4-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
| Download URL | geodesk2-2.0.4-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl |
|---|---|
| Size | 1.7 MB |
| Tags | CPython 3.11 Linux glibc 2.17+ x86-64 |
|
SHA-256 checksum How to use checksums |
58e3b59ca070c5ccdc0125e112867a438f02368f45d982df6f2cb89fcf2a5358
|
|
BLAKE2b-256 checksum How to use checksums |
e9d6d4bb09a9544296662332719e28a143ba11bdaedf97f45319b7f33d79791f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.13
|
Release files / geodesk2-2.0.4-cp311-cp311-macosx_11_0_x86_64.whl
| Download URL | geodesk2-2.0.4-cp311-cp311-macosx_11_0_x86_64.whl |
|---|---|
| Size | 1.2 MB |
| Tags | CPython 3.11 macOS 11.0+ x86-64 |
|
SHA-256 checksum How to use checksums |
94522c108b9268550e93af167292676d53f20c90f4183b8c354fad746ddd7206
|
|
BLAKE2b-256 checksum How to use checksums |
0278518e7d1b09802d5a190b5b882dea199cff85f01e790fc1f9be8e7f06846d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.13
|
Release files / geodesk2-2.0.4-cp311-cp311-macosx_11_0_arm64.whl
| Download URL | geodesk2-2.0.4-cp311-cp311-macosx_11_0_arm64.whl |
|---|---|
| Size | 1.1 MB |
| Tags | CPython 3.11 macOS 11.0+ ARM64 |
|
SHA-256 checksum How to use checksums |
f8eb9e2dd1b29d8c920127a7e2b75c996ef7b93ffd22ad977f0507b036ac9567
|
|
BLAKE2b-256 checksum How to use checksums |
279bafbb9ffd4e9c8af8a92537166d5db28f8bdebe852f8f0cd33807703cde62
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.13
|
Release files / geodesk2-2.0.4-cp310-cp310-win_amd64.whl
| Download URL | geodesk2-2.0.4-cp310-cp310-win_amd64.whl |
|---|---|
| Size | 326.7 kB |
| Tags | CPython 3.10 Windows x86-64 |
|
SHA-256 checksum How to use checksums |
a91d960f32f4d4d3a5367ca426d0e0ed38eafc9473d1beed42457f0c930cd3e6
|
|
BLAKE2b-256 checksum How to use checksums |
3d95d2af3352290623998286870356bc26c7fc3c100d3d40954947de7ebd7066
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.13
|
Release files / geodesk2-2.0.4-cp310-cp310-musllinux_1_2_x86_64.whl
| Download URL | geodesk2-2.0.4-cp310-cp310-musllinux_1_2_x86_64.whl |
|---|---|
| Size | 2.6 MB |
| Tags | CPython 3.10 Linux musl 1.2+ x86-64 |
|
SHA-256 checksum How to use checksums |
20e100c20ebb63cd69be1ddd9006defc415c4d86b2f5b1c156b630b9d5ac5054
|
|
BLAKE2b-256 checksum How to use checksums |
dba3687538f0a5fc8ae8c0788290145043ef15be9206e2fb60262da5be1b9e8a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.13
|
Release files / geodesk2-2.0.4-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
| Download URL | geodesk2-2.0.4-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl |
|---|---|
| Size | 1.7 MB |
| Tags | CPython 3.10 Linux glibc 2.17+ x86-64 |
|
SHA-256 checksum How to use checksums |
3bd0af8f2fb4b8b2aa0d513255c9457a79a8d36f4d82e6fb3ec787bdb9eafe45
|
|
BLAKE2b-256 checksum How to use checksums |
8e7a33b54b282a54fc462084e68b6f5b8cd3c943c5c28c12373cfb5db371aeb4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.13
|
Release files / geodesk2-2.0.4-cp310-cp310-macosx_11_0_x86_64.whl
| Download URL | geodesk2-2.0.4-cp310-cp310-macosx_11_0_x86_64.whl |
|---|---|
| Size | 1.2 MB |
| Tags | CPython 3.10 macOS 11.0+ x86-64 |
|
SHA-256 checksum How to use checksums |
3a5ddc4979c50781baab333ee0fe1f765ba39c1de268b55693c1e765edd86019
|
|
BLAKE2b-256 checksum How to use checksums |
ee567ba9135d34c502aea070ce6ce53432b8e0cb90c5c650a146c32a95bcdf9d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.13
|
Release files / geodesk2-2.0.4-cp310-cp310-macosx_11_0_arm64.whl
| Download URL | geodesk2-2.0.4-cp310-cp310-macosx_11_0_arm64.whl |
|---|---|
| Size | 1.1 MB |
| Tags | CPython 3.10 macOS 11.0+ ARM64 |
|
SHA-256 checksum How to use checksums |
79ebb783769792bb80c70d1357ed2ae895b4c0d5d3acafc0f893a95b27198cae
|
|
BLAKE2b-256 checksum How to use checksums |
c87c45eab1ffafb422fb0b5761c646826122d52f54e862f6a06a237f29ac3521
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.13
|
Release files / geodesk2-2.0.4-cp39-cp39-win_amd64.whl
| Download URL | geodesk2-2.0.4-cp39-cp39-win_amd64.whl |
|---|---|
| Size | 326.8 kB |
| Tags | CPython 3.9 Windows x86-64 |
|
SHA-256 checksum How to use checksums |
aa1a1ca465b98c75a1aa6327c1a9f8b7bed324de1dfd94a3d4f4042cf518b6fe
|
|
BLAKE2b-256 checksum How to use checksums |
a2f41fa4e4bbbfc7d94358ff6d55571307cb133d9d0d24d33672e76fc96685af
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.13
|
Release files / geodesk2-2.0.4-cp39-cp39-musllinux_1_2_x86_64.whl
| Download URL | geodesk2-2.0.4-cp39-cp39-musllinux_1_2_x86_64.whl |
|---|---|
| Size | 2.6 MB |
| Tags | CPython 3.9 Linux musl 1.2+ x86-64 |
|
SHA-256 checksum How to use checksums |
3ab666425d097d108530c69fcf6da41eb7b5a7a7d903ca669cd256c634a7cc18
|
|
BLAKE2b-256 checksum How to use checksums |
c2a622afcec0189937abab2027a5546cc1447735f3f7acc77a921e45cc5dd4ef
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.13
|
Release files / geodesk2-2.0.4-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
| Download URL | geodesk2-2.0.4-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl |
|---|---|
| Size | 1.7 MB |
| Tags | CPython 3.9 Linux glibc 2.17+ x86-64 |
|
SHA-256 checksum How to use checksums |
f2f795ae8952c753daa56f2fe54c24bf419567443c4b5a3213f9452b35e61a4c
|
|
BLAKE2b-256 checksum How to use checksums |
87cd684e575370c212ab624f65f74a35269bf61748582f91ae92a50617c011a5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.13
|
Release files / geodesk2-2.0.4-cp39-cp39-macosx_11_0_x86_64.whl
| Download URL | geodesk2-2.0.4-cp39-cp39-macosx_11_0_x86_64.whl |
|---|---|
| Size | 1.2 MB |
| Tags | CPython 3.9 macOS 11.0+ x86-64 |
|
SHA-256 checksum How to use checksums |
55e64948ac644ec452309c02c3719459664de54fb1f9dd47ee51a287bb164368
|
|
BLAKE2b-256 checksum How to use checksums |
feafa91c8543ab197b14308695331439f7c6f44e791cd930324a15b42f741474
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.13
|
Release files / geodesk2-2.0.4-cp39-cp39-macosx_11_0_arm64.whl
| Download URL | geodesk2-2.0.4-cp39-cp39-macosx_11_0_arm64.whl |
|---|---|
| Size | 1.1 MB |
| Tags | CPython 3.9 macOS 11.0+ ARM64 |
|
SHA-256 checksum How to use checksums |
8101fc44559a9af92ea708efa7e96a076f3f5b9820dbc6be94e8669a34b297bf
|
|
BLAKE2b-256 checksum How to use checksums |
83957759905dc69971ef8d4eeee484607bd22b22947b87ab97c848c1fb4a0b0f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.13
|