GeofabrikDownloader.get_region_subregion_tier

GeofabrikDownloader.get_region_subregion_tier(update=False, confirmation_required=True, verbose=False)[source]

Get a catalogue of region-subregion tier.

This includes all geographic regions to which data of subregions is unavailable.

Parameters
  • update (bool) – whether to check on update and proceed to update the package data, defaults to False

  • confirmation_required (bool) – whether to prompt a message for confirmation to proceed, defaults to True

  • verbose (bool or int) – whether to print relevant information in console, defaults to False

Returns

region-subregion tier (in dict type) and all that have no subregions (in list type)

Return type

tuple

Example:

>>> from pydriosm.downloader import GeofabrikDownloader

>>> geofabrik_downloader = GeofabrikDownloader()

>>> rs_tier, ns_list = geofabrik_downloader.get_region_subregion_tier()

>>> print(list(rs_tier.keys()))
['Africa',
 'Antarctica',
 'Asia',
 'Australia and Oceania',
 'Central America',
 'Europe',
 'North America',
 'South America']

>>> print(ns_list[0:5])
['Antarctica', 'Algeria', 'Angola', 'Benin', 'Botswana']