BAG
download_bag_light(download_dir=datastore.bag_dir, overwrite=True)
Download BAG for The Netherlands
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
download_dir
|
Path
|
Download dir to store GeoPackages. By default datastore.bag_dir |
bag_dir
|
overwrite
|
bool
|
If not True BAG will only be downloaded if not existing. Default is True |
True
|
Returns:
| Type | Description |
|---|---|
Path
|
Path to BAG GeoPackage |
get_bag_features(bbox, *, layer='pand', source='wfs', bag_light_gpkg=datastore.bag_dir.joinpath('bag-light.gpkg'), wfs_crs=28992)
Get BAG features
Use source=wfs to use the BAG wfs. Note (!) BAG only allows you to extract 50000 features. If your bbox is too large, you'll get an incomplete result
Use source=bag-light to extract from an existing bag-light GeoPackage. This file can be downloaded with the download_bag_light function in the waterlagen.bag module
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
bbox
|
tuple[float, float, float, float] | None
|
Extent with (xmin, ymin, xmax, ymax). BAG will be downloaded for this extent only. |
required |
layer
|
Literal['pand', 'verblijfsobject']
|
Layer to extract/download, by default "pand" |
'pand'
|
source
|
Literal['bag-light', 'wfs']
|
Source to extract/download features from, by default "wfs" |
'wfs'
|
bag_light_gpkg
|
Union[Path, str]
|
bag_light GeoPackage to extract features from with |
joinpath('bag-light.gpkg')
|
wfs_crs
|
int
|
CRS to use for extracting BAG features from WFS, by default 28992 |
28992
|
Returns:
| Type | Description |
|---|---|
GeoDataFrame
|
GeoDataFrame with BAG-features |