GeofabrikDownloader¶
-
class
pydriosm.downloader.
GeofabrikDownloader
(download_dir=None)¶ Download OSM data from Geofabrik free download server.
- Parameters
download_dir – (a path or a name of) a directory for saving downloaded data files; if
None
(default), a folderosm_geofabrik
under the current working directory- Variables
Example:
>>> from pydriosm.downloader import GeofabrikDownloader >>> geofabrik_downloader = GeofabrikDownloader() >>> print(geofabrik_downloader.Name) Geofabrik OpenStreetMap data extracts >>> print(geofabrik_downloader.URL) https://download.geofabrik.de/
Methods
download_osm_data
(subregion_names, …[, …])Download OSM data (in a specific format) of one (or multiple) geographic region(s).
download_subregion_data
(subregion_names, …)Download OSM data (in a specific file format) of all subregions (if available) for one (or multiple) geographic region(s).
file_exists
(subregion_name, osm_file_format)Check if a requested data file of a geographic region already exists locally, given its default filename.
get_continents_subregion_tables
([update, …])Get download information for continents.
get_default_osm_filename
(subregion_name, …)get a default filename for a geograpic region.
get_default_path_to_osm_file
(subregion_name, …)Get a default path to a local directory for storing a downloaded data file.
get_download_catalogue
([update, …])Get a catalogue of download information.
get_download_index
([update, …])Get the formal index of all available downloads.
get_list_of_subregion_names
([update, …])Get a list of names of all available geographic regions.
get_raw_directory_index
(url[, verbose])Get a raw directory index.
get_region_subregion_tier
([update, …])Get a catalogue of region-subregion tier.
get_subregion_download_url
(subregion_name, …)Get a download URL of a geographic region.
get_subregion_table
(url[, verbose])Get download information for all geographic regions on a web page.
make_sub_download_dir
(subregion_name, …[, …])Make a default directory for downloading data of a geographic region’s subregions.
search_for_subregions
(*subregion_name[, deep])Retrieve names of all subregions (if any) of the given geographic region(s).
validate_input_file_format
(osm_file_format)Validate an input file format of OSM data.
validate_input_subregion_name
(subregion_name)Validate an input name of a geographic region.