-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Avoid downloading neighboring geometries #110
Comments
Hello @shishkin MonacoI've plotted the geocoded geometry for clause As you can see, there is a huge chunk of sea area that is returned by Nominatim, that isn't covered by extract from Geofabrik. But, changing the PBF source from import quackosm as qosm
import osmnx as ox
qosm.convert_geometry_to_geodataframe(
geometry_filter=ox.geocode_to_gdf("Monaco").unary_union, osm_extract_source="osmfr"
) quackosm --geom-filter-geocode Monaco --osm-extract-source osmfr Düsseldorf
Germany
SummaryBy default QuackOSM uses only Geofabrik extracts, because scraping BBBike and OSMfr takes a long time to do, but these services could contain better matching geometries for particular use cases. Also, Geofabrik has better coverage of the whole world than OpenStreetMap.fr, but they don't have enough buffer around extracts to fully cover Nominatim-based geometries. Looking at those examples, I think I can fix the issue regarding Germany and Düsseldorf case for Geofabrik default source, by discarding new extracts if their contribution to overall geometry is insignificant (for example less than 1% of the queried geometry). OSM_fr index - better precision in particular areas, but some gaps outside Europe |
I see. I'm actually confused by what you call "Nominatim-based geometries". Aren't all geometries coming from OSM unchanged, where Nomimatim is a search index and Geofabrik, osmfr and others are just repackaging the same OSM world.pbf in smaller pieces? I get that the nature of boundaries is very complicated, but so far Geofabrik slicing seem quite practical. I would actually even prefer to just specify names of Geofabrik extracts directly (like |
Nominatim can be a source of truth, but all of those services can define their geometries and names. I've added two issues to tackle the problems mentioned here: |
When specifying
Monaco
to get a geometry and then use that geometry to download and convert OSM into parquet, quackosm downloads 346 MB offiles/Geofabrik_provence-alpes-cote-d-azur.osm.pbf
instead of 527 KB of the actual Monaco PBF.I also tried the same with Regierungsbezirk Düsseldorf. Quackosm downloads neighboring Münster and Köln. That is almost 325 MB more than just 190 MB asked.
When downloading Germany, Quackosm also downloads Denmark, Austria, and Czechia.
Is there a way to avoid downloading unneeded OSM files?
The text was updated successfully, but these errors were encountered: