background preloader

OSM how-tos

Facebook Twitter

Osmosis. Osmosis is a command line Java application for processing OSM data. The tool consists of pluggable components that can be chained to perform a larger operation. For example, it has components for reading/writing databases and files, deriving/applying changes to data sources, and sorting data, (etc.). It has been written to easily add new features without re-writing common tasks such as file and database handling. Some examples of the things it can currently do are: Generate planet dumps from a database Load planet dumps into a database Produce change sets using database history tables Apply change sets to a local database Compare two planet dump files and produce a change set Re-sort the data contained in planet dump files Extract data inside a bounding box or polygon Osmosis can also be included as a library in other Java applications.[1] Current status Osmosis is in a state where the majority of the codebase is unlikely to change drastically.

Downloading Latest Stable Version Java 1.5. Download.geofabrik.de. PBF Format. PBF Format ("Protocolbuffer Binary Format") is primarily intended as an alternative to the XML format. It is about half of the size of a gzipped planet and about 30% smaller than a bzipped planet. It is also about 5x faster to write than a gzipped planet and 6x faster to read than a gzipped planet. The format was designed to support future extensibility and flexibility. The underlying file format is chosen to support random access at the 'fileblock' granularity. Each file-block is independently decodable and contains ~8k OSM entities in the default configuration.

There is no tag hardcoding used; all keys and values are stored in full as opaque strings. Files have extension *.osm.pbf At the present time, the reference implementation of PBF is the Osmosis implementation, split into two parts, the osmosis-specific part, contained in the Osmosis repository at [1], and an application-generic part at [2]. Software support for PBF Design Low level encoding File format For datestamps, Nodes. OSM Inspector.

A part of Karlsruhe in the Addresses view of the OSM Inspector The OSM Inspector is a web based debugging tool for advanced OpenStreetMap users offered by Geofabrik. On a map you can see several themed views, each with several layers, showing specific details of the OSM data, often with highlighted errors. Layers can be switched on and off, details about any feature is available on mouseclick and links lead to your favourite editor so that you can fix problems easily. Views Currently the following views are available: What is Open about OSM Inspector and what isn't The data sets which OSM Inspector is based on are generated as a side product by custom, Geofabrik-internal data processing. The results, however, can not only be viewed in OSM inspector, but they can also be downloaded in raw form through WMS and WFS interfaces.

See also Other quality assurance tools are listed in Quality Assurance. Wishlist I would like to see something like the coastline checker for the relation boundary. OSM Inspector/Views/Boundaries. Index of /~jocelyn/polygons. Overpass API. Introduction The Overpass API (formerly known as OSM Server Side Scripting, or OSM3S before 2011) is a read-only API that serves up custom selected parts of the OSM map data. It acts as a database over the web: the client sends a query to the API and gets back the data set that corresponds to the query.

Unlike the main API, which is optimized for editing, Overpass API is optimized for data consumers that need a few elements within a glimpse or up to roughly 100 million elements in some minutes, both selected by search criteria like e.g. location, type of objects, tag properties, proximity, or combinations of them. It acts as a database backend for various services. Overpass API has a powerful query language with a lot more features than the former XAPI based tools. For details, see the introductory level language guide or the comprehensive Overpass QL guide/language reference. To support small and well scaling OSM main services, Overpass API is run as a third party service. Limitations. How do I extract the polygon of an administrative boundary? It depends, of course, of the format you want. Convert as written above. Display any part of the map in JOSM.File>new layer Select what you wantEdit>Merge Selection -> new layer Repeat Select+Merge as many times as needed With new layer active, File>Save As...

-> layer -> xxx.osm file same to save xx.gpx, xxx.json or compressed OSM files. A new layer is useful to display only the data you want to edit or save. Display it in the main layer.in Relations window, right-click your boundary>Select relationEdit>Merge Selection -> new layer With new layer active, right-click your boundary>Download incomplete members-> your boundary to be a polygon If your admin_level relations contain admin_level+x relations as subareas (a very good idea), you can download whole chunks of boundaries going from one to the parent or child.

Edit>Select all File>Update selectionto keep your data in sync, else you may get nasty conflicts to solve. !!! Switch2osm | GPS or BING for Buildings? Collecting OpenStreetMap POIs with Fulcrum. There’s been some discussion around the OpenStreetMap community lately about improving the available tools for editing the map, and making it more accessible for mere mortals to contribute on their own.

The current procedure that a new contributor has to walk through to make their first edits is still quite complicated, even with powerful editing tools like the web-based Potlatch editor and the more powerful desktop tool, JOSM . Potlatch makes editing somewhat simpler by abstracting OSM’s complex tagging schema , but it can still be overwhelming to a new editor. Still, neither editor is practical when out in the field surveying for street names, POI features, or other details someone might want to observe and contribute.

I really wanted a way to do surveying on my iPhone. OSM tagging classifications I’ve also set up a number of visibility conditions, so that certain fields only appear on my phone when particular conditions are met: e.g. Fulcrum exported tags in JOSM. Roof modelling. Notes for drawing buildings in Potlatch 2 basing upon BING aerial imagery This article refers using of Potlatch 2 and Bing. Apart from details in the handling of Potlatch 2 are the discussed methods also applicable: -in other editors like JOSM and Merkaartor -with aerial images other than those of Bing. Autor: Marek Strassenburg-Kleciak Tips Don't forget to add (in the left panel) a building tag to the outline after drawing! You should only use the most detailed zoom level when drawing buildings.

In Potlatch 2, the background imagery layer should not usually be "dimmed", as it can make interpreting the images harder. Drawing of simple building outlines The goal is to draw the geometry of the building outline as precisely as possible: These parts of the aerial image are helpful in the interpretation: 1. After the roof shape has been drawn as an outline, it should be moved to match the location on the ground level. 3. About the logic of building making 4x and 2x symmetry Function "make rectangular" How do I extract the polygon of an administrative boundary?

Tutorial: How to extract street coordinates from Open Street Map geodata « dataist. I’ve spent almost a year learning about data-driven journalism and tools for analysis and visualization of data. I have now become confident enough to think that I might even be able to teach someone else something. So here it goes: my first tutorial. The task Earlier this fall Helsingin Sanomat published a huge dump of price data from Oikotie, a Finnish market place for apartments. I had an idea to build a kind of heat map where every street would be colored based on the average price of the apartments. With the JavaScript library Polymaps you can easily make stylish web maps.

The problem is that you need an overlay GeoJSON layer with the colored streets. From .shp to .geojson The raw data from Open Street Map is downloadable in shape-format. This is A LOT of geodata, but in this case I’m only interested in the Helsinnki region. To export the selected part of the map to the GeoJSON format that Polymaps can read, chose Layer > Save Selection as vector file and GeoJSON as your format. End. General Discussion - Enhanced version of "OSM Administrative Boundary Map" at OpenMapSurfer.uni-hd.de.

About This Site | OpenStreetMap Data. There are several download options on this site. See the information about available projections and formats. Data All of the data on this site is derived from the original OpenStreetMap data and available under the same conditions. See the license page for more details. Because the data is directly derived from OpenStreetMap data, errors in OSM data will appear in this data, too. Don't ask me to fix those errors, you can do that in OpenStreetMap yourself. You can get the original OpenStreetMap data from the official download site at planet.openstreetmap.org. Software I use Open Source software written by me and others to convert the data into the form you see here.