Replies: 1 comment 1 reply
-
It feels odd to go from a list of OSM IDs to polygons, only to then use it to find if a way of a known OSM ID matches the list. How does your current approach work with updates to OSM data? How does it work with updates to the coverage data? |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I was looking into the new Locators to see if we can migrate some of our custom CSV based code to this new core feature.
I noticed that this would require us to rethink how we access the data compared to what we do now.
It will likely be possible to do all we need, but different and maybe a bit less performant…
So this is meant to share what we are planning to do and start the discussion if it worth adding an additional feature to the locators.
Our goal:
For a given way, know if there is Mapillary coverage of type "panorama" or "regular".
Current approach:
This is the code ATM: https://github.com/search?q=repo%3AFixMyBerlin%2Ftilda-geo+mapillary_coverage+path%3A%2F%5Eprocessing%5C%2F%2F&type=code
Reading the CSV takes about 20 Min at the start of the osm2pgsql processing ATM.
How I would rebuild this using locators:
pano
or (fallback)regular
for the image type. However, we can have overlapping areas, unless we substract thepano
areas in a separate step.mapillary_pano
, one formapillary_regular
Given the pre processing of the data, I can still use the
first_intersecting
logic because we made sure beforehand that the pano area "win" for a given area. I we skip the substraction step in the ata preparation we would have to look atall_intersecting
so see if one ispano
.Alternative: Access properties of the area via the locator:
I think the approach above should work but one has to think about the properties as separate locators.
An alternative would be…
coverage_type=pano|regular
"mapillary_coverage
first_intersecting
, we access thecoverage_type
property for that locator resultSince both approaches work in principle the difference will be mainly performance and developer UX, I guess.
Beta Was this translation helpful? Give feedback.
All reactions