ohsome-api icon indicating copy to clipboard operation
ohsome-api copied to clipboard

Allow charts like potm.osm.ch/superset/dashboard/31/

Open tordans opened this issue 2 years ago • 1 comments

Use Case Description

I would like to run https://potm.osm.ch/superset/dashboard/31/ for Berlin without having to setup all the stuff that https://github.com/sosm/osmhistorydb-ch runs manually.

I want to integrate those charts in a micro site that is focussed on specific dataset like drinking water, bicycle stands, parking lane tags and such.

Request Description

  • [x] Provide Data for a chart on the number of OSM objects for a given tag over time Possible today with queries like https://dashboard.ohsome.org/#backend=ohsomeApi&groupBy=none&time=2022-06-01T00%3A00%3A00Z%2F2023-06-18T20%3A00%3A00Z%2FP1M&measure=count&key=sport&value=table_tennis&types=node%2Cway%2Crelation&adminids=-62422

    • [ ] Allow to filter by user-identifier (see also below)
  • [ ] Provide Data for a chart on then number of OSM Changes for a given timeframe and tag It looks like a grouping by day and count of changesetid might be possible with the /contributions api endpoint?

    • [ ] Allow to filter by user-identifier (see also below)
  • [ ] Provide Date on the total and top 5 list of mappers that (a) created new objects and (b) changed objects for a given timeframe and tag, by grouped by user-identifier. It looks like this is blocked by https://github.com/GIScience/ohsome-api/issues/182 from 2021.


The idea of this issue is to be a kind of umbrella ticket to collect know how on this topic.

tordans avatar Jul 03 '23 04:07 tordans

Provide Data for a chart on then number of OSM Changes for a given timeframe and tag

Yeah, that would be the /contributions/count endpoint, e.g. https://api.ohsome.org/v1/contributions/count?bboxes=12.944,52.299,13.824,52.742&filter=type:node%20and%20amenity=drinking_water&time=2010-01-01/2023-01-01/P1Y&format=csv

Provide Data for a chart on the number of OSM objects for a given tag over time […] Allow to filter by user-identifier

Independent from the GDPR topic, it is not clearly defined what exactly filtering by user-id would mean for a regular (i.e. non-contribution) aggregation endpoint: Is it filtering entities which have been a) created by the respective user, b) last edited by the user, c) edited at some point by the respective user, d) something else

//edit: FWIW, potm.osm.ch also flags this combination as incompatible:


Allow to filter by user-identifier

My usual answer would have been that in such cases you could fall back to the oshdb, starting with a small history extract (e.g. from geofabrik), converting it to the oshdb format, and running an OSHBD query on it using the OSMContributionView. But I don't think that would really make sense in your use case, as it sounds like a similar amount of effort as setting up an instance of osmhistorydb-ch.

tyrasd avatar Jul 05 '23 08:07 tyrasd