OpenStreetMap Pika-aloitus¶
OpenStreetMap is a free street level map of the world, created by an ever growing community of mappers. Anyone can edit OpenStreetMap. The Learn OSM website provides easy to understand, step-by-step guides for you to get started with contributing to OpenStreetMap and using OpenStreetMap and using OpenStreetMap data. The Learn OSM guide at the link above shows step by step how to navigate the OpenStreetMap website, view and print maps, and sign up for a user account. After you have your own username and password, you will be able to add your first points to the map, learn how to do street surveys and work with aerial imagery.
The remainder of this guide introduces some of the online and offline software used to edit and render OSM data.
Sisältö
Programs that work with OSM data¶
iD¶
iD on on-line oletusohjelma OpenStreetMapin (OSM) editointiin. iD on nopea ja helppokäyttöinen sekä kartoittaminen sillä onnistuu hyödyntäen useampaa tietolähdettä, kuten satelliittii- ja ilmakuvia, kartoituksia sekä GPS-jälki- ja katunäkymäaineistoja.
Aloitussivu: https://www.openstreetmap.org/edit
Dokumentaatio: https://wiki.openstreetmap.org/wiki/ID
JOSM¶
JOSM (Java OpenStreetMap Editor) on kehittynyt Javaan perustuva ohjelma OpenStreetMapin (OSM) editointiin. Se on tehokkaampi ja monimutkaisempi kuin iD ja sitä voidaan käyttää sarjamuokkaukseen ja offline- sekä epävakaiden Internet-yhteyksien kanssa. Sitä voidaan laajentaa lisäosien, mukautettujen esiasetuksien ja muiden laajennuksien avulla.
Verkkosisvusto: https://josm.openstreetmap.de
Käyttöopas: https://wiki.openstreetmap.org/wiki/JOSM/Guide
Tutorial: https://learnosm.org/en/josm/start-josm/
JOSM lisäosakokoelma: https://josm.openstreetmap.de/wiki/Plugins
QGIS¶
OpenStreetMap-dataa voidaan ladata QGIS-ohjelmaan vektorimuodossa. Tämä onnistuu ohjelman ydintoiminnallisuuksilla ja lisäohjelmien kuten QuickOSMin kautta.
QuickOSM: See the QuickOSM section
Online-ohje: https://wiki.openstreetmap.org/wiki/QGIS#QGIS_2:_Importing_OSM_vector_layers
Osmosis¶
Osmosis on toiminnoiltaan laaja apuohjelma, jonka avulla voidaan suorittaa monia tehtäviä OSM-datan kanssa. Tämä sisältää tietojen tuonnin ja viennin tietokantoihin, lajittelun, puhdistamisen ja datadumppien luomisen.
Dokumentaatio: https://wiki.openstreetmap.org/wiki/Osmosis#Usage
Osm2pgsql¶
osm2pgsql on apuohjelma, joka muuntaa OpenStreetMap (.osm) -datan muotoon, jolla se pystytään lataamaan PostgreSQL:ään (PostGIS). Sitä käytetään usein visualisoimaan OSM-dataa Mapnikin avulla, koska Mapnik pystyy kyselemään PostgreSQL:ästä paikkatietoja. Osm-tiedostojen hyödyntäminen suoraan Mapnikista ei nimittäin onnistu.
Working with OSM data in QGIS¶
OSGeoLive comes with OSM data for the city where the global FOSS4G conference takes place. You find the data in the file system at /usr/local/share/data/osm/ or in the PostgreSQL database osm_local.
Start QGIS and have a look at the data.
Open the Desktop GIS folder.
Double click on the QGIS icon.
Go the browser panel on the left of the screen.
Navigate to PostGIS and then to the database osm_local. You will find the data in the schema public.
Drag the layers from the Browser panel and drop them in the map canvas.
You find a QGIS introduction in the QGIS Quickstart
QuickOSM¶
QuickOSM allows you to work quickly with OSM data in QGIS thanks to Overpass API.
Homepage: https://github.com/3liz/QuickOSM
You have to enable the Plugin in QGIS. Search for QuickOSM from Plugins –> Manage and Install Plugins in QGIS
Open QuickOSM from Vector –> QuickOSM –> QuickOSM
Search for all the pubs in the FOSS4G city
Choose key amenity, value pub, in Buenos Aires
Show the query to see the Overpass query
Click Run query. The resulting data will be loaded in your QGIS project as temporal data
You can now save the data via Export -> Save as….. Choose i.e. Geopackage and save the data as buenos_aires_pubs.
Vihje
You also find many OSM Plugins for QGIS. Search for OSM in the plugin repository.
Using OSM as basemap in QGIS¶
XYZ Tiles¶
By default, QGIS comes with OpenStreetMap basemap layer and is located in the Browser Panel under XYZ Tiles.
QuickMapServices¶
QuickMapServices plugin allows you to easily add various map services as basemaps with one click in QGIS.
You have to enable the Plugin in QGIS. Search for QuickMapServices from Plugins –> Manage and Install Plugins in QGIS
Add an OSM basemap from Web –> QuickMapServices –> OSM
Start working with OSM data¶
There are several ways to download OpenStreetMap data for your region. You can get the data in several formats.
You can use the following tools and services to extract OSM data for your area of interest.
Geofabrik¶
Geofabrik provides daily worldwide OpenStreetMap data extracts by subregion and country. Choose the region or country you are interested in. Data is provided in three formats: .osm.pbf, .shp.zip and .osm.bz2. .osm.pbf and`.shp.zip` can be opened directly in QGIS.
Vihje
.osm.bz2 contains raw OSM XML files .osm, osm2pgsql works well with them, find out more about working with them here https://wiki.openstreetmap.org/wiki/OSM_XML
Overpass turbo¶
Overpass turbo is a web based data mining tool for OpenStreetMap based on the Overpass-API.
Have a look at the web client and download all the pubs in the FOSS4G city.
Search for all the pubs in the FOSS4G city
Click on the button Wizard and paste the query to the search column amenity=pub in ”Buenos Aires”
Then click the button build and run query
Click zoom to data in the map canvas to navigate to your results
HOT Export Tool¶
The Humanitarian OpenStreetMap Team (HOT) provides an export tool for OpenStreetMap too. To use it you need an OSM account. You can download data in several formats and have history for your downloaded data and exports.
Here is a quickstart: https://export.hotosm.org/en/v3/learn/quick_start
Mitä seuraavaksi?¶
Find out more about OSM on the website: https://www.openstreetmap.org
Get support: https://www.openstreetmap.org/help