[OSM-dev] Get geometries out of OSM changes file
François Lacombe
fl.infosreseaux at gmail.com
Sun Mar 21 22:28:48 UTC 2021
Hi Yves, Simon, Roland and mmd
Do we agree about nodes lat/lon presence in an osc file as shown in the
first example here?
https://wiki.openstreetmap.org/wiki/OsmChange
At least we have the nodes geometry for each version, however the ways
caveat mentioned by Roland below.
Le dim. 21 mars 2021 à 21:26, Roland Olbricht <roland.olbricht at gmx.de> a
écrit :
> If your process allows to load data over the internet during processing
> then Overpass API (or potentially other OSM APIs) will allow you to
> fetch the missing data on the fly.
>
In my situation, I have to get all modifications done in France in a time
range up to 3 years.
I'm not sure Overpass API is suitable to get such an amount of data in one
query, isn't it?
> If it is easier for you to maintain a full database, run a patch and
> extract then on the fly then you should look at what Osmium (and again,
> some other tools) do.
>
Reload a full database on the same area and filtered on the appropriate
time window will be probably long as well.
I've no experience in it, can you tell me if I'm wrong here?
A third (and current behavior actually) solution is to filter the French
osc file with osmium on the appropriate time window and then filter again
day by bay on each of my 40k admin boundaries
This have to be tremendously long too (and I'm here to abandon this)
> In any case, there is a caveat that the timestamps in the database are
> not strictly in line with the minute updates. As there is no direct
> connection between events on nodes and events on ways or relations, it
> may happen that a way get it final geometry not before half an hour
> later. The new diff process should have mostly mitigated the situation.
> Keep this in mind when the basic process has been set up.
>
This will certainly prevent to rebuild ways linestrings from nodes ids in
osc file, thank you to bring this to my attention
> I'm sorry, from
>
> https://github.com/vdct/ProjetDuMois/blob/master/db/10_project_update.js#L275
> I have not been able to figure out what is in "osh.pbf" to decide
> whether there is already somewhere the geometry.
>
osh.pbf is a file format, not an actual file
This is documented here :
https://docs.osmcode.org/osmium/latest/osmium-file-formats.html
This is really interesting, looking forward to go on these things :)
All the best
François
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/dev/attachments/20210321/1ca68b88/attachment.htm>
More information about the dev
mailing list