Ga naar inhoud

BGT

BgtCustomDownload dataclass

Metadata for a custom BGT request.

BgtDownload dataclass

Metadata for the predefined national BGT download.

bgt_custom_download(download_dir=datastore.bgt_dir, *, featuretypes=DEFAULT_FEATURETYPES, poly_mask=None, overwrite=True, poll_interval_s=5)

Download BGT features as GeoPackages.

Parameters:

Name Type Description Default
download_dir Path

Download dir to store GeoPackages. By default datastore.bgt_dir.

bgt_dir
featuretypes Iterable[str]

BGT feature-types, by default ("waterdeel", "pand").

DEFAULT_FEATURETYPES
poly_mask shape | None

Optional polygon-mask to use as geofilter. If not Polygon, shape-bounding box will be used. By default None

None
overwrite bool

If not True BGT will only be downloaded if all expected output files already exist. Default is True.

True
poll_interval_s int

Interval to poll the BGT download status in seconds, by default 5.

5

Returns:

Type Description
BgtCustomDownload

Metadata for the BGT download.

bgt_download(*args, **kwargs)

Compatibility alias for :func:download_bgt.

download_bgt(download_dir=datastore.bgt_dir, *, featuretypes=DEFAULT_FEATURETYPES, target_path=None, overwrite=True, url=BGT_PREDEFINED_URL, progress=True, chunk_size=1024 * 1024, timeout=30)

Download the predefined national BGT GML Light ZIP as one GeoPackage.

get_bgt_features(featuretypes, poly_mask, download_dir)

Download BGT features in GeoPackages.

Use :func:bgt_custom_download for new custom BGT downloads.