Skip to main content

duckOSM

The notebook manual

Preface

This notebook manual teaches duckOSM from the Python SDK. Each chapter is one Jupyter notebook: you read it here, and you can run the same notebook in Colab with the button at the top of the chapter.

duckOSM builds the road network of an area from OpenStreetMap into one DuckDB file: the networks of each mode (driving, walking, cycling), the nodes, the turns and the base map. Each road has an edge_id that stays the same when you build the area again, so your own data can join to it.

How to read this manual

Part Chapters
The core 1. Get and build an area · 2. Look inside the file · 3. Draw maps · 4. Join your data by edge_id · 5. Fix the OSM data once · 6. Exports
The modules 7. Routing · 8. Advanced routing · 9. Street network analysis · 10. OSM data for GIS · 11. Mobility data · 12. Traffic simulation · 13. Transport planning · 14. HD maps · 15. Graph machine learning

Each chapter starts with what you learn and how long it takes, and ends with exercises, the words of the chapter and a summary. The boxes in the text have one job each:

NoteWhat the output shows

After an output: what the numbers and the card mean.

ImportantKey idea

One idea of a section that you must keep.

TipTip

A good way to do something, or a short way.

WarningWarning

A trap, and how to avoid it.

Where to find more

You want Go to
Each function and its options The manual: Python SDK, command line, database schema
duckOSM in the browser, with no install duckOSM Studio
The source and the issues GitHub