Modify

Opened 10 years ago

Closed 5 years ago

Last modified 3 years ago

#10564 closed enhancement (fixed)

GeoJSON import

Reported by: pierzen Owned by: Don-vip
Priority: normal Milestone: 19.10
Component: Core geojson Version: latest
Keywords: Cc:

Description

In the context of Activations like for the current Ebola outbreak, we make a lot of exchanges with imagery providers or with various humanitarian organizations.

OpenData is very handy. Some enhancements could make it even more useful.

  • Geojson export creates only linestring features. To have Polygon to import either in the Tasking Manager or uMap, we have to input in QGIS, convert, save into shp file then reload and save as geojson. Ouf! Then a simple geojson output (Polygon) added to the options would take care of this.

New input or output that would make the plugin even more useful

  • Geojson input
  • csv output
  • kml output
  • shapefile output

Attachments (0)

Change History (34)

comment:1 by Don-vip, 10 years ago

Geojson export is a core feature we need to finish but that's not relevant to the plugin.
Geojson input: why not, can you give me a real example?
Other formats export: no. The idea of the plugin is to be able to import open data resources to improve OSM, not to give back OSM data in proprietary or non geographical formats.

comment:2 by Don-vip, 10 years ago

Owner: changed from Don-vip to pierzen
Status: newneedinfo

Can you please tell me what organization provides geojson data?

comment:3 by Don-vip, 10 years ago

Keywords: geojson added
Summary: Input / Export new formatsGeoJSON import

comment:4 by Don-vip, 10 years ago

Resolution: needinfo
Status: needinfoclosed

I'm OK to add this but please I need some investment from you as well. Please reopen after adding an example.

comment:5 by Denis Carriere <carriere.denis@…>, 10 years ago

Resolution: needinfo
Status: closedreopened

Having the ability to import GeoJSON is very important since it's the only format that can handle complex attributes like "addr:housenumber". Shapefiles have a maximum length of characters in the fieldnames and it usually breaks when you are adding (:) in the fieldnames.

All existing polygon data imports can't handle (addr:housenumber), if the data was in point format you could create CSV, but it's not the case for polygons.

Please add the GeoJSON import in JOSM!

Thanks

comment:6 by Don-vip, 10 years ago

Status: reopenedneedinfo

Same question, can you please give me a real-world example of open data delivered as geojson?

comment:7 by Denis Carriere <carriere.denis@…>, 10 years ago

Ex: Importing buildings to osm from municipal providers.

You can't import any polygons datasets with appropriate OSM related fields. If I'm helping a city import some building data, I would make sure all the data fields match the appropriate standards to OSM.

name
addr:housenumber
addr:route
building

Here's a sample of a GeoJSON of a building, obviously there would be more then just one.

https://gist.github.com/DenisCarriere/8c2b7b5a77fee753477e

comment:8 by Denis Carriere <carriere.denis@…>, 10 years ago

As for providers that give Open data in GeoJSON format, well most of the municipalities don't understand how to format data properly for OSM. There's tons of partnerships that can be made with many cities listed in Canada and across the globe.

Here's all the cities in Canada that have an Open Data program

http://open.canada.ca/en/maps/open-data-canada

But this ticket isn't about getting open data licenses, it's about importing GeoJSON.

Thanks Don-vip!

comment:9 by anonymous, 10 years ago

Here is a link to the (HOT Task Manager Export file for Project 917) (json format)

comment:10 by Denis Carriere <carriere.denis@…>, 10 years ago

HOT is using GeoJSON for their extents for their tasks, it's not exactly data that you will import, however it will be a good file to import to track your progress within an area.

comment:11 by pierzen, 10 years ago

I first forgot to connect. There are surely other uses then for HOT, as Denis described.

And exactly, bringing the grid into JOSM is for management of crowdsourcing. It let's look at the data for the area. With the grid in the background, we can import data, either a specific tag or a specific area.

For major Activation like for Ebola, we build overview maps that show imagery available, districts to map.
See http://umap.openstreetmap.fr/en/map/sierra-leone-kailahun-district-imagery_11227#9/8.1313/-10.8669

We add various Task Manager jobs. Then re-import into JOSM to see the extent of areas already covered. This is a monitoring tools that we share with our various partners in the Activation.
See http://umap.openstreetmap.fr/en/map/west-africa-ebola-openstreetmap-response-200-km-x-_13842#6/8.190/-11.942

in reply to:  7 ; comment:12 by stoecker, 10 years ago

Replying to Denis Carriere:

Ex: Importing buildings to osm from municipal providers.

...

Here's a sample of a GeoJSON of a building, obviously there would be more then just one.

https://gist.github.com/DenisCarriere/8c2b7b5a77fee753477e

That looks much like an already converted data set with OSM specifics. So that's no original data. If you can output GeoJSON in a converter, you can also output the OSM-XML format instead. Where is the advantage of using JSON?

in reply to:  12 comment:13 by Denis Carriere <carriere.denis@…>, 10 years ago

Replying to stoecker:

That looks much like an already converted data set with OSM specifics. So that's no original data. If you can output GeoJSON in a converter, you can also output the OSM-XML format instead. Where is the advantage of using JSON?

Most of the data is stored as JSON now a days, no one stores data as OSM XML format. For example using a database like MongoDB and then export your data into GeoJSON is very easy, exporting it into OSM is not possible without installing a converter.

I created that GeoJSON object using http://geojson.io

Original data doesn't exist, people have to make it, and no one makes data into OSM XML format, the new standard for data is GeoJSON, it's not proprietary unlike ESRI's shapefile format which is used for commercial purposes.

comment:14 by pierzen, 10 years ago

If we can save data in JOSM with geojson format, we should be able to reread it without passing by an other software to convert in shapefile and come back again in JOSM.

comment:15 by Don-vip, 9 years ago

Resolution: wontfix
Status: needinfoclosed

So as far as I understand, there is no data provider currently providing geojson, so I won't implement this.
If you are producing geojson yourself, please produce OSM files instead.

comment:16 by GutenYe, 9 years ago

in reply to:  16 comment:17 by Don-vip, 9 years ago

Replying to GutenYe:

@Don-vip

There're tons of GeoJSON open data available in Github.

Github is not an open data portal. For the example of Chicago, if you look at your project description you will find that the data comes from the official Chicago open data portal:

https://data.cityofchicago.org

And the data you can find there seems to be natively in KML, and can be exported in shapefile as well, not geojson, example:

https://data.cityofchicago.org/Public-Safety/Boundaries-Police-Districts-current-/fthy-xz3r

This is always the same thing: open data portals propose data in formats supported by the plugin, and you want to support a file format used by other developers who transformed the original data.

My answer stays the same: keep to original data. I still don't see any example of official organization using geojson as native and sole file format that would justify to add it into the plugin.

comment:18 by anonymous, 9 years ago

+1 for this feature

comment:19 by carriere.denis@…, 9 years ago

Resolution: wontfix
Status: closedreopened

Can this feature ever be implemented? There's clearly a demand for this, it's very silly that you can export as GeoJson but you can't import the data back into JSOM.

comment:20 by Don-vip, 9 years ago

Resolution: wontfix
Status: reopenedclosed

No. And stop this please, this becomes annoying.

comment:21 by Stereo, 8 years ago

I apologise in advance if this is annoying.

Some open data portals do publish as geojson, e.g. https://data.public.lu/en/datasets/donnees-geographiques-des-chemins-de-randonnee-du-portail-tourisme-geoportail-lu/

If you want to open geojson data in josm, an easy way to convert it is via geojson.io.

comment:22 by carriere.denis@…, 8 years ago

Also to add, the GeoJSON specification has been published by IETF.

RFC 7946

In 2015, the Internet Engineering Task Force (IETF), in conjunction with the original specification authors, formed a GeoJSON WG to standardize GeoJSON. RFC 7946 was published in August 2016 and is the new standard specification of the GeoJSON format, replacing the 2008 GeoJSON specification.

in reply to:  21 comment:23 by Don-vip, 8 years ago

Resolution: wontfix
Status: closedreopened

Replying to Stereo:

I apologise in advance if this is annoying.

It is not, that's the first answer to the question I asked two years ago. I will then consider to add geojson support, thanks for the link.

comment:24 by openstreetmap.org-user-d1g, 8 years ago

For reference, latest version of the GeoJSON viewer plug-in (by Larry0ua) was discussed here:

comment:25 by carriere.denis@…, 8 years ago

@don-vip Can I buy you a gift ? :) This support will solve so many issues with datasetes that need colons in the attributes such as "addr:housenumber & addr:street". It's impossible to have a Shapefile to have those columns and the only way around it was to use point geometry in a CSV, polygons & ways are very problematic.

<3 <3 <3 JOSM FTW!

comment:26 by Klumbumbus, 8 years ago

Ticket #14663 has been marked as a duplicate of this ticket.

comment:27 by Don-vip, 6 years ago

Owner: changed from pierzen to Don-vip
Status: reopenednew

comment:28 by Don-vip, 5 years ago

Component: Plugin opendataCore
Owner: changed from Don-vip to team

comment:29 by Don-vip, 5 years ago

Milestone: 19.10
Owner: changed from team to Don-vip
Status: newassigned

comment:30 by Don-vip, 5 years ago

Resolution: fixed
Status: assignedclosed

In 15424/josm:

fix #10564 - add GeoJSON import (adapted from geojson plugin)

comment:31 by Don-vip, 5 years ago

Component: CoreCore geojson
Keywords: geojson removed

comment:32 by Don-vip, 5 years ago

In 15441/josm:

see #10564 - add missing geojson download task
see #13015 - fix presets checkgroup layout for checks without icon

comment:33 by Don-vip, 5 years ago

In 15452/josm:

see #10564 - use the same i18n string than other actions

comment:34 by Don-vip, 3 years ago

In 35787/osm:

see #10564 - remove geojson from plugin svn:externals

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Don-vip.
as The resolution will be set.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.